{"id":50,"date":"2013-01-23T22:29:53","date_gmt":"2013-01-23T22:29:53","guid":{"rendered":"http:\/\/www.incredigeek.com\/home\/?p=50"},"modified":"2013-06-06T18:24:21","modified_gmt":"2013-06-06T18:24:21","slug":"how-to-set-a-static-ip-address-in-ubuntu-and-debian","status":"publish","type":"post","link":"https:\/\/www.incredigeek.com\/home\/how-to-set-a-static-ip-address-in-ubuntu-and-debian\/","title":{"rendered":"How to set a Static IP Address in Ubuntu and Debian"},"content":{"rendered":"<p>The first thing we need to do, is open our interfaces file.\u00a0 Execute the following from a terminal.<\/p>\n<pre>sudo vi \/etc\/network\/interfaces<\/pre>\n<p>or<\/p>\n<pre>sudo nano \/etc\/network\/interfaces<\/pre>\n<p>Then add or copy and paste the following.<\/p>\n<pre>auto eth0\r\niface eth0 inet static\r\n        address 192.168.1.100\r\n        netmask 255.255.255.0\r\n        network 192.168.1.0\r\n        broadcast 192.168.1.255\r\n        gateway 192.168.1.1<\/pre>\n<p>Close the file. Now we need to change the DNS settings<\/p>\n<pre>sudo vi \/etc\/resolv.conf<\/pre>\n<p>or<\/p>\n<pre>sudo nano \/etc\/resolv.conf<\/pre>\n<p>Edit the nameserver line to something like the following.<\/p>\n<pre>nameserver 8.8.8.8<\/pre>\n<p>Close the file and then restart the networking stuff.<\/p>\n<pre>sudo \/etc\/init.d\/networking restart<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>The first thing we need to do, is open our interfaces file.\u00a0 Execute the following from a terminal. sudo vi \/etc\/network\/interfaces or sudo nano \/etc\/network\/interfaces Then add or copy and paste the following. auto eth0 iface eth0 inet static address &hellip; <a href=\"https:\/\/www.incredigeek.com\/home\/how-to-set-a-static-ip-address-in-ubuntu-and-debian\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4,45,3,21,28],"tags":[51,7,50,49],"class_list":["post-50","post","type-post","status-publish","format-standard","hentry","category-command-line","category-internet","category-linux","category-networking","category-ubuntu","tag-debian","tag-linux-2","tag-static-ip","tag-ubuntu-2"],"_links":{"self":[{"href":"https:\/\/www.incredigeek.com\/home\/wp-json\/wp\/v2\/posts\/50","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.incredigeek.com\/home\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.incredigeek.com\/home\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.incredigeek.com\/home\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.incredigeek.com\/home\/wp-json\/wp\/v2\/comments?post=50"}],"version-history":[{"count":4,"href":"https:\/\/www.incredigeek.com\/home\/wp-json\/wp\/v2\/posts\/50\/revisions"}],"predecessor-version":[{"id":55,"href":"https:\/\/www.incredigeek.com\/home\/wp-json\/wp\/v2\/posts\/50\/revisions\/55"}],"wp:attachment":[{"href":"https:\/\/www.incredigeek.com\/home\/wp-json\/wp\/v2\/media?parent=50"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.incredigeek.com\/home\/wp-json\/wp\/v2\/categories?post=50"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.incredigeek.com\/home\/wp-json\/wp\/v2\/tags?post=50"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}