03.02.2014

IP

/etc/network/interfaces

# interfaces(5) file used by ifup(8) and ifdown(8)

auto lo 
iface lo inet loopback 

############################
# MAIN interface
auto eth0 
allow-hotplug-eth0 
#iface eth0 inet dhcp
iface eth0 inet static
   address 10.10.10.10 
   netmask 255.255.255.0 
   gateway 10.10.10.254
   network 10.10.10.0
   broadcast 10.10.10.255
   dns-nameservers 127.0.0.1

############################
# 3G-modem
auto eth1 
allow-hotplug-eth1 
iface eth1 inet dhcp

############################
# From mobile
auto usb0 
allow-hotplug-usb0
iface usb0 inet dhcp

############################
# route delete default 
# route add default gw 192.168.0.1 
# /etc/init.d/networking restart
# ifdown eth0
# ifup eth0
# For Ubuntu: ifdown --exclude=lo -a && ifup --exclude=lo -a

Комментариев нет: