[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Thoughts on network detection and configuration on Debian



Hi.

I'm using the guessnet package with my laptop. It can be configured with
/etc/network/interfaces like this:

auto lo eth0

iface lo inet loopback

mapping eth0
        script /usr/bin/guessnet
        map 10.3.67.3           00:50:04:BE:05:CD 10.3.64.42    eth0-work
        map 192.168.1.1         00:D0:C9:35:02:90 192.168.1.11  eth0-home
        map 192.168.0.51        00:80:48:90:8E:D5 192.168.0.1   eth0-platte
        map 192.168.0.60        00:10:5A:A2:BE:54 192.168.0.90  eth0-halfmann

iface eth0-work inet dhcp
        up /etc/network/adapt_location.sh eth0 dns=10.3.64.65 mirror=http://spieglein firewall=eth0

iface eth0-platte inet dhcp
        up /etc/network/adapt_location.sh eth0 mirror=ftp://192.168.0.5 nosources

iface eth0-halfmann inet static
        up /etc/network/adapt_location.sh eth0 dns=192.168.0.90 firewall=eth0
        gateway 192.168.0.90
        address 192.168.0.60
        netmask 255.255.255.0

iface eth0-home inet static
        up /etc/network/adapt_location.sh eth0 dns=62.225.244.197
        address 192.168.1.1
        gateway 192.168.1.11
        netmask 255.255.255.0

iface eth0-none inet static
        up /etc/network/adapt_location.sh eth0 dns=62.225.244.197 firewall=ppp0
        address 192.168.1.1
        netmask 255.255.255.0

adapt_location is a script I did myself just for comfort reasons.

Couldn't this do everything you need?

Greetings,
-Cajus



Reply to: