/etc/conf.d/net

Define network interface on Gentoo Linux systems. See /etc/sysconfig/network-scripts/ifcfg-eth0 for RedHat systems and /etc/network/interfaces for Ubuntu.

Dynamic IP Address (DHCP):

config_eth0=( "dhcp" )

Static IP Address:

config_eth0=( "192.168.149.36/24" ) routes_eth0=( "default via 192.168.149.2" ) # IPv4 default route

Change from DHCP client to Static or resetting static IP Address:

  1. Edit /etc/conf.d/net (shown above) as appropiate
  2. Run the following: ln -s net.lo /etc/init.d/net.<dev>
  3. Finally, test your changes by running, say, "ping www.google.com".