Eu prefiro vim em vez de gato. Veja como eu defino IPs estáticos no dia a dia:
Obtenha e instale o vim (se necessário):
sudo apt-get install vim
Abra para editar o arquivo de interfaces de rede:
vi /etc/network/interfaces
Faça alterações no arquivo de interfaces de rede para aparecer da seguinte forma: usei 192.168.10.10 como o IP estático no exemplo.
auto enp2s0
iface enp2s0 inet static
address 192.168.10.10
netmask 255.255.255.0
network 192.168.10.0
broadcast 192.168.10.255
gateway 192.168.10.1
dns-nameservers 192.168.10.111
Em seguida, reinicie o serviço como faria normalmente ou como faria:
sudo ifdown enp2s0
espere
sudo ifup enp2s0
Agora verifique seu ifconfig e você deverá ver o IP estático
ifconfig
Boa sorte e aproveite!
Se isso não funcionar, desligue e ligue novamente todas as interfaces de rede com sudo ifdown -a
e sudo ifup -a