[Users] No Persistent TUN/TAP Devices?

openvz at bigfatdave.com openvz at bigfatdave.com
Mon Sep 6 17:03:57 EDT 2010

Hi Matt,

Matt Ayres wrote:
>  On 9/6/2010 3:03 PM, openvz at bigfatdave.com wrote:

>> Now, I run OpenVZ in production on my own hardware, so I know that

>> the lack of persistent TUN/TAP devices isn't "by design," but obviously

>> there's some setting that these guys don't know/care about.  Would anybody

>> care to clue me in, here?


>Two things I can think of:


>1) They are not loading the 'tun' drive on the host on boot.

>2) they are not using vzctl --save option when enabling tun device for 

>your VPS.

I think they've successfully confused you (as well as themselves, so
don't feel bad) with the rebooting discussion.  I can easily verify that
the TUN/TAP driver is loaded, but when I try to set a TUN/TAP device
persistent, I get errno==1 returned.  If you have openvpn installed
locally, the easiest way to duplicate the error is to do this from
a shell:
 # strace openvpn --mktun --dev tun
(Notice, in particular, how the TUNSETPERSIST ioctl(2) call fails,
setting errno to EPERM.)

If you don't have and don't want openvpn, just let me know, and I'll
paste here a trivial C program to show off the problem.

More information about the Users mailing list