M
M
Mark2017-10-20 20:04:05
linux
Mark, 2017-10-20 20:04:05

Static address in Ubutu Server 16.* How to set up?

What could be easier than setting up a static address in Ubuntu?
I've done this before and it worked. But now, in version 16, something went wrong. There are thousands of identical recipes to be found. Here, the first one and others ... says that I am doing everything right, as I did before.
But the command ip addrshows that the interface simply does not have an address, ifconfig -asays that everything is in order (only, again, only the MAC shows). What am I doing wrong? Or rather - what has changed in version 16, that the good old editing /etc/network/interfaces is useless and does not want to work, unless it is worth it auto?
Of course there is no ping. The system is freshly installed and I only changed the address (I started with this).

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexey Cheremisin, 2017-10-20
@engelson

Everything is fine in ubuntu 16!
pi prescribe the interface and prescribe auto . Just auto is what you need to launch the interface on boot.

auto eth0
iface eth0 inet static
        address XX.XX.XX.XX
        netmask 255.255.192.0
        gateway YY.YY.YY.YY
        up ip addr add 10.19.0.5/16 dev eth0
        dns-nameservers 8.8.8.8 8.8.4.4

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question