On Wed, Jul 22, 2009 at 06:43:29PM +0200, Robert Millan wrote: > On Wed, Jul 22, 2009 at 04:01:51PM +0200, Alberto Gonzalez Iniesta wrote: > > On Sat, May 05, 2007 at 06:06:07PM +0200, Robert Millan wrote: > > > There seems to be a race between daemonised openvpn trying to bring up > > > network > > > and fetchmail (or the like) trying to connect to a pop server that can > > > only > > > be accessed via VPN tunnel. In my particular case, this results in: > > > > > > - fetchmail not checking mail in its first run. > > > - /me being unable to set an high sleep period, since I would have to > > > wait > > > too much every time the machine is started. > > > > > > I assume there could be other (maybe worse) problems because of this. > > > Would > > > you consider blocking openvpn initialisation untill the network is > > > brought up? > > > > > > Hi Robert, > > > > I think the solution in this case is in your hands, more than in mine. > > You'd probably want to use 'openvpn foobar' in /etc/network/interfaces, > > or /etc/ppp/ip-up.d/ to start openvpn only when the network is up. > > Instead of having it started on system initialization. > > Other option could be starting fetchmail with openvpn's 'up' option > > (and up-delay). > > Ok, but openvpn installs /etc/init.d/openvpn, shouldn't it hook itself in > /etc/network/if-up.d/ instead?
Openvpn installs an init script just like all daemons, but also provides you with a /etc/default/openvpn to avoid starting VPNs with that script. And you also get a /etc/network/if-up.d/openvpn to use in the interfaces file. So you've got plenty of choices :) -- Alberto Gonzalez Iniesta | Formación, consultoría y soporte técnico agi@(inittab.org|debian.org)| en GNU/Linux y software libre Encrypted mail preferred | http://inittab.com Key fingerprint = 9782 04E7 2B75 405C F5E9 0C81 C514 AF8E 4BA4 01C3 -- To UNSUBSCRIBE, email to [email protected] with a subject of "unsubscribe". Trouble? Contact [email protected]

