How to assign a static IP address in Ubuntu
Setting a static IP address in Ubuntu involves editing /etc/network/interfaces. If the interface is currently using DHCP, you will find these lines in the file.
iface lan inet dhcp
You will have to replace the above lines with a section that looks like:
iface lan inet static
Make the changes effective by either rebooting or by issuing this command:
sudo /etc/init.d/networking restart