Am 14.11.2012 18:55, schrieb Helmut Jarausch: > On 11/13/2012 07:08:24 PM, Florian Philipp wrote: >> Am 13.11.2012 17:27, schrieb Bruce Hill: >> > On Tue, Nov 13, 2012 at 04:52:25PM +0100, Helmut Jarausch wrote: >> >>>> >> >>>>> I'd like to assign fixed IP numbers to computers of a local >> >>>> map MAC addresses to IP addresses. >> > >> [...] >> > >> > If you just want to setup a static IP per machine, /etc/conf.d/net: >> > >> > config_wlan0="192.168.1.2/24" >> > routes_wlan0="default via 192.168.1.1" >> > >> > Hope this helps. If it's too confusing, might mention where DHCP is >> handed >> > out, and some more about your LAN. >> >> The following is taken directly from my /etc/conf.d/net with minimal >> editing. It assigns configs based on SSIDs. If I'm not mistaken (haven't >> tested it in a long time) this means it will default to DHCP for >> unspecified nets. Good for quick and dirty setups while traveling: >> >> modules_wlan0="wpa_supplicant" >> >> config_MySSID="192.168.2.5 netmask 255.255.255.0" >> routes_MySSID="default via 192.168.2.1" >> dns_servers_MySSID="192.168.6.1" >> dns_domain_MySSID="example.net" >> >> config_SomeHotelSSID="dhcp" >> >> config_HotelWithVPN="dhcp" >> dhcp_HotelWithVPN="nodns" >> dns_servers_HotelWithVPN="192.168.6.1" # DNS server via VPN >> dns_domain_HotelWithVPN="vpn.example.net" >> >> Hope this helps, > > Thanks Florian, > > it *nearly* works. > The line > routes_MySSID="default via 192.168.2.1" > > (adapted to my IPs) > doesn't seem to have any effect. > > Only if I add > > route add default gw 192.168.2.1 wlan0 > > to /etc/local.d/local.start > it does work. > > I have no idea why the routes_MySSID=... line doesn't have any effect. > > Helmut. >
Just guessing, could it be related to iproute2? From net.example: # If you don't specify an interface then we prefer iproute2 if it's # installed. To prefer ifconfig over iproute2 modules="!iproute2"
signature.asc
Description: OpenPGP digital signature

