[maemo-developers] auto-start openvpn and udhcpc
From: Marius Gedminas marius at pov.ltDate: Wed Mar 3 09:29:28 EET 2010
- Previous message: auto-start openvpn and udhcpc
- Next message: auto-start openvpn and udhcpc
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On Tue, Mar 02, 2010 at 10:25:48PM -0500, Jason wrote: > I'm attempting to get openvpn on my N900 connecting to my existing > openvpn server. The openvpn part works well. The automation part is > trickier :-) > > First, how do I get openvpn to automagically start anytime I select a > network to connect to? I'd like mail checks (which should pull up an > interface on demand) to find my mailserver, which is only available > via vpn. Good question. I suppose you already tried /etc/network/if-up.d/ and it didn't work? > Second, I've found a script workaround for the gprs0 unnamed gateway > issue, but I can't figure out the proper way to trigger udhcpc on my > tap0. I've setup my openvpn infrastructure to use my dnsmasq server > for dhcp and to use real dhcp clients to configure tap0 (one tool for > one job [1]). This has worked great for years on > desktop/laptop/embedded platforms. > > I tried adding tap0 to /etc/network/interfaces, but that earned me a > dumb look. Isn't maemo supposed to be debian-based? It is; that doesn't mean nothing was changed. > I cat'd the > /proc/$PID/cmdline of udhcpc for my wlan0 which sent me on a script > hunt and didn't yield, at least to me, a clean way to hook in or > trigger it. Worst case you can listen for DBUS notifications to discover when the N900 gets online. Best case -- I hope you can find a script you can hook into. E.g. /etc/udhcpc/default.script might work. > I also found that resolv.conf is changed in /var/run... That's normal for dnsmasq, as far as I understand. Incidentally, the script that modifies it is /etc/udhcpc/default.bound or default.renew > Any ideas? > > thx, > > Jason. > > [1] http://www.faqs.org/docs/artu/ch01s06.html Regards, Marius Gedminas -- C is a language that combines all the elegance and power of assembly language with all the readability and maintainability of assembly language. -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 189 bytes Desc: Digital signature URL: <http://lists.maemo.org/pipermail/maemo-developers/attachments/20100303/86c25920/attachment.pgp>
- Previous message: auto-start openvpn and udhcpc
- Next message: auto-start openvpn and udhcpc
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]