I have a dynamic IP through DHCP.
I've edited the /etc/network/interfaces file to this:
# This file describes the network interfaces available on your system
and how to activate them. For more information, see interfaces(5).
source /etc/network/interfaces.d/*
# The loopback network interface
auto lo
iface lo inet loopback
# The primary network interface
auto enp1s0
iface enp1s0 inet static
address 192.168.0.200
netmask 255.255.255.0
network 192.168.0.0
broadcast 192.168.0.255
gateway 192.168.0.1
dns-nameservers 192.168.0.1 0.0.0.0
And I've tried the following commands:
- systemctl restart ifup@enp1s0
- systemctl restart ifup@eth0
- sudo service network-manager restart
but none of them do what I want them to do, after entering ifconfig
I keep seeing my dynamic IP of 192.168.0.30 coming up... What am I doing wrong?
(I'm ssh'ing into the machine using the dynamic IP address and for now I have a portforwarding rule based on the old rule, but I'd really like to have it static. I've chosen 200 to be waaaay out of range for anyone else to snatch it up).