Re: [systemd-devel] CPUAffinity=all ?

2023-03-23 Thread Mantas Mikulėnas
My wild guess would be "no", in order to remain compatible with CPUs that might be added to the system at runtime. On Thu, Mar 23, 2023, 23:00 Etienne Champetier wrote: > Le jeu. 23 mars 2023 à 16:37, Etienne Champetier > a écrit : > > > > Hello, > > > > I'm setting `CPUAffinity=0-1` in /etc/sy

Re: [systemd-devel] Unsubscribing doesn't work.

2023-03-23 Thread Mantas Mikulėnas
h rejected. > > >> > > >> I tried also subscribing via the maillist web site form. That also > hasn't unsubscribed me. > > >> > > >> Can someone please tell me the correct way to unsubscribe from this > list? > > > You need to unsubscribe through the web interface. > > > > > > Zbyszek > -- Mantas Mikulėnas

Re: [systemd-devel] automount fails but mount does not

2023-03-14 Thread Mantas Mikulėnas
/sync': Permission denied > ``` > > But I can touch that dir as my user. > > Any ideas of what might be wrong? > An automount placeholder is, itself, a special kind of mount – as long as the .automount unit is active, the path is no longer owned by you because the "sync" directory has an 'autofs' filesystem mounted on top of it. (See `findmnt`.) -- Mantas Mikulėnas

Re: [systemd-devel] How to start a service when a device is created under /dev/pts/

2023-02-13 Thread Mantas Mikulėnas
On Mon, Feb 13, 2023 at 5:16 PM Giuseppe Sacco wrote: > Hello Mantas, > > Il giorno lun, 13/02/2023 alle 14.32 +0100, Giuseppe Sacco ha scritto: > > Il giorno lun, 13/02/2023 alle 15.25 +0200, Mantas Mikulėnas ha scritto: > > > On Mon, Feb 13, 2023 at 3:21 PM Giu

Re: [systemd-devel] How to start a service when a device is created under /dev/pts/

2023-02-13 Thread Mantas Mikulėnas
On Mon, Feb 13, 2023 at 3:21 PM Giuseppe Sacco wrote: > Il giorno lun, 13/02/2023 alle 12.12 +0200, Mantas Mikulėnas ha > scritto:[...] > > I'm not entirely sure whether it even makes sense for a .service unit > > to wait for a specific pty? I mean, the entire design of p

Re: [systemd-devel] User wayland session, conceptual questions

2023-02-13 Thread Mantas Mikulėnas
On Sun, Feb 12, 2023 at 9:27 AM Vladimir Kudrya wrote: > On 10/02/2023 12.51, Mantas Mikulėnas wrote: > > Also systemd.special manual recommends putting display servers into >> session.slice. But in case of a wayland compositor it is impossible to >> separate it from

Re: [systemd-devel] How to start a service when a device is created under /dev/pts/

2023-02-13 Thread Mantas Mikulėnas
self, so there's no way for faxgetty@.service to be sure that pty/0 is your fax thing and not e.g. someone's xterm or an incoming SSH connection. What is supposed to be creating /dev/pts/0 in your case? It might be simplest to have the same software directly start faxgetty@.service as well. -- Mantas Mikulėnas

Re: [systemd-devel] User wayland session, conceptual questions

2023-02-10 Thread Mantas Mikulėnas
On Fri, Feb 10, 2023 at 12:27 PM Vladimir Kudrya wrote: > On 10/02/2023 12.51, Mantas Mikulėnas wrote: > > Also systemd.special manual recommends putting display servers into >> session.slice. But in case of a wayland compositor it is impossible to >> separate it from

Re: [systemd-devel] User wayland session, conceptual questions

2023-02-10 Thread Mantas Mikulėnas
On Fri, Feb 10, 2023, 00:11 Vladimir Kudrya wrote: > Hello everyone! > > As an experiment I wrote a session manager for standalone wayland > compositors that utilizes systemd user-level daemon features for graphical > sessions: https://github.com/Vladimir-csp/uwsm > > It can either manage targets

Re: [systemd-devel] systemd-networkd: Failure to add slave interface to bridge

2023-01-31 Thread Mantas Mikulėnas
r=GetConnectionUnixUser cookie=52 reply_cookie=0 signature=s > error-name=n/a error-message=n/a > Jan 31 11:06:35 sarkovy systemd-networkd[1294]: Got message > type=method_return sender=org.freedesktop.DBus destination=:1.12 > path=n/a interface=n/a member=n/a cookie=4294967295 reply_cookie=52 > signature=u error-name=n/a error-message=n/a > > > These are the contents of /etc/systemd/network/50-vpn.network: > > [Match] > Name = vpn_* > > [Link] > RequiredForOnline = no > ActivationPolicy = up > ARP = no > > [Network] > Description = VPN interface > DHCP = no > DHCPServer = no > LinkLocalAddressing = no > DefaultRouteOnDevice = no > LLMNR = no > IPv6AcceptRA = no > Bridge = br_lan > > -- Mantas Mikulėnas

Re: [systemd-devel] systemd-homed: Change group membership without root and user passwords

2023-01-20 Thread Mantas Mikulėnas
rd ? > > Usually its an admin task to maintain group membership and she has no > user passwords. > > But when its the users task to join a group, the user needs the admin > password, this is also a bad situation. > > Is it possible to add more than one password ? > > /eric > > -- Mantas Mikulėnas

Re: [systemd-devel] [Question] How to make services only see only one external network interface and loopback

2023-01-17 Thread Mantas Mikulėnas
There's no single service option to do this, as far as I know, since it involves a bit more than just making the interface visible. After PrivateNetwork is enabled, the newly created namespaces need to be explicitly given network access through the host; the same "external" interface can't exist i

