Escribes en /etc/network/interfaces
:
auto eth0
iface eth0 inet static
address 192.0.2.7
netmask 255.255.255.0
gateway 192.0.2.254
El valor del netmask y gateway instala net-tools
.
El gateway se saca con ip route
. Y el netmask con ifconfig
Para reiniciar la configuración o hacer un reboot:
service networking restart