понедельник, 14 июля 2014 г.

static ip LINUX

sudo apt-get update 
sudo apt-get upgrade
  1. ifconfig
  2. sudo nano /etc/network/interfaces
    auto eth0
    iface eth0 inet static
    address 192.168.1.150
    netmask 255.255.255.0
    network 192.168.2.0
    broadcast 192.168.1.255
    gateway 192.168.2.1
    safe
    
  3. sudo nano /etc/resolv.conf
    Do not edit this file by hand --your changes will be overwritten
    # I add this 
    nameserver 8.8.8.8
    nameserver 8.8.4.4
    
  4. sudo apt-get remove dhcp-client
  5. sudo /etc/init.d/networking restart
    *Running /etc/init.d/networking restart is deprecated because it may 
    not enable again some interfaces
    *Reconfiguring network interfaces...
    ssh stop/waiting
    ssh start/running,process 1438

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

Отправить комментарий