Debian / Ubuntu Static Local IP

If your a Linux Power User, like me, you use SSH quite frequently. Don’t you hate it when you know the IP of the device you want to access, but all of a sudden the IP changes? That’s because your using DHCP, which is what your router generally defaults to. Look inside to find out more…….

Having a static IP is also necessary for server applications. If I, for example, were to host an Apache2 website on my Ubuntu Server, it would be impossible for me to do the correct port forwarding without a static IP address.

How to do it

Giving your Raspberry Pi a static IP is easy, and can be done without much hassle at all.

sudo nano /etc/network/interfaces

Clear all of the contents of the file, and copy the contents below – while filling in all of the necessary details.

iface eth0 inet static
address (IP you wish to set)
gateway (IP of Router)
nameserver (IP of Router)

If you have a Cisco router, like me, your default IP address is . This is also the case with several other manufactures.  A simple Google search will result you with the correct IP.  You could also use Fing, a network scanner for iOS, that’s become incredibly handy for me.


3 thoughts on “Debian / Ubuntu Static Local IP

  1. Hey just wanted to give you a quick heads up and let you know a few
    of the images aren’t loading correctly. I’m not sure why but I
    think its a linking issue. I’ve tried it in two different internet browsers and both show the same outcome.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s