Re: [systemd-devel] Systemd sessionid like `c508`

2023-01-10 Thread Mantas Mikulėnas
The sessions listed in loginctl are created and their IDs assigned by systemd-logind (when asked by pam_systemd). If /proc/*/loginuid and /proc/*/sessionid are available (set up by pam_loginuid), then logind directly takes the audit session ID as logind session ID. If those are not available (ker

Re: [systemd-devel] Syslog forwarding not working within journal namespace

2022-12-28 Thread Mantas Mikulėnas
ck" Socket="/run/systemd/journal.my-namespace/syslog") > > I guess with this rsyslog manages the socket, creating it if it doesn't > exist. > It seems like magic to me though. I didn't configure anything else. How > does journald know to write to this

Re: [systemd-devel] Syslog forwarding not working within journal namespace

2022-12-28 Thread Mantas Mikulėnas
to setup an additional socket at > /run/systemd/journal.my-namespace/syslog to forward logs to syslog from my > own namespace. Can you point me to the documentation for how I should do > this? > > > On Wed, Dec 28, 2022 at 2:32 AM Mantas Mikulėnas > wrote: > >> The forwar

Re: [systemd-devel] Syslog forwarding not working within journal namespace

2022-12-27 Thread Mantas Mikulėnas
nal.conf which has forwarding enabled by default. I can see > the > logs in the journal with journalctl --namespace my-namespace. > > I haven't seen any bugs reported on this so I must be missing something. > > Regards, > > Aaron > > -- Mantas Mikulėnas

Re: [systemd-devel] missed _netdev option for nfs

2022-11-30 Thread Mantas Mikulėnas
7;t stored, as it has no use after the mount has already happened.) -- Mantas Mikulėnas

Re: [systemd-devel] Antw: Re: Antw: [EXT] [systemd???devel] starting networking from within single user mode?

2022-11-14 Thread Mantas Mikulėnas
not a > hyphen. > proc_cmdline_key_streq() treats - and _ as identical (behaving like kernel options, I believe). -- Mantas Mikulėnas

Re: [systemd-devel] Antw: [EXT] [systemd???devel] starting networking from within single user mode?

2022-11-14 Thread Mantas Mikulėnas
that option. Is that a kind of target, or what is the > mechanism? > Which of the 196 (man -k systemd | wc -l) systemd-related manual pages > would describe it? ;-) > The more I read your smartass sarcastic comments here, the less I feel like staying on this list and helping *other* people with finding stuff in those 196 systemd-related manual pages. But I suppose that's what you want to achieve, so that you can snark even more about how "systemd is so complex that nobody's bothering to reply to the list anymore"? For those who have *actually* never heard of that option, it is documented in systemd-debug-generator(8). -- Mantas Mikulėnas

Re: [systemd-devel] Antw: [EXT] [systemd???devel] starting networking from within single user mode?

2022-11-11 Thread Mantas Mikulėnas
lored 'upgrading' a running (slight older) SP5 box, using > this trimmed-down list. A purposeful side effect was to uninstall > RPMs not in that trimmed-down list. > > This latter box begins to boot, and gets at least as far as loading > the initrd image, before hanging. > Boot with "systemd.debug-shell" and use tty9 to investigate from the inside. -- Mantas Mikulėnas

Re: [systemd-devel] starting networking from within single user mode?

2022-11-10 Thread Mantas Mikulėnas
P address, add a default route (dhclient or dhcpcd will also work without udev, while systemd-networkd probably won't). ip link set eth0 up ip addr add 192.168.1.55/24 dev eth0 ip route add default via 192.168.1.1 -- Mantas Mikulėnas

Re: [systemd-devel] Support for unmerged-usr systems will be REMOVED in the second half of 2023

2022-11-05 Thread Mantas Mikulėnas
On Sat, Nov 5, 2022 at 12:52 PM TJ wrote: > On 05/11/2022 10:36, Mantas Mikulėnas wrote: > > On Sat, Nov 5, 2022 at 12:06 PM TJ wrote: > > > >> Just seen this announcement in the v252 changelog: > >> > >> "We intend to remove support for spli

Re: [systemd-devel] Support for unmerged-usr systems will be REMOVED in the second half of 2023

2022-11-05 Thread Mantas Mikulėnas
port for having the rootfs itself mount /usr halfway through, which requires many things that normally are on /usr/lib to be split between it and /lib instead (such as on Debian). Using the initrd to mount /usr isn't new. <https://web.archive.org/web/20150906203654if_/https://www.gentoo.org/support/news-items/2013-09-27-initramfs-required.html> -- Mantas Mikulėnas

Re: [systemd-devel] How to get a useful peer address when doing accept(3, ...) on a systemd supplied listening socket

2022-10-27 Thread Mantas Mikulėnas
tested with `systemd-socket-activate --listen=`: https://gist.github.com/grawity/63369273742f23b596d764cb6d45feb7 > > If mydaemon creates the listening socket, I can easily get the peer > address. > > I suspect that when systemd creates the listening socket then > accept(3,...) returns a socket which is connected to a local socket created > by systemd. > > QUESTION: Is that suspicion correct? > No, it isn't. > -- Mantas Mikulėnas

Re: [systemd-devel] Antw: Re: [EXT] Finding network interface name in different distro

2022-10-19 Thread Mantas Mikulėnas
eno1 & ens4f0np1 is actual systemd naming. -- Mantas Mikulėnas

Re: [systemd-devel] Is it possible to let systemd create a listening socket and yet be able to have that socket activate nothing, at least temporarily?

2022-10-07 Thread Mantas Mikulėnas
ome/me/mydaemon/. > Deploy the new version of your daemon to another location (/home/me/mydaemon.new/), perform all processing/conversions that are necessary, *then* stop the socket, `mv mydaemon mydaemon.old`, stop the service, `mv mydaemon.new mydaemon`, start the socket again. The interval for this will be more like half a second than a minute. -- Mantas Mikulėnas

Re: [systemd-devel] bond for wlan/lan failover: hook for dhcp changes?

2022-09-29 Thread Mantas Mikulėnas
lient to Restart=always. However, this > interrupts even working openvpn client sessions every 60 sec of > inactivity. > > Thanks for any pointers... > > -- Mantas Mikulėnas

Re: [systemd-devel] "Failed to connect to bus: No such file or directory" when running systemd --user commands with runuser as root

2022-09-19 Thread Mantas Mikulėnas
o?noredirect=1#comment2491580_1430191 > > This seems like odd behavior so I am not sure why this is happening. Can > anyone help? > > - Dave > > > -- Mantas Mikulėnas

Re: [systemd-devel] systemd service causing bash to miss signals?

2022-09-19 Thread Mantas Mikulėnas
Pipelines somewhat rely on the kernel delivering SIGPIPE to the writer as soon as the read end is closed. So if you have `foo | head -1`, then as soon as head reads enough and exits, foo gets killed via SIGPIPE. But as most systemd-managed services aren't shell interpreters, systemd marks SIGPIPE a

Re: [systemd-devel] Can /usr/lib/systemd/user/sockets.target.wants be used to autoenable a socket by a vendor package?

2022-09-17 Thread Mantas Mikulėnas
quot; status) – instead it's because the unit doesn't match any .preset files that would disable it (i.e. it only matches the compiled-in default "enable *" preset), and therefore systemctl *would create *a .wants/ symlink from the preset. -- Mantas Mikulėnas

