3

Arch 5.18/ MATE Desktop

I have a user service that sets up values for my panel

[Unit]
Description=Set values for panel widgets
After=mnt-ram
After=sys-subsystem-net-devices-eno1.device

[Service]
ExecStart=/home/stephen/bin/panel-setup.sh 
Type=oneshot
RemainAfterExit=True

[Install]
WantedBy=default.target

Both mnt-ram and sys-subsystem-net-devices-enp0s8.device show up as active for systemctl --user list-units.

At boot the journal reports

 systemd[669]: /home/stephen/.config/systemd/user/panel-setup.service:3: Failed to add dependency on mnt-ram, ignoring: Invalid argument
 

However after the desktop loads I can issue without error and with expected effect: systemctl user restart panel-setup

1 Answer 1

4

The error is in After=mnt-ram

The actual value given by systemctl --user list-units is mnt-ram.mount NOT mnt-ram.

In accessing systemd units I've fallen into the habit of omitting the .service extension (eg. systemctl restart servicename) so dropped the extension here where referencing the mnt-ram.mount service.

1
  • 1
    Had the same error for a very similar problem: Dependency on systemd-journald, which is a normal service, but there is also a systemd-journald.socket, so to resolve the ambiguity I had to tack on .service.
    – goldilocks
    Commented Mar 8 at 16:01

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .