How to change Ubuntu network from DHCP to Static IP Address

  • Open the /etc/network/interfaces file :-

        ==> sudo nano /etc/network/interfaces

  • You can see the following lines in interfaces file :-

        ==> auto eth0
                iface eth0 inet dhcp

  • Change the following lines :-

        ==> auto eth0
                iface eth0 inet static
                address 192.168.1.11
                netmask 255.255.255.0
                network 192.168.1.0
                broadcast 192.168.1.255
                gateway 192.168.1.1
                dns-nameservers 8.8.8.8

Reboot your system for change Network.

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top