Unix & Linux Stack Exchange
Q&A for users of Linux, FreeBSD and other Unix-like operating systems
Latest Questions
0
votes
0
answers
17
views
Restart systemd service *without* restarting dependents
I have four `systemd` services: `{a,b,c,d}.service`. `d.service` is the "main" service, and it is the one that parses the configuration file for all four. Typically, the four are started together. To make it easier to apply configuration changes, I have marked `{a,b,c}.service` as `PartOf=d.service`...
I have four
systemd
services: {a,b,c,d}.service
. d.service
is the "main" service, and it is the one that parses the configuration file for all four. Typically, the four are started together.
To make it easier to apply configuration changes, I have marked {a,b,c}.service
as PartOf=d.service
in their unit files. That way, when I restart d.service
, the configuration changes are applied across all four services.
However, there are circumstances (debugging, for example) where I want to **only** restart d.service
without affecting {a,b,c}.service
. Is there a way for me to do this, either through options for the systemctl restart
command or through unit file configurations?
I could also, I suppose, make a wrapper service - e.service
- that contains {a,b,c,d}.service
and then restart that when I want to apply config changes. I wanted to see if there was a way to do this without adding a fifth service, though.
This is perhaps a misuse of systemd
, and I'll gladly take recommendations for ways that I can structure this configuration better.
chrysolepis
(1 rep)
Aug 6, 2025, 01:00 PM
• Last activity: Aug 6, 2025, 02:55 PM
0
votes
1
answers
2353
views
systemd & python logging
I wrote a simple python3 skript and want to make a service from it. Here are the two files #!/bin/python3 while True: print('True') Systemd Service: [Unit] Description=True Service [Service] Type=simple ExecStart=python3 /root/print_true.py StandardOutput=journal+console [Install] WantedBy=multi-use...
I wrote a simple python3 skript and want to make a service from it. Here are the two files
#!/bin/python3
while True:
print('True')
Systemd Service:
[Unit]
Description=True Service
[Service]
Type=simple
ExecStart=python3 /root/print_true.py
StandardOutput=journal+console
[Install]
WantedBy=multi-user.target
The service is starting but i cant see the output anywhere. Not in
-u true-service.service
, not in status true-service
and not in
. I want to have it only in journal but how can i accomplish that? I cant seem to find a working answer.
Nico
(123 rep)
Jun 28, 2020, 08:57 AM
• Last activity: Aug 6, 2025, 06:05 AM
7
votes
2
answers
4149
views
How to lock screen on lid closing using systemd?
I am running Sway on Fedora 26 and want my laptop to be locked when I close my screen. I changed `HandleLidSwitch` to `lock` in `/etc/systemd/logind.conf` and ran `systemctl restart systemd-logind` after that. However, closing the lid does nothing. The lock program I intend to use is Swaylock and I...
I am running Sway on Fedora 26 and want my laptop to be locked when I close my screen. I changed
HandleLidSwitch
to lock
in /etc/systemd/logind.conf
and ran systemctl restart systemd-logind
after that. However, closing the lid does nothing.
The lock program I intend to use is Swaylock and I can manually call it by runnig the command swaylock
in a terminal.
How do I make Systemd call swaylock
when it tries to close the screen (as instructed to do in logind.conf
)?
strNOcat
(383 rep)
Oct 7, 2017, 09:22 PM
• Last activity: Aug 5, 2025, 05:03 PM
6
votes
1
answers
5927
views
Understand Systemd basic.target after boot time
The question I have here is to understand `basic.target` upon booting my CentOS 7 server. A few things I think I know correctly about Systemd: * `Requires=unit2` means some `unit1` will only be activated if `unit2` succeeds all the way * `Wants=unit2` means some `unit1` will be activated regardless...
The question I have here is to understand
basic.target
upon booting my CentOS 7 server.
A few things I think I know correctly about Systemd:
* Requires=unit2
means some unit1
will only be activated if unit2
succeeds all the way
* Wants=unit2
means some unit1
will be activated regardless whether
the listed unit2 succeeds or not
* After=unit2
means some unit1
will only be activated after unit2 is activated
* Things in Systemd usually starts out in parallel
* .target
is mainly for "grouping" and "ordering" (see [systemd.target])
* In reality, basic.target
must be activated (along with everything it required and wanted) before reaching multi-user.target
(which is the default runlevel for a server)
All right, I hope so far I am right.
---
Now, looking basic.target
:
$ sudo cat /usr/lib/systemd/system/basic.target
[Unit]
Description=Basic System
Documentation=man:systemd.special(7)
Requires=sysinit.target
After=sysinit.target
Wants=sockets.target timers.target paths.target slices.target
After=sockets.target paths.target slices.target
So now my interpretation is:
1. basic.target
will only be activated **after** sysinit.target
has succeeded
2. Furthermore, basic.target
desires to have sockets.target
and etc to be running
3. The additional After=
means, okay, please only activate basic.target
after sockets.target
, paths.target
, and slices.target
are activated. It's okay for timers.target
to fail.
4. Then why not combine two After=
into one? Why not use Require=
instead of Wants
(except timers.target
)?
CppLearner
(499 rep)
Aug 21, 2019, 07:53 PM
• Last activity: Aug 5, 2025, 10:05 AM
-1
votes
2
answers
1021
views
What's the difference between `active` and `running` states of `systemctl list-units`?
I see from manual of `systemctl` that's the difference is `high-` and `low-` levels. What does that mean? I suppose that `active` means "started automatically while OS starts" and `running` means "is active right now".
I see from manual of
systemctl
that's the difference is high-
and low-
levels.
What does that mean?
I suppose that active
means "started automatically while OS starts" and running
means "is active right now".
palmasd1
(127 rep)
Apr 26, 2024, 06:42 AM
• Last activity: Aug 4, 2025, 01:07 PM
0
votes
1
answers
2067
views
systemd timer runs more than once per period even with persistent=false
I have a unit that normally I want running, but sometimes I want to manually shut it off for the day and restart it later automatically. So I have a timer to restart it `OnCalendar=daily`. This works, but sometimes I need to stop the unit twice because the timer immediately restarts the unit. Here's...
I have a unit that normally I want running, but sometimes I want to manually shut it off for the day and restart it later automatically. So I have a timer to restart it
OnCalendar=daily
. This works, but sometimes I need to stop the unit twice because the timer immediately restarts the unit.
Here's a simplified example with minutes instead of days:
[Unit]
Description=foo timer
[Timer]
Persistent=false
OnCalendar=minutely
AccuracySec=1
Unit=foo.service
[Install]
WantedBy=default.target
---
[Unit]
Description=foo service
[Service]
Type=simple
ExecStart=/bin/sh -c 'while true; do sleep 1; done'
[Install]
WantedBy=default.target
---
If I systemctl stop foo.service
, and the timer had fired more than 1 minute ago (PASSED > 1m in systemdctl list-timers
), it immediately refires and starts the unit. The unit always stays stopped until the next minute if I stop it twice. The docs make it sound like Persistent=false
should not cause this, but clearly I'm misunderstanding. If it matters, the daily unit I'm actually interested in is a system unit, but the test unit is a user unit; the behavior is the same.
jpkotta
(493 rep)
Sep 16, 2019, 01:12 AM
• Last activity: Aug 2, 2025, 09:05 AM
3
votes
1
answers
37
views
How to start multiple systemd services within a target sequentially
I have a large set of systemd services that are part of a single target running on an embedded system with a relatively slow file system. When starting the target, our most significant startup delay is due to loading the application from the filesystem into memory. When the target is started, System...
I have a large set of systemd services that are part of a single target running on an embedded system with a relatively slow file system. When starting the target, our most significant startup delay is due to loading the application from the filesystem into memory. When the target is started, SystemD starts all services simultaneously, and we occasionally miss the service's TimeoutSec delay for some applications.
We could increase the TimeoutSec to increase the delay, but I'm interested in whether we can improve the overall system startup by having SystemD start only 1 service at a time and not thrashing the i/o.
We could use the service unit wants/after/requires etc. to enforce a specific startup ordering, but the ordering doesn't matter. Is there a way, without requiring specific ordering, to tell SystemD to start the services within a target 1 at a time?
T. Waters
(31 rep)
Aug 1, 2025, 04:39 PM
• Last activity: Aug 1, 2025, 07:17 PM
3
votes
3
answers
4171
views
systemd networking is ignoring network configuration file on boot
I have an embedded linux system compiled with Yocto, using systemd. I have a network configuration file at ```/etc/systemd/network/20-wired.network```. The contents of that file are: [Match] Name=eth0 [Network] Address=192.168.5.40/24 Gateway=192.168.5.1 DNS=192.168.5.1 However, when I reboot my mac...
I have an embedded linux system compiled with Yocto, using systemd. I have a network configuration file at
/etc/systemd/network/20-wired.network
. The contents of that file are:
[Match]
Name=eth0
[Network]
Address=192.168.5.40/24
Gateway=192.168.5.1
DNS=192.168.5.1
However, when I reboot my machine, the eth0 interface is successfully configured using DHCP instead of assigning the static IP address. The a
command shows:
2: eth0: mtu 1500 qdisc mq state UP group default qlen 1000
link/ether f8:dc:7a:3c:27:82 brd ff:ff:ff:ff:ff:ff
inet 10.1.1.223/16 brd 10.1.255.255 scope global dynamic noprefixroute eth0
valid_lft 85898sec preferred_lft 85898sec
inet6 fe80::43ec:fd39:e1c0:3c05/64 scope link noprefixroute
valid_lft forever preferred_lft forever
However, if I then wait 5 seconds or so after boot, and do a restart systemd-networkd
the system will usually be configured correctly like so:
2: eth0: mtu 1500 qdisc mq state UP group default qlen 1000
link/ether f8:dc:7a:3c:27:82 brd ff:ff:ff:ff:ff:ff
inet 192.168.5.40/24 brd 192.168.5.255 scope global eth0
valid_lft forever preferred_lft forever
inet6 fe80::43ec:fd39:e1c0:3c05/64 scope link noprefixroute
valid_lft forever preferred_lft forever
Lastly, with the right timing on the restart of the network service, I can seemingly even get this result (both the intended static address and the unwanted DHCP address):
2: eth0: mtu 1500 qdisc mq state UP group default qlen 1000
link/ether f8:dc:7a:3c:27:82 brd ff:ff:ff:ff:ff:ff
inet 192.168.5.40/24 brd 192.168.5.255 scope global eth0
valid_lft forever preferred_lft forever
inet 10.1.1.223/16 brd 10.1.255.255 scope global dynamic noprefixroute eth0
valid_lft 86246sec preferred_lft 86246sec
inet6 fe80::43ec:fd39:e1c0:3c05/64 scope link noprefixroute
valid_lft forever preferred_lft forever
Does anyone know what is going on here or how to debug this? Is there something obvious wrong with my configuration?
status systemd-networkd
shows the following immediately after boot (specifically after network-online.target):
* systemd-networkd.service - Network Service
Loaded: loaded (/lib/systemd/system/systemd-networkd.service; enabled; vendor preset: enabled)
Active: activating (start) since Tue 2021-07-20 12:58:52 UTC; 65ms ago
TriggeredBy: * systemd-networkd.socket
Docs: man:systemd-networkd.service(8)
Main PID: 282 ((networkd))
Tasks: 1 (limit: 3576)
Memory: 416.0K
CGroup: /system.slice/systemd-networkd.service
`-282 (networkd)
Some number of seconds later it looks like this:
* systemd-networkd.service - Network Service
Loaded: loaded (/lib/systemd/system/systemd-networkd.service; enabled; vendor preset: enabled)
Active: active (running) since Tue 2021-07-20 12:58:52 UTC; 3min 20s ago
TriggeredBy: * systemd-networkd.socket
Docs: man:systemd-networkd.service(8)
Main PID: 282 (systemd-network)
Status: "Processing requests..."
Tasks: 1 (limit: 3576)
Memory: 2.0M
CGroup: /system.slice/systemd-networkd.service
`-282 /lib/systemd/systemd-networkd
So it looks like the service is still "activating" when the network-online.target services run. I'm not sure what that means, though, or if it's a problem.
Dave
(91 rep)
Jul 19, 2021, 08:40 PM
• Last activity: Aug 1, 2025, 03:12 AM
6
votes
1
answers
3948
views
X2Go: How to enable/disable
[Documentation](https://wiki.archlinux.org/index.php/X2go#Start_X2Go_server_daemon) and various internet answers suggest `x2goserver` will have a service on systemd systems which can be started (or stopped, etc) with `systemctl start x2goserver`. However, there is no such service on my system (Fedor...
[Documentation](https://wiki.archlinux.org/index.php/X2go#Start_X2Go_server_daemon) and various internet answers suggest
x2goserver
will have a service on systemd systems which can be started (or stopped, etc) with systemctl start x2goserver
.
However, there is no such service on my system (Fedora 30 MATE):
> Unit x2goserver.service could not be found.
There is also no process by this name except for x2gocleansessions
:
$ pgrep -la x2go
1808 /usr/bin/perl /usr/sbin/x2gocleansessions
Yet, X2Go is working. Has its process or service been named something else now?
How can X2Go be turned off or on?
adatum
(1241 rep)
May 22, 2019, 06:43 PM
• Last activity: Jul 31, 2025, 08:07 PM
0
votes
1
answers
123
views
What systemd service mounts filesystems in /media/$USER?
I have some mount units that are not always being started. When one of them isn't started, I find that the corresponding device is instead mounted in `/media/${USER}`. What do I need to do to make these mount units launch before whatever mounts filesystems in `/media/${USER}`?
I have some mount units that are not always being started. When one of them isn't started, I find that the corresponding device is instead mounted in
/media/${USER}
. What do I need to do to make these mount units launch before whatever mounts filesystems in /media/${USER}
?
Melab
(4328 rep)
Jul 31, 2025, 01:47 AM
• Last activity: Jul 31, 2025, 05:09 PM
1
votes
2
answers
279
views
systemd-networkd 'relaytarget' not working (dhcp relay) in Debian stable 12 bookworm
my first question here. I'm currently using the 'dhcp-helper' program to do dhcp relay, works fine, but I want to switch to using the systemd-networkd 'RelayTarget' function in the *.network file. I've tried every option I can think of, but can't seem to get it working. * Running current Debian stab...
my first question here.
I'm currently using the 'dhcp-helper' program to do dhcp relay, works fine, but I want to switch to using the systemd-networkd 'RelayTarget' function in the *.network file. I've tried every option I can think of, but can't seem to get it working.
* Running current Debian stable "bookworm 12" 6.1.0-13-amd64
* Debian stable runs systemd 252 (252.17-1~deb12u1)
I've tried every option I can think of, no luck yet.
/etc/systemd/network/02-port2-lan0-static.network:
# /etc/systemd/network/02-port2-lan0-static.network
# configures lan0 with static ip address
#
[Match]
Name=lan0
[Network]
Address=172.16.1.1/24
# do not set gateway or dns, will inherit from system
[DHCPServer]
ServerAddress=172.16.11.2/24
RelayTarget=172.16.11.2
BindToInterface=no
Anyone have this working in Debian stable? I realize Debian stable does not run the latest systemd version. This is a production router, so upgrading to testing is not an option.
Thanks
drokmed
(11 rep)
Nov 4, 2023, 08:23 PM
• Last activity: Jul 30, 2025, 10:03 AM
2
votes
2
answers
3506
views
startProcess: posix_spawnp: does not exist (No such file or directory)
I have an interesting case where I'm getting the below error when running a bash program but only when it's run via a systemd unit (running within Nixos). `telegram: startProcess: posix_spawnp: does not exist (No such file or directory)` If I run this program from the command line locally it works w...
I have an interesting case where I'm getting the below error when running a bash program but only when it's run via a systemd unit (running within Nixos).
telegram: startProcess: posix_spawnp: does not exist (No such file or directory)
If I run this program from the command line locally it works with no issue... What might be the cause of this error? It seems like posix_spawnp is actually a syscall which confuses me (why does the error seem to indicate it's an executable?)
The actual script is located here: https://github.com/fabianonline/telegram.sh/blob/master/telegram
Chris Stryczynski
(6593 rep)
Sep 25, 2022, 01:17 PM
• Last activity: Jul 29, 2025, 11:02 PM
15
votes
1
answers
3709
views
Is it possible to change systemd private tmp directory?
I am running some programs on both Debian and Fedora. When I `ls` the `/tmp` directory, I see many directories with extremely long name like systemd-private-d85027...-bluetooth.service-qxzMGm systemd-private-d85027...-chronyd.service-vSzXdP systemd-private-d85027...-colord.service-LvpIL2 systemd-pri...
I am running some programs on both Debian and Fedora. When I
ls
the /tmp
directory, I see many directories with extremely long name like
systemd-private-d85027...-bluetooth.service-qxzMGm
systemd-private-d85027...-chronyd.service-vSzXdP
systemd-private-d85027...-colord.service-LvpIL2
systemd-private-d85027...-fwupd.service-cbpodH
systemd-private-d85027...-httpd.service-rJIaIX
It seems to be related to PrivateTmp, but how can I remove them or move them to a less distracting location? (e.g. from /tmp/systemd-...
to /tmp/.systemd-...
) I want to try not to change the PrivateTmp option for every service.
Eric Stdlib
(559 rep)
Apr 3, 2018, 08:56 PM
• Last activity: Jul 29, 2025, 10:00 AM
0
votes
2
answers
1232
views
Trouble with keeping process launched by systemd service alive
I am trying to to get my first `systemd` service working as desired. Here is what I have: `gateway-watchdog.service`: ``` # A systemd service for the Gateway Watchdog [Unit] Description=gateway-watchdog: Watchdog to ensure that Gateway (gateway.py) is running [Service] Type=simple User=root WorkingD...
I am trying to to get my first
systemd
service working as desired. Here is what I have:
gateway-watchdog.service
:
# A systemd service for the Gateway Watchdog
[Unit]
Description=gateway-watchdog: Watchdog to ensure that Gateway (gateway.py) is running
[Service]
Type=simple
User=root
WorkingDirectory=/home/ubuntu/lora_gateway/
ExecStart=/home/ubuntu/lora_gateway/watchdog.sh
[Install]
WantedBy=multi-user.target
gateway-watchdog.timer
:
[Unit]
Description=gateway-watchdog: Timer to run the associated gateway-watchdog service
[Timer]
# Run service 1 minute after boot
OnBootSec=1min
# Run service 15 minutes after the last run
OnUnitActiveSec=30s
[Install]
WantedBy=timers.target
watchdog.sh
has these lines (contained in some if
statements):
#!/bin/bash
...
if [[condition]]; then
command="python3 gateway.py"
# Process needs to be run in the background with '&'. If it isn't, the systemd service will treat this script
# as still running and so not re-run it at the time specified by the timer service.
echo "2 $(date +'%F %T'): Running: $command" >> $LOG_FILE_PATH
eval "$command"
# Command must be run using eval. If it isn't, the ampersand at the end of the command is effectively ignored
exit
fi
What I need:
The service will run watchdog.sh
. If the if
conditions in the script are true, watchdog.sh
will launch python3 gateway.py
as a separate process and then exit, and the service will no longer be considered active so that it will run again 30 seconds later.
Through various combinations of different service Type
s (I've tried simple
, oneshot
, and forking
), using &
at the end of ExecStart
and/or my command line, and/or using nohup
, I am able to either launch and keep gateway.py
alive, or have the service run every 30 seconds, but not both.
When python3 gateway.py
stays alive, it always stays part of the service's CGroup
, so the service stays active (running)
.
How can I change this behavior to achieve what I'm trying to do? Any thoughts are greatly appreciated.
**EDIT**:
I have updated the file contents above to reflect changes made based on suggestions from U.
With the files as given above, sudo systemctl status gateway-watchdog.service
gives:
● gateway-watchdog.service - gateway-watchdog: Watchdog to ensure that Gateway (gateway.py) is running
Loaded: loaded (/etc/systemd/system/gateway-watchdog.service; enabled; vendor preset: enabled)
Active: active (running) since Thu 2022-01-13 01:45:25 UTC; 8s ago
TriggeredBy: ● gateway-watchdog.timer
Main PID: 30684 (watchdog.sh)
Tasks: 3 (limit: 4435)
CGroup: /system.slice/gateway-watchdog.service
├─30684 /bin/bash /home/ubuntu/lora_gateway/watchdog.sh
└─30696 python3 gateway.py
Jan 13 01:45:25 ubuntu systemd: Started gateway-watchdog: Watchdog to ensure that Gateway (gateway.py) is running.
Good: The gateway.py
process stays running.
Bad: The service does not run again 30 seconds later, because the previous run is still active.
If I put the &
back into command="python3 gateway.py &"
, sudo systemctl status gateway-watchdog.service
gives:
● gateway-watchdog.service - gateway-watchdog: Watchdog to ensure that Gateway (gateway.py) is running
Loaded: loaded (/etc/systemd/system/gateway-watchdog.service; enabled; vendor preset: enabled)
Active: inactive (dead) since Thu 2022-01-13 01:49:05 UTC; 6s ago
TriggeredBy: ● gateway-watchdog.timer
Process: 33724 ExecStart=/home/ubuntu/lora_gateway/watchdog.sh (code=exited, status=0/SUCCESS)
Main PID: 33724 (code=exited, status=0/SUCCESS)
Jan 13 01:49:05 ubuntu systemd: Started gateway-watchdog: Watchdog to ensure that Gateway (gateway.py) is running.
Jan 13 01:49:05 ubuntu systemd: gateway-watchdog.service: Succeeded.
Good: The service is inactive, so it does run again 30 seconds later.
Bad: The python3 gateway.py
process dies immediately.
nabelekt
(1 rep)
Jan 12, 2022, 04:31 AM
• Last activity: Jul 29, 2025, 04:36 AM
0
votes
1
answers
114
views
Broadcasting a message to users in desktop environments
I'm currently writing a small systemd service that may need to shutdown the computer. I'd like to broadcast a message to all users, e.g. `This computer is going to shutdown at XXX, don't forget save your work.` For terminal users, I could use `wall`, but for users who don't have a terminal open, tha...
I'm currently writing a small systemd service that may need to shutdown the computer. I'd like to broadcast a message to all users, e.g.
This computer is going to shutdown at XXX, don't forget save your work.
For terminal users, I could use wall
, but for users who don't have a terminal open, that's not an option. I know that all the users on this machine use X/Gnome, so they have a freedesktop notification client installed. However, it's not clear to me how I can use the system bus (?) to send freedesktop notifications.
How can I do that?
Yoric
(103 rep)
Oct 31, 2024, 11:04 AM
• Last activity: Jul 28, 2025, 12:44 PM
2
votes
1
answers
2805
views
MX Linux: Network service not running after update unless booted with systemd
I did `sudo apt-get update` and `sudo apt-get upgrade`, and installed the rpi-installer. And after that, I lost all network connectivity. After that, it seemed like my network had been disabled. No access to the internet or local file shares. The networking service is not running. At the boot screen...
I did
sudo apt-get update
and sudo apt-get upgrade
, and installed the rpi-installer. And after that, I lost all network connectivity.
After that, it seemed like my network had been disabled. No access to the internet or local file shares. The networking service is not running. At the boot screen, when I see advanced options, if I select the "...(systemd)" option, I have network again.
Does anyone have any ideas on how to fix this so I don't need to go into the advanced options?
dvdhns
(121 rep)
Oct 13, 2021, 04:43 AM
• Last activity: Jul 28, 2025, 04:07 AM
0
votes
1
answers
2385
views
Systemd specifying service name dynamically
Is there a way of setting a service name dynamically in a service file? I am running several instances of a service, where all services uses different input arguments. For debugging this is not optimal as all services are called the same and it can be tedious finding out which service is actually co...
Is there a way of setting a service name dynamically in a service file?
I am running several instances of a service, where all services uses different input arguments. For debugging this is not optimal as all services are called the same and it can be tedious finding out which service is actually complaining. So what I want is to give the service a unique name for a given input. Systemds service files support this by changing the arg in
by setting the prefix "@" where the second argument will be the arg value.
Information about
command and the **@** prefix:
https://www.freedesktop.org/software/systemd/man/systemd.service.html
So this is what I have so far in my service file:
ExecStart=@/usr/bin/foo foo-%I %I
The input argument is a file, so it will be called something like bar-123.json. This works and the service name will be foo-bar-123.json when I use top, ps or the QA tools we are using. The input files are created by another service that also starts the "foo" service instance using systemctl dbus api.
However having the service called foo-bar-123.json is not the best and instead I would like to call is foo-bar.
I have tried running, as a test:
**ExecStartPre=/bin/sh -c 'export NAME=bar'**
**ExecStart=@/usr/bin/foo foo-${NAME} %I**
But then the name will be "foo-". Am guessing this is to be expected as the service file is not a shell script, however that was the only solution I could think of.
Other solution to the problem are also welcomed. I know that PR_SET_NAME in the prctl function should also change the name of the process but I am not sure who they relates to each other. The reason I don't want to use the prctl function is that is says that the name only can be 16 bytes long including the null byte, this is a limitation that I would be nice not to have.
Adam Nilsson
(1 rep)
Apr 12, 2021, 03:54 PM
• Last activity: Jul 27, 2025, 06:08 AM
-1
votes
1
answers
35
views
Why is the root partition not remounted rw after booting is finished if mounting other disks fails?
I have a Debian 12 server that I just restored to a different hardware from backups. The new hardware is missing some disks and of course they failed to mount. After the machine booted, the root filesystem was still mounted read-only. I checked everything, but didn't find any issue. Then I removed a...
I have a Debian 12 server that I just restored to a different hardware from backups. The new hardware is missing some disks and of course they failed to mount.
After the machine booted, the root filesystem was still mounted read-only. I checked everything, but didn't find any issue.
Then I removed all the *.mount services for the missing disks and the server booted with the root filesystem mounted writeable.
That makes no sense to me. Why should the root filesystem, which is completely fine and without any errors, not be mounted rw if any other mount point fails?
Is that a behaviour that I can configure somehow?
Markus Grunwald
(173 rep)
Jul 26, 2025, 01:00 PM
• Last activity: Jul 26, 2025, 03:37 PM
0
votes
1
answers
2956
views
On systemctl start, "Failed to start gitlab-runner.service: Unit is not loaded properly: Bad message."
Whenever I run `systemctl start gitlab-runner.service` I get, systemctl start gitlab-runner.service Failed to start gitlab-runner.service: Unit is not loaded properly: Bad message. See system logs and 'systemctl status gitlab-runner.service' for details. How can I find more information about this er...
Whenever I run
systemctl start gitlab-runner.service
I get,
systemctl start gitlab-runner.service
Failed to start gitlab-runner.service: Unit is not loaded properly: Bad message.
See system logs and 'systemctl status gitlab-runner.service' for details.
How can I find more information about this error, what does this mean?
Evan Carroll
(34663 rep)
Mar 22, 2020, 04:35 PM
• Last activity: Jul 26, 2025, 03:09 AM
5
votes
2
answers
2482
views
Execute a script on ethernet connection/disconnection with systemd
I have an embedded device that will connect with [`systemd-networkd`][1] to a DHCP server if connected to the local network and will fall back to being a DHCP server if not. I didn't implement it yet but plan using the answer described [here][2]. This answer points to use a script that will be start...
I have an embedded device that will connect with
systemd-networkd
to a DHCP server if connected to the local network and will fall back to being a DHCP server if not. I didn't implement it yet but plan using the answer described here .
This answer points to use a script that will be started on boot. I was wondering what if the user unplugs the network cable and connects it to a PC at runtime, he'd need to restart the board for the script to start. So the question is: is there a way to start a script when there's an interface change with systemd?
I tried using [networkd-dispatcher](https://gitlab.com/craftyguy/networkd-dispatcher) without success. I tried restarting the systemd-networkd
service, unplug the Ethernet cable, but the script I wrote located in /usr/lib/networkd-dispatcher
is not executed.
David Bensoussan
(151 rep)
May 31, 2019, 04:04 PM
• Last activity: Jul 23, 2025, 04:03 PM
Showing page 1 of 20 total questions