Summary: | /etc/conf.d/net with two NICs can easily break the gateway setting | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Jules Colding <colding> |
Component: | [OLD] baselayout | Assignee: | Roy Marples (RETIRED) <uberlord> |
Status: | RESOLVED INVALID | ||
Severity: | minor | ||
Priority: | High | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- |
Description
Jules Colding
2005-07-21 10:53:52 UTC
The new configuration in baselayout-1.11.13 allows the use of the route_eth0 syntax to set gateways http://www.gentoo.org/doc/en/handbook/handbook-x86.xml?part=4&chap=1 routes_eth0=( "default via 10.0.1.1" ) routes_eth1=( "default via 10.0.1.1" ) (In reply to comment #1) > The new configuration in baselayout-1.11.13 allows the use of the route_eth0 > syntax to set gateways > > http://www.gentoo.org/doc/en/handbook/handbook-x86.xml?part=4&chap=1 > > routes_eth0=( "default via 10.0.1.1" ) > routes_eth1=( "default via 10.0.1.1" ) I tried that, but it doesn't work. My exact /etc/conf.d/net is: ############# iface_eth0="10.0.1.4 broadcast 10.0.1.255 netmask 255.255.255.0" iface_eth1="10.0.1.5 broadcast 10.0.1.255 netmask 255.255.255.0" routes_eth0=( "default via 10.0.1.1" ) routes_eth1=( "default via 10.0.1.1" ) #gateway="eth1/10.0.1.1" ############# It only works if the "gateway=..." is effective. config_eth0=( "10.0.1.4 broadcast 10.0.1.255 netmask 255.255.255.0" ) config_eth1=( "10.0.1.5 broadcast 10.0.1.255 netmask 255.255.255.0" ) routes_eth0=( "default via 10.0.1.1" ) routes_eth1=( "default via 10.0.1.1" ) There ya go :) BTW, the gateway var is translated into a routes_ethx variable However - with the current stable version of baselayout you can only have one default route, and you're adding two - if both interfaces are active at the same time. baselayout-1.12.0 will solve this issue by clever use of route metrics :) (In reply to comment #3) > config_eth0=( "10.0.1.4 broadcast 10.0.1.255 netmask 255.255.255.0" ) > config_eth1=( "10.0.1.5 broadcast 10.0.1.255 netmask 255.255.255.0" ) > > routes_eth0=( "default via 10.0.1.1" ) > routes_eth1=( "default via 10.0.1.1" ) > > There ya go :) Thanks a lot. Works fine :-) |