Re: [systemd-devel] systemd-network and loopback

2022-09-09 Thread Mantas Mikulėnas
– on Linux it could be assigned to a Type=dummy interface or to an empty bridge, but just as frequently it's assigned to `lo`. (It's even called a "loopback address".) -- Mantas Mikulėnas

Re: [systemd-devel] Help required for configuring a blocking service during shutdown

2022-08-29 Thread Mantas Mikulėnas
.target might work for the ones in fstab?) Not sure how it works with Plymouth, but in its default console output, systemd itself will already show which services are waiting to be stopped. Syslog (journald) should be available the entire time. The backup system should also run under `systemd-inhibit --what=shutdown` as an additional layer of precaution – that way the user will know that something is still running *before* they initiate the actual shutdown. -- Mantas Mikulėnas

Re: [systemd-devel] logind: discontinuous TTYs?

2022-08-26 Thread Mantas Mikulėnas
nd tty12. I know I can set NAutoVTs to 12, but how to disable getties > on tty2..tty11? > > Regards, > T. > -- Mantas Mikulėnas

Re: [systemd-devel] logging for socket-based services

2022-08-22 Thread Mantas Mikulėnas
ing as expected but my logs are now flooded > with "systemd: Started ..." messages. Is there any way to tune the logging > for these services to filter out these entries? > -- Mantas Mikulėnas

Re: [systemd-devel] [EXT] Re: org.freedesktop.timedate1.NTPSynchronized not signaled: rationale?

2022-08-18 Thread Mantas Mikulėnas
> > signal; looks like it *almost* does > > (org.freedesktop.timesync1.Manager.NTPMessage) but it looks like it only > > emits the raw messages and not whether they resulted in a successful > sync. > > Maybe because a "successful sync" is actually not sharply defined. > There can be very interesing scenarios (like requiring three "surviving > clocks", but only two were found) > It's an SNTP client, it only deals with one timeserver at a time. And it already has a specific definition of "synced" in the code because it sets a flag file on the filesystem when that happens, just doesn't do the same via D-Bus. -- Mantas Mikulėnas

Re: [systemd-devel] org.freedesktop.timedate1.NTPSynchronized not signaled: rationale?

2022-08-17 Thread Mantas Mikulėnas
if you're using timesyncd you can use inotify to watch /run/systemd/timesync/synchronized, which is touched after a sync. -- Mantas Mikulėnas

Re: [systemd-devel] Detecting when running under systemd

2022-08-16 Thread Mantas Mikulėnas
o disabling the timestamps you should *at least* add message priority indicators as well, either by using SyslogLevelPrefix=, or by avoiding stderr entirely and using the syslog() API for logging – if not going all the way with sd_journal_send*().) -- Mantas Mikulėnas

Re: [systemd-devel] How can we debug systemd-gpt-auto-generator failures?

2022-07-28 Thread Mantas Mikulėnas
-pid1 processes). Since it uses libblkid, there's also LIBBLKID_DEBUG=all. -- Mantas Mikulėnas

Re: [systemd-devel] Prefix delegation and IPv6 subnetting

2022-07-08 Thread Mantas Mikulėnas
On Fri, Jul 8, 2022, 09:22 Andrei Borzenkov wrote: > On 07.07.2022 18:25, Bent Bagger wrote: > > > > The prefix delegation problem starts with the interactions between net0 > > and net2. Net0 is delegated a /56 prefix from the main router (which > > runs radvd and dhcpd6, not networkd, for histor

Re: [systemd-devel] Waiting for network routes to appear

2022-06-15 Thread Mantas Mikulėnas
I think it's better to use a custom tool. RequiresMountsFor relies on knowing the exact mount points from the beginning and just waiting for them to be done – but that might not exactly match networking, where you might have two /24 routes today and a /23 tomorrow, so you can't exactly predefine th

Re: [systemd-devel] Q: Start network in chroot?

2022-06-13 Thread Mantas Mikulėnas
l)? Because you don't have systemd as init while inside a chroot. 2) How can I start the network using systemd? > Start it outside the chroot. -- Mantas Mikulėnas

