Static DNS and IP address allocation

Open network configuration file $ sudo vi /etc/network/interfaces or $ sudo nano /etc/network/interfaces

Find and remove dhcp entry: iface eth0 inet dhcp

Append new network settings:

  iface eth0 inet static
  address 192.168.1.100
  netmask 255.255.255.0
  network 192.168.1.0
  broadcast 192.168.1.255
  gateway 192.168.1.254`

Edit /etc/dhcp3/dhclient.conf ··· gksu gedit /etc/dhcp3/dhclient.conf ··· put your numbers, looks like this->

prepend domain-name-servers 208.67.220.220, 208.67.222.222;

(that setup is if you wanted to use opendns)

And restart the network manager, then check the result:

  daniel@daniel-laptop:/etc$ cat resolv.conf
  # Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
  # DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN

  daniel@daniel-laptop:/etc$