[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: debian12: something destroys /etc/network/interfaces at boot



Thank your for your quick and detailed reply.

On Tue, Mar 26, 2024 at 7:01 PM Greg Wooledge <greg@wooledge.org> wrote:
> On Tue, Mar 26, 2024 at 06:33:42PM +0100, Steffen Dettmer wrote:
> > I changed a gateway on a remote site using /etc/network/interfaces by
> > changing gateway. However, at reboot some old gateway IP reappears.
>
> So then the question is *which* of the many different subsystems is in
> use to set the system's default gateway.  It might be coming from /e/n/i
> or from NetworkManager or from systemd-networkd or others.

Yes, but I found nothing in any logfile, the IP did not appear anywhere
in the file system and I had no idea what to do...

It turned out the machine actually is a virtualisation container
and the infrastructure configures the IP (which was incorrectly set in the
virtualization web GUI). Well, and I didn't see this, but
fortunately Pierre-Elliott Bécue (from this list) saw it instead.

> > root@site4-nas:~# ls -l /etc/network/interfaces
> > -rw-r--r-- 1 root root 117 Mar 26 18:19 /etc/network/interfaces
> > root@site4-nas:~# grep gateway /etc/network/interfaces
> >         gateway 192.168.2.43
>
> See, that's not useful.  That's not how this file is structured.  It's
> NOT just a series of independent lines.

Yes, thanks, sure, I know. I just wanted to show that it does change
automagically at reboot (it is written by virtualisation environment
when the container is being started). The stanza was correct,
just gateway IP was wrong, because someome made an error
in the container configuration and it just so happend that it was
my little foot where it fell onto...

Best regards,
Steffen


Reply to: