Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

systemd-analyze verify fails to find transient units #32824

Open
spektrokalter opened this issue May 14, 2024 · 1 comment · May be fixed by #32850
Open

systemd-analyze verify fails to find transient units #32824

spektrokalter opened this issue May 14, 2024 · 1 comment · May be fixed by #32850
Labels
analyze bug 🐛 Programming errors, that need preferential fixing
Milestone

Comments

@spektrokalter
Copy link

spektrokalter commented May 14, 2024

systemd version the issue has been seen with

255.6-1-arch

Used distribution

Arch Linux

Linux kernel version used

6.8.9-arch1-2

CPU architectures issue was seen on

None

Component

systemd-analyze

Expected behaviour you didn't see

It seems that the command should be able to work with transient units. In the documentation (systemd-analyze(1):/verify), it is not mentioned which unit types the command supports and which it doesn't.

Rather, it says:

The full unit search path is formed by combining the directories for all command line arguments, and the usual unit load paths.

Unexpected behaviour you saw

The command claims it cannot find a unit, even though it does exist and is a transient unit.

Steps to reproduce the problem

Create transient units:

systemd-run --user -u dreamer.service sleep 1h
systemd-run --system -u dreamer.service sleep 1h

Try to run systemd-analyze verify on them:

systemd-analyze --user verify dreamer.service
Unit dreamer.service not found.
systemd-analyze --system verify dreamer.service
Unit dreamer.service not found.

Additional program output to the terminal or log subsystem illustrating the issue

No response

@spektrokalter spektrokalter added the bug 🐛 Programming errors, that need preferential fixing label May 14, 2024
@yuwata yuwata modified the milestones: v257, v256 May 15, 2024
yuwata added a commit to yuwata/systemd that referenced this issue May 15, 2024
…ing with MANAGER_TEST_RUN_GENERATORS

Otherwise, e.g. systemd-analyze verify or security cannot be used for
transient services.

Fixes systemd#32824.
yuwata added a commit to yuwata/systemd that referenced this issue May 15, 2024
…ing with MANAGER_TEST_RUN_GENERATORS

Otherwise, e.g. systemd-analyze verify or security cannot be used for
transient services.

Fixes systemd#32824.
@yuwata yuwata modified the milestones: v256, v257 May 15, 2024
@yuwata
Copy link
Member

yuwata commented May 15, 2024

Fix is waiting in #32850.

Workaround for the issue is specifying unit path explicitly e.g. /run/systemd/transient/xyz.service.

yuwata added a commit to yuwata/systemd that referenced this issue May 15, 2024
…ning with MANAGER_TEST_RUN_GENERATORS

Otherwise, e.g. systemd-analyze verify or security cannot be used for
transient services.

Fixes systemd#32824.
yuwata added a commit to yuwata/systemd that referenced this issue May 22, 2024
…ning with MANAGER_TEST_RUN_GENERATORS

Otherwise, e.g. systemd-analyze verify or security cannot be used for
transient services.

Fixes systemd#32824.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
analyze bug 🐛 Programming errors, that need preferential fixing
Development

Successfully merging a pull request may close this issue.

2 participants