Re: [systemd-devel] How can I prevent systemd.network from auto-deleting my manually-assigned static IPv4 addresses?

2023-09-14 Thread Ian Pilcher

On 9/13/23 17:32, Jeremy Friesner wrote:
This all works fine and has for a long time; the problem is that the new 
version of the device is running systemd.networkd and networkd has some 
functionality in it where it detects when an Ethernet device has lost 
its carrier, and responds by removing all the IPv4 addresses associated 
with that Ethernet device.


Why are you running systemd-networkd at all?

--

Google  Where SkyNet meets Idiocracy





[systemd-devel] mDNS Packet truncation support in systemd

2023-09-14 Thread Vishwanath Chandapur
Hi,

We have a couple of observations on packet truncation for systemd mdns
packets.

1.As querier  systemd supports packet truncation for mdns packets.
2.As responder systemd does not process the packets enabled with truncation

Ideally as part of  rfc 6762 7.2 recommends to support packet truncation
for both query and responder .

Is there any specific reason responder doesn't does not process the packets
 with truncation?

With Regards
Vishwa


Re: [systemd-devel] DynamicUser=yes leads to "Too many levels of symbolic links" for /etc/.pwd.lock

2023-09-14 Thread Lennart Poettering
On Do, 14.09.23 03:50, Muggeridge, Matt (matt.muggerid...@hpe.com) wrote:

> $ ls -l /etc/.pwd.lock
>
> lrwxrwxrwx 1 root root 19 Apr  5  2011 /etc/.pwd.lock -> sysconfig/.pwd.lock
>
> $ ls -l /etc/sysconfig/.pwd.lock
>
> -rw--- 1 root root 0 Aug 16 07:25 /etc/sysconfig/.pwd.lock
>
> For the purpose of investigation, I configured an overlay so /etc/.pwd.lock 
> was a simple writeable file (not a read-only symlink) and the service starts.
>
> Why is systemd complaining about the file being a symlink?

It's supposed to be a lock file, i.e. a regular file we issue POSIX file
locks on. It's not a config file.

The problem with symlinks for things like this is that in various
contexts these files are atomically replaced, and if that happens then
symlinks just make a mess, since it's not clear whether to replace the
symlink or its target.

Hence, we don't support that.

Generally, things like /etc/passwd is API pretty much, you cannot
really change it to a be a symlink (unless you make it fully
immutable), since it is updated by various tools and these tools tend
to do atomic updates of these files, i.e. when updating they write a
new file under a temporary name/O_TMPFILE, and then atomically move
it over the old file, so that other clients either get the old version
or the new version but never a half-updated version. This kind of
updating is really how you have to do things on UNIX, but that means
symlinks are out of the question...

Hence, TLDR: don't make the lock file a symlink. (Also, why would you even?)

Lennart

--
Lennart Poettering, Berlin