From Bugzilla Helper: User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.6) Gecko/20050224 Firefox/1.0.1 Fedora/1.0.1-1.3.1 Description of problem: There is no way to disable default route for interface which uses dhcp as protocol to receive ip-address etc. I would like to see something like this in future releases: /sbin/dhclient-script (from line 141): function add_default_gateway() { + if [ "${DEFAULTROUTE}" == "no" ]; then + return + fi So that then we can say in /etc/sysconfig/network-scripts/ifcfg-eth?: PEERDNS=no DEFAULTROUTE=no And we only get ip/netmask/broadcast from dhcp and that's all what we want. This seems to work but people more familiar to the scripts can point out failures, but the idea of what is needed is clear. Version-Release number of selected component (if applicable): dhclient-3.0.1-40_FC3 How reproducible: Always Steps to Reproduce: 1. Configure interface 2. Put interface up Actual Results: We get default route Expected Results: We don't get default route Additional info:
There are several ways to cause dhclient to use a different default route than that supplied by the DHCP "routers" option with dhclient-3.0.1-40_FC3: 1. Specifying $GATEWAYDEV in /etc/sysconfig/network : Then ONLY the dhclient session for the $GATEWAYDEV interface will set a default route from the DHCP "routers" option. There's nothing stopping you from specifying an interface that is never brought up, eg. 'GATEWAYDEV=eth7' - then no DHCP session will set the default route. 2. Specifying $GATEWAY in ifcfg-ethX : The dhclient session for ethX will set the default route to be via $GATEWAY IF the IP address and subnet mask received from DHCP match the subnet of $GATEWAY - else, no default route is set by the dhclient session for ethX . 3. Specifying 'supersede routers AAA.BBB.CCC.DDD;' in /etc/dhclient.conf : All dhclient sessions will attempt to set the default route to be via AAA.BBB.CCC.DDD on their interface and will ignore the routers option sent by DHCP . As there are quite a few ways to disable setting the default route with DHCP, no new ways are needed - hence, this bug is being closed as 'NOT A BUG'.