On 12/07/18 05:00, Gene Heskett wrote:
Greetings;

I have been playing the 10k monkeys scene trying to figure out how to add
a gateway entry to the route -n report on a rock64 with a stretch/xfce
install on it.

Where does this assignment belong in a static defined eth0 configuration?

I know several places where it doesn't work, but what I need to know is
where do I put, in what file, the "gateway = www.xxx.yyy.zzz" and make
it just work for a stretch install on a rock64.  Thats an arm64 family
card.

All I have been able to get out of route is the gibberishy help when
there is a syntax error.

The obvious (to me that is) place would be
in /etc/network/interfaces.d/eth0, which has this:

auto eth0
allow-hotplug eth0
iface eth0 inet static
address 192.168.71.2
netmask 255.255.255.0
gateway 192.168.71.1
dns-nameserver 192.168.71.1

Start off with ifconfig -a to check your interface names, if you've got eth1 rather than eth0 look in something like /etc/udev/rules.d/70*. Working in /etc/network/interfaces, simplify your config to something like

allow-hotplug eth0
iface eth0 inet static
        address 192.168.71.2/24
        gateway 192.168.71.1
        dns-nameserver 192.168.71.1
        post-up echo ifup > /tmp/eth0

Note that for the dns-nameserver to work you'll need the resolvconf package.

Look for /tmp/eth0 which should contain a message telling you that the "post-up" ran. If it's not there find what's going wrong, there's a file which in principle tells NetworkManager to never under any circumstances touch an interface but TBH I've yet to find a circumstance in which NM is less trouble than it's worth and very often I just tell systemd not to run it.

--
Mark Morgan Lloyd
markMLl .AT. telemetry.co .DOT. uk

[Opinions above are the author's, not those of his employers or colleagues]

Reply via email to