ComTech: IT Support Stirling
TwitterFacebookGoogle

How to set a static ip address in Linux


Today I will show you how to set a static ip address in Linux.  Because my main system is Linux Mint 11 I will also show you the GUI way for gnome based distributions.

The following steps work on any distribution

Open up a terminal and type:

sudo nano /etc/network/interfaces

Find the following lines;

auto eth0
iface eth0 inet dhcp

and replace with;

auto eth0
iface eth0 inet static
address 192.168.1.100
netmask 255.255.255.0
gateway 192.168.1.1
dns-nameservers 192.168.1.1
broadcast address 192.168.1.255

where address, netmask and gateway are set using addresses relevant to your network. Restart the system and that is it.

GUI for Gnome and Cinnamon

(Unity is the same method but the icon is top right instead)

1. Right click on your internet connection (bottom right of screen) and chose edit connections.

2. Chose your connection from the list and click Edit.

3. Click on the IPv4 Settings tab.

4. Change method from DHCP to manual.

5. Enter your details for address, netmask and default gateway.

6. Add an address for your DNS server and click apply.

7. Restart your system for changes to take effect.

About the Author

Hi I am Chris Wakefield the owner of ComTech IT Support. I provide Windows, Linux and Mac based IT Support to small businesses throughout the Stirling, Falkirk and Alloa areas.

For a list of what I can offer you why not visit my website www.comtech247.net where you will find a list of my services, testimonials, blog and much more.

 

CyberChimps
Follow

Get every new post delivered to your Inbox

Join other followers

WordPress SEO fine-tune by Meta SEO Pack from Poradnik Webmastera
WP Like Button Plugin by Free WordPress Templates