Re: [systemd-devel] Why are journal files stored in machine-specific directories?

2022-05-26 Thread Mantas Mikulėnas
On Thu, May 26, 2022, 16:27 Jakub Piecuch wrote: > Hello, > > I'm wondering why journald stores journal files under > /var/log/journal/$MACHINE_ID instead of just /var/log/journal. > It allows logs from remote systems to be collected using ordinary rsync or NFS or other file-based tools. Similar

Re: [systemd-devel] certificate and trust store feature for systemd

2022-05-26 Thread Mantas Mikulėnas
and OS X? > > > > I still find the management of PKIs in /etc/pki to be problematic. > > > > Having this available as a core service within systemd using like APIs > either in (mostly deprecated) CAPI or the new CNG > This sounds more like the area of p11-kit, rather than systemd. -- Mantas Mikulėnas

Re: [systemd-devel] resolved vs. DNS servers listening on Linux dummy interfaces

2022-05-09 Thread Mantas Mikulėnas
On Mon, May 9, 2022, 16:35 Peter Mattern wrote: > Hi, Petr. > > > Do you need any systemd-resolved specific features? > Primarily, it's about the way directive Domains allows for directing > queries to particular DNS servers based on the queries' domains. > I'm using it to restrict the ISP's DNS

Re: [systemd-devel] [systemd] Behavior of "Requires" and "After" in service unit

2022-05-08 Thread Mantas Mikulėnas
s for services where systemd waits for the main process to start *and finish* (e.g. for services that perform a single update and don't have a daemon at all). It sounds a bit like it would be the right choice for swupdate-usb, but it's never correct to use oneshot for daemons like swupdate-core. -- Mantas Mikulėnas

Re: [systemd-devel] [EXT] Re: Q: logger: "invalid structured data parameter: 'fo\o="b\"a\"r"'"

2022-05-02 Thread Mantas Mikulėnas
Sorry, I was confused by the "-systemd" suffix. > I don't know how SLES works, but this sounds like they have two builds of util-linux, one with libsystemd (for logger --journal) and another without. Either way, it should have no relation to the --rfc5424 mode. -- Mantas Mikulėnas

Re: [systemd-devel] Q: logger: "invalid structured data parameter: 'fo\o="b\"a\"r"'"

2022-05-02 Thread Mantas Mikulėnas
On Mon, May 2, 2022 at 11:40 AM Ulrich Windl < ulrich.wi...@rz.uni-regensburg.de> wrote: > Hi! > > If I understand it corrctly the logger from > util-linux-systemd-2.33.2-4.18.1.x86_64 of SLES12 is part of systemd; if > not, > It's not. It's part of util-linux. -- Mantas Mikulėnas

Re: [systemd-devel] Starting transient services securely from other service without root

2022-04-28 Thread Mantas Mikulėnas
1:8.2.0-4 /usr/share/polkit-1/rules.d/50-libvirt.rules community/libvirt-dbus 1.4.1-2 /usr/share/polkit-1/rules.d/libvirt-dbus.rules community/packagekit 1.2.5-1 /usr/share/polkit-1/rules.d/org.freedesktop.packagekit.rules I found a bugzilla about this: https://bugs.freedesktop.org/show_bug.cgi?id=80921 -- Mantas Mikulėnas

Re: [systemd-devel] [systemd‑devel] Antw: [EXT] Re: Q: non‑ASCII in syslog

2022-04-28 Thread Mantas Mikulėnas
/dev/log listener, so including journald) *parses and rebuilds* the entries that come from the API before storing them anywhere. Whether you use rsyslog or syslog-ng, they don't just dump program-provided data to /var/log – they both parse the input into date + hostname + pid + message, then reformat according to whatever output format is specified. (For example, we have syslog-ng configured to write RFC3339 timestamps.) Journald also does the same by design. -- Mantas Mikulėnas

Re: [systemd-devel] [EXT] Re: Q: non-ASCII in syslog

2022-04-28 Thread Mantas Mikulėnas
ever. > Still outside the scope of systemd. Systemd doesn't send RFC 3164 messages over the network, either. > > > > > Generally, if a message successfully decodes as UTF-8 then it's most > likely > > actual UTF-8 (and if UTF-8 decode fails then you fall back to ISO8859-1). > > Various old systems get away with this without needing a UTF-8 BOM. > > Yes, you can just output what you received, hoping the messages will be > presented correctly. > I't just like sending 8-bit E-Mmail without a coding system or charset in > the > past. > Which is not what I was saying, but sure, whatever. -- Mantas Mikulėnas

Re: [systemd-devel] Q: non-ASCII in syslog

2022-04-27 Thread Mantas Mikulėnas
rder does. (Also, why RFC 3164 and not 5425?) Generally, if a message successfully decodes as UTF-8 then it's most likely actual UTF-8 (and if UTF-8 decode fails then you fall back to ISO8859-1). Various old systems get away with this without needing a UTF-8 BOM. -- Mantas Mikulėnas

Re: [systemd-devel] LogsDirectory= permissions

2022-04-20 Thread Mantas Mikulėnas
On Wed, Apr 20, 2022, 23:43 Lennart Poettering wrote: > On Mi, 20.04.22 22:18, Andrea Pappacoda (and...@pappacoda.it) wrote: > > > Hi! I've been playing around with various options documented in > > systemd.exec(5) recently, and I'm having an issue with `LogsDirectory=` > and > > its permissions.

Re: [systemd-devel] device unit files

2022-04-11 Thread Mantas Mikulėnas
hing up fast enough... Such delays for the mmcblk rootfs seem to be a frequent question both here on the list as well as on IRC, but I don't think I remember any specific answers. -- Mantas Mikulėnas

Re: [systemd-devel] Intercepting/Delaying the boot process

2022-04-08 Thread Mantas Mikulėnas
On Fri, Apr 8, 2022, 12:44 Andreas Hartmann wrote: > On Fri, 2022-04-08 at 12:07 +0300, Mantas Mikulėnas wrote: > > On Fri, Apr 8, 2022 at 10:08 AM Andreas Hartmann wrote: > > > > > > > > To this end I was wondering whether it would be feasible to "h

Re: [systemd-devel] Intercepting/Delaying the boot process

2022-04-08 Thread Mantas Mikulėnas
ssible for a service during early boot to command a system > shutdown > instead of continuing to boot? > - May I simply take control of the TTY and clear/rewrite it as I like, or > does > systemd use some magic for this? > > Thank you in advance! > > > hartan > > > -- Mantas Mikulėnas

Re: [systemd-devel] Antw: [EXT] Dropping split-usr/unmerged-usr support

2022-04-06 Thread Mantas Mikulėnas
nd "/lib => /usr/lib" symlinks as part of that reorganization, in 1989. (Though it still had a separate /sbin with barely anything except 'init' and 'mount' inside.) -- Mantas Mikulėnas

Re: [systemd-devel] [EXT] Re: Q: journalctl -b -g logrotate

2022-04-05 Thread Mantas Mikulėnas
Try different `-o` modes though to see what fields each log entry actually has. > > As soon as I add _MESSAGE= I get no output any more (even with MESSAGE=.*). > It's MESSAGE, not _MESSAGE, and there's no regex support for this kind of match. Journalctl can't search for "all entries that contain this key" unfortunately. (Would be useful though.) -- Mantas Mikulėnas

Re: [systemd-devel] Q: journalctl -b -g logrotate

2022-04-05 Thread Mantas Mikulėnas
946 has bad signature EXBLK01 > > So can I find kernel messages from previous boots? > `journalctl -k` is meant to imitate dmesg (except with correct timestamps), so it shows the current boot only. You can use _TRANSPORT=kernel to filter for kernel messages if you don't want that. $ journalctl _TRANSPORT=kernel -g BogoMIPS -- Mantas Mikulėnas

Re: [systemd-devel] What is wrong with my .path setup?

2022-03-20 Thread Mantas Mikulėnas
On Sun, Mar 20, 2022, 23:27 John Ioannidis wrote: > Here are my .path and .service files: > > $ *cat /etc/systemd/system/trigg.path * > [Path] > DirectoryNotEmpty=/root/trigger > MakeDirectory=true > > $ *cat /etc/systemd/system/trigg.service * > [Unit] > Description=Trigger Service > > [Service]

Re: [systemd-devel] timer "OnBootSec=15m" not triggering

2022-03-07 Thread Mantas Mikulėnas
configuration – the problem is that the whole .timer unit isn't active, so its triggers won't get scheduled in the first place. > [Install] > WantedBy=timer.target > The timer is not being scheduled because it's WantedBy a nonexistent target. I think you meant 'timer*s*.target' here. -- Mantas Mikulėnas

Re: [systemd-devel] systemd failing to close unwanted file descriptors & FDS spawning and crashing

2022-03-04 Thread Mantas Mikulėnas
all at the same syscall number, so check what your kernel's arch/**/syscall.tbl says about number 436? -- Mantas Mikulėnas

Re: [systemd-devel] systemd failing to close unwanted file descriptors & FDS spawning and crashing

2022-03-03 Thread Mantas Mikulėnas
Ah, right, I forgot – since this is done in the service child (right before exec) and not in the main process, you probably need to add the -f option to make strace follow forks... On Thu, Mar 3, 2022, 22:08 Christopher Obbard wrote: > Hi Mantas, > > On 03/03/2022 19:18, Mantas Mikulė

Re: [systemd-devel] systemd failing to close unwanted file descriptors & FDS spawning and crashing

2022-03-03 Thread Mantas Mikulėnas
, where the only major change is that it has been ported to call close_range() if that's available... I would boot with init=/bin/sh, then run `exec strace -D -o /var/log/systemd.trace /lib/systemd/systemd` to get a trace, and see if the EINVAL actually comes from calling close_range() or from something else. -- Mantas Mikulėnas

Re: [systemd-devel] Journald: Re-use /var/log/journal hash entry after system upgrade

2022-03-01 Thread Mantas Mikulėnas
alctl -m -f could be used to watch logs of all containers. (The machine ID is also used as the base for systemd-networkd's DHCPv4 Client ID, DHCPv6 DUID, and IPv6 address generation. But other than that, though, I can't think of any its uses that would be visible externally – aside from desktop-specific things like pulseaudio – so in some cases it might be "good enough" to pre-define a fixed ID in the template image as a last resort.) -- Mantas Mikulėnas

Re: [systemd-devel] Syntax check for a new service?

2022-03-01 Thread Mantas Mikulėnas
On Tue, Mar 1, 2022 at 2:32 PM Tom Browder wrote: > On Sat, Feb 26, 2022 at 12:06 Mantas Mikulėnas wrote: > ... > >> Use the Environment= option to set environment variables. >> > > Thanks, Mantas. That works great. > > One more question: I'm thinking of

Re: [systemd-devel] Syntax check for a new service?

