Setting IP on Linux there are two, namely a temporary (On the fly), and which is permanent. On the fly means is that if we restart the computer before the settings will be lost / returned to the initial setting. while the permanent is when the computer is restarted then the Ip settings will not be lost.
to set the IP on the eth0 interface with IP 192.168.10.1 temporary way is:
entered the terminal, then run the command
entered the terminal, then run the command
sudo ifconfig eth0 192.168.10.1
while for a permanent way:
entered the terminal, then run the command
entered the terminal, then run the command
sudo gedit / etc / network / interfaces
after that, to set the IP on the eth0 interface with IP 192.168.10.1, how to add a line like this:
auto eth0
iface eth0 inet static
address 192.168.10.1
netmask 255.255.255.0
network 192.168.10.0
broadcast 192.168.10.255
iface eth0 inet static
address 192.168.10.1
netmask 255.255.255.0
network 192.168.10.0
broadcast 192.168.10.255
klik SAVE, kemudian klik EXIT
setelah itu restart service networking dengan cara
setelah itu restart service networking dengan cara
sudo /etc/init.d/networking restart
so, good luck