2022-02-26 Thread Mantas Mikulėnas
e=simple but neither like the single > ExecStart= line with that command. > Neither of them invoke /bin/sh to parse the command – the *shell* is what normally would interpret the "export ..." in a shell script, but that doesn't happen in systemd services. In all cases, ExecStart is minimally parsed by systemd itself and then just directly execve()'d. Use the Environment= option to set environment variables. -- Mantas Mikulėnas

Re: [systemd-devel] Q: Wanting a target

2022-02-23 Thread Mantas Mikulėnas
vice:After=network.target > > /usr/lib/systemd/system/nfs-server.service:Requires= network.target > proc-fs-nfsd.mount > /usr/lib/systemd/system/nfs-server.service:After= network.target > proc-fs-nfsd.mount rpcbind.socket nfs-mountd.service > > /usr/lib/systemd/system/nmb.service:After=network.target > According to docs for network.target, it's the first two that are "wrong". -- Mantas Mikulėnas

Re: [systemd-devel] Proposal to extend os-release/machine-info with field PREFER_HARDENED_CONFIG

2022-02-16 Thread Mantas Mikulėnas
7;re in a hurry to check on some problem, make three typos, you're locked out for 10 minutes, and you're about to throw the computer out the window :-| I don't think it's a good idea to stick a "lockdown" knob in machine-info, though (and definitely not os-release) – m

Re: [systemd-devel] [RFC] systemd-resolved: Send d-bus signal after DNS resolution

2022-02-16 Thread Mantas Mikulėnas
dit for service start/stop operations (via audit_log_user_comm_message). Not sure how or why domain resolution be integrated with the firewall, though. -- Mantas Mikulėnas

Re: [systemd-devel] Service activation

2022-02-13 Thread Mantas Mikulėnas
On Sun, Feb 13, 2022 at 1:09 PM Wols Lists wrote: > On 13/02/2022 09:54, Mantas Mikulėnas wrote: > > On Sun, Feb 13, 2022 at 2:03 AM Wol > <mailto:antli...@youngman.org.uk>> wrote: > > > > More fun getting things to work ... :-) > > > > So

Re: [systemd-devel] Service activation

2022-02-13 Thread Mantas Mikulėnas
and directly gives it the "listening" socket, letting the service itself handle accept(). > > > And once I've got all that sorted, I'm betting I'm going to have grief > getting it to work properly, so while it's not much to do with systemd, > is there any way I can get systemd to log all traffic back and forth so > I can debug it? > No, the traffic doesn't even go through systemd in the first place. -- Mantas Mikulėnas

Re: [systemd-devel] [EXT] Re: Help understanding "notify" (SLES15 SP3 restarting smartd)

2022-02-10 Thread Mantas Mikulėnas
gt; >> So back to systemd: What time stamp does it use for PathChanged=? > >> > > > > Technically none – it watches *inotify* events (all except IN_MODIFY). > > Specifically PathChanged= reacts to: > > > > [PATH_CHANGED] = IN_DELETE_SELF | IN_MOVE_SELF | IN_ATTRIB | > > IN_CLOSE_WRITE | IN_CREATE | IN_DELETE | IN_MOVED_FROM | IN_MOVED_TO, > > > > (https://github.com/systemd/systemd/blob/main/src/core/path.c#L37) > > > > So basically a) any kind of rename, delete, attribute change (stuff that > > changes ctime), or b) whenever the file gets *closed* after it has been > > written to (stuff that changes mtime). > > Hi! > > So a unit using PathChanged= is expected to check again what actually has > changed? > Yes, .path units (not unlike .timer units) only activate another unit but can't inform it of *why* it just got activated. > Doesn't really sound like being useful, as must users probably assume that > "Changed" refers to file content change. > Which is what PathChanged= includes. (The difference between PathChanged and PathModified is that the latter triggers immediately for each individual write (IN_MODIFY), while PathChanged delays the trigger until the file is closed. That makes PathModified the less useful one, in most situations.) -- Mantas Mikulėnas

Re: [systemd-devel] Antw: Re: [EXT] Re: Run "ipmitool power cycle" after lib/systemd/system-shutdown scripts

2022-02-10 Thread Mantas Mikulėnas
a power cycle through IPMI > while also doing a clean shutdown/reboot, unless the the IPMI features a > delayed execution itself. > Asking the BMC to power the system off is no different than asking the system to power itself off – what makes it a "clean shutdown" is stopping services, syncing and unmounting filesystems, etc. So in theory these shutdown hooks should do the job. Though a better place would be a "shutdown initramfs" which runs from a tmpfs after *all* storage has been unmounted. I think Dracut has that, and explicitly specifies the order for its shutdown hooks, so it should be possible to put ipmitool there. -- Mantas Mikulėnas

Re: [systemd-devel] [EXT] Re: Help understanding "notify" (SLES15 SP3 restarting smartd)

2022-02-10 Thread Mantas Mikulėnas
ime stamp does it use for PathChanged=? > Technically none – it watches *inotify* events (all except IN_MODIFY). Specifically PathChanged= reacts to: [PATH_CHANGED] = IN_DELETE_SELF | IN_MOVE_SELF | IN_ATTRIB | IN_CLOSE_WRITE | IN_CREATE | IN_DELETE | IN_MOVED_FROM | IN_MOVED_TO, (https://github.com/systemd/systemd/blob/main/src/core/path.c#L37) So basically a) any kind of rename, delete, attribute change (stuff that changes ctime), or b) whenever the file gets *closed* after it has been written to (stuff that changes mtime). -- Mantas Mikulėnas

Re: [systemd-devel] Help understanding "notify" (SLES15 SP3 restarting smartd)

2022-02-10 Thread Mantas Mikulėnas
react. > None. It's not an activation mechanism and not a configuration monitoring mechanism – it's a readiness indication mechanism. Type=notify expects the service to send a message to a Unix socket (at $NOTIFY_SOCKET) indicating that it is "ready". (And optionally some custom text to show in 'systemctl status'.) -- Mantas Mikulėnas

Re: [systemd-devel] Odd behaviour on boot

2022-02-07 Thread Mantas Mikulėnas
On Mon, Feb 7, 2022, 22:06 Tomasz Torcz wrote: > On Mon, Feb 07, 2022 at 07:28:46PM +, Wols Lists wrote: > > On 07/02/2022 17:55, Mantas Mikulėnas wrote: > > > Basically you have *a lot* of service daemons getting killed – some of > > > them restart cleanly, othe

Re: [systemd-devel] Odd behaviour on boot

2022-02-07 Thread Mantas Mikulėnas
On Mon, Feb 7, 2022, 19:43 Wols Lists wrote: > On 07/02/2022 14:06, Mantas Mikulėnas wrote: > > On Mon, Feb 7, 2022 at 2:54 PM Wols Lists > <mailto:antli...@youngman.org.uk>> wrote: > > > > Bear in mind I did have a malformed scarletdme.service file, it

Re: [systemd-devel] Odd behaviour on boot

2022-02-07 Thread Mantas Mikulėnas
d the whole `journalctl -b` for messages that happened around the actual failure? Could be just about anything, from services getting stopped due to their dependencies failing, to something missing due to *lack of* dependencies, to OOM killing random processes... -- Mantas Mikulėnas

Re: [systemd-devel] network interface scripting

2022-02-05 Thread Mantas Mikulėnas
s I know, an Ubuntu-specific tool that just generates systemd-networkd (or NetworkManager) configs. In case you wanted those to be YAML-based. -- Mantas Mikulėnas

Re: [systemd-devel] Configuring wakeup-online at runtime with networkctl

2022-02-03 Thread Mantas Mikulėnas
y via `ethtool -s wol g ens0`. Also is it possible to display the status of wakeup online with > 'networkctl status' ? > I'd say open a RFE on GitHub issues, although personally I think `networkctl status` is already a bit overloaded... -- Mantas Mikulėnas

Re: [systemd-devel] Launching script that needs network before suspend

2022-01-31 Thread Mantas Mikulėnas
management solution does this > explicitly, I am puzzled, why it would do that. > NetworkManager does that, especially for Wi-Fi; I don't remember the rationale though. (It uses systemd's delay inhibitors.) -- Mantas Mikulėnas

Re: [systemd-devel] Where to put unix sockets while SELinux enforces on init_t?

2022-01-30 Thread Mantas Mikulėnas
al – on my system I see /run/rpcbind.sock, /run/dmeventd-client, /run/avahi-daemon/socket, all of them created by pid1 through .socket units (see `systemctl list-sockets`) and not by the actual daemons themselves. This makes me assume that on distros with SELinux, the default policy would just allow systemd to do that. -- Mantas Mikulėnas

Re: [systemd-devel] systemd killing processes on monitor wakeup?

2022-01-30 Thread Mantas Mikulėnas
IGCHLD from PID 3328167 > (n/a). > > ** > Honestly this just sounds like systemd killing "leftover" processes within the plasma-plasmashell cgroup, after the "main" process of that service has exited. That's not a bug; that's standard behavior for systemd services. For special cases like desktop environments, I think this means the .service should have KillMode=process (as long as that's still supported, anyway), *or* Plasma should be improved to no longer spawn apps directly but to put them in new systemd units (like gnome-shell does). -- Mantas Mikulėnas

Re: [systemd-devel] systemd killing processes on monitor wakeup?

2022-01-28 Thread Mantas Mikulėnas
Try to set the systemd user instance's log level to 'debug'; I'm guessing it's not that systemd kills processes directly but that something triggers a 'systemctl stop' of the session .scope that they were in. Can't think of any events directly related to monitor wakeup that systemd would react to

Re: [systemd-devel] [EXT] Re: Q: "systemd[1]: var-tmp-AP_0x6tWaHS.mount: Succeeded."

2022-01-28 Thread Mantas Mikulėnas
On Fri, Jan 28, 2022, 11:59 Ulrich Windl wrote: > >>> Mantas Mikulenas schrieb am 28.01.2022 um 10:27 in > Nachricht > : > > On Fri, Jan 28, 2022 at 10:50 AM Ulrich Windl < > > ulrich.wi...@rz.uni-regensburg.de> wrote: > > > >> Hi! > >> > >> When upgrading SLES15 to SP3, a newer version of syste

Re: [systemd-devel] Q: "systemd[1]: var-tmp-AP_0x6tWaHS.mount: Succeeded."

2022-01-28 Thread Mantas Mikulėnas
tribute to dependencies.) If OpenSuSE has the kernel audit subsystem enabled, try using `auditctl` to monitor a) what process executes mount-related syscalls, b) what process creates directories under /var/tmp. -- Mantas Mikulėnas

Re: [systemd-devel] Automatically moving forked processes in a different cgroup based on children's UID

2022-01-09 Thread Mantas Mikulėnas
alk to their own PHP-FPM socket), so resource limits could be set either at PHP-FPM level, or if needed multiple php-fpm@.service instances could be run with their own cgroups. -- Mantas Mikulėnas

Re: [systemd-devel] How to check watchdog status?

2022-01-07 Thread Mantas Mikulėnas
r versions just give up. Generally, if systemd or something else is actively using the watchdog, then wdctl will report a "Timeleft" value lower than the total "Timeout" as it is actively counting down. (If it does report identical values, that *could* mean systemd just pinged the watchdog, so wait 1-2 seconds and check again.) -- Mantas Mikulėnas

Re: [systemd-devel] eth2: Failed to rename network interface 6 from 'eth2' to 'eno1': File exists

2022-01-06 Thread Mantas Mikulėnas
On Thu, Jan 6, 2022 at 10:42 AM Harald Dunkel wrote: > On 2022-01-05 21:48:11, Michael Biebl wrote: > > Am Mi., 5. Jan. 2022 um 13:50 Uhr schrieb Mantas Mikulėnas < > graw...@gmail.com>: > >> It does, yes, but note this part: > >> > >> Jan 03 11:3

Re: [systemd-devel] eth2: Failed to rename network interface 6 from 'eth2' to 'eno1': File exists

2022-01-05 Thread Mantas Mikulėnas
AME=' assigned by an earlier rule, so the "predictable" name is not applied to avoid breaking existing configuration. It also makes me wonder whether one of your interfaces might actually have the "eno1" name assigned manually (through another udev rule) and not really through the "predictable" naming. -- Mantas Mikulėnas

Re: [systemd-devel] Context for "exitrd"

2021-12-31 Thread Mantas Mikulėnas
service that runs before every shutdown. At least on Arch it literally runs mkinitcpio; not sure about dracut. So I'm assuming that the whole idea of "exitrd" is just to make the same "initramfs update" process generate both halves as static cpio images at the same time, so that it would become systemd's job to simply unpack it to /run (and maybe validate a signature or two). -- Mantas Mikulėnas

Re: [systemd-devel] User authentication service isn't killed fully

2021-12-28 Thread Mantas Mikulėnas
On Tue, Dec 28, 2021, 16:39 beroal wrote: > I was not aware of `PAMName`. After reading its documentation, it's still > not clear to me what it does and how it can be used. What's a PAM session? > Do you have any references? Google search wasn't very helpful. AFAIK from > the PAM documentation, s

Re: [systemd-devel] User authentication service isn't killed fully

2021-12-28 Thread Mantas Mikulėnas
anything specific that the built-in [Service] PAMName= wouldn't do anyway?) -- Mantas Mikulėnas

Re: [systemd-devel] Q: journal filtering and unit failures

2021-12-27 Thread Mantas Mikulėnas
service \ + MESSAGE_ID=fc2e22bc6ee647b6b90729ab34a250b1 _UID=0 COREDUMP_UNIT=logrotate.service \ + _PID=1 UNIT=logrotate.service \ + _UID=0 OBJECT_SYSTEMD_UNIT=logrotate.service The fourth is a generic filter (any process running as root can specify OBJECT_SYSTEMD_UNIT=) which I think came a bit later than the special-case pid1 and coredump ones. -- Mantas Mikulėnas

Re: [systemd-devel] Q: journal logging and "{xyz}"

2021-12-27 Thread Mantas Mikulėnas
uot;, and "\").* Anything else goes through C-style escaping (see systemd-escape) before it even leaves systemctl. -- Mantas Mikulėnas

Re: [systemd-devel] [systemd-networkd] Can use IPv6SendRA and IPv6AcceptRA in a same .network file

2021-12-12 Thread Mantas Mikulėnas
er advertisement` messages. > > So is my configuration wrong ,or does systemd-networkd support this kind > of operation ? > > Systemd version > ` > systemctl --version > systemd 249 (249.7-2-arch) > +PAM +AUDIT -SELINUX -APPARMOR -IMA +SMACK +SECCOMP +GCRYPT +GNUTLS > +OPENSSL +ACL +BLKID +CURL +ELFUTILS +FIDO2 +IDN2 -IDN +IPTC +KMOD > +LIBCRYPTSETUP +LIBFDISK +PCRE2 -PWQUALITY +P11KIT -QRENCODE +BZIP2 +LZ4 > +XZ +ZLIB +ZSTD +XKBCOMMON +UTMP -SYSVINIT default-hierarchy=unified > ` > > Thanks. > > Best regards, > Jack > > -- Mantas Mikulėnas

Re: [systemd-devel] Run reboot as normal user

2021-11-30 Thread Mantas Mikulėnas
it is not installed? > Yes. Polkit is the authorization system that decides whether to allow normal users to do privileged actions or not. > I don't want to use Polkit or sudo, is there any solution ? > No. -- Mantas Mikulėnas

Re: [systemd-devel] Systemd setup DSA interfaces in port mode and bond them together?

2021-11-16 Thread Mantas Mikulėnas
Most of this looks like it could be done with systemd-networkd to create a bond .netdev, with a small oneshot service for i2c. (What's the exact criteria for when it should be run? Does it depend on bond0 being there, does it need to be last, etc?) On Tue, Nov 16, 2021, 02:58 Brian Hutchinson wro

Re: [systemd-devel] 回复: Is it possible to send a string to the journal of one specific systemd unit

2021-10-22 Thread Mantas Mikulėnas
AIY DHAIY wrote: > Thanks a lot Mantas. > But in my sytem, logger does not have "--journal". > Are you aware of other tools from bash which can be used? > > BR > ------ > *发件人:* Mantas Mikulėnas > *发送时间:* 2021年10月22日 18:45 > *收件人:* DHA

Re: [systemd-devel] 回复: Is it possible to send a string to the journal of one specific systemd unit

2021-10-22 Thread Mantas Mikulėnas
yservice* to inspect the logs generated by > myservice. > > > But is there a way to insert one string from command-line into myservice's > journal so that it can be seen by *journalctl -u myservice* later? > > -- Mantas Mikulėnas

<    1   2   3   4   5   6   7   8   9   10   >