[systemd-devel] How to allow a user to use journalctl to see user-specific systemd service logs?
Stefan Schweter
stefan at schweter.it
Mon Oct 3 19:48:16 UTC 2016
On 03.10.2016 20:59, Daniel Ng wrote:
> I am running user-level services in Ubuntu 16.04 LTS. For example, I have
> my test.service located at ~/.config/systemd/user/test.service
>
> I was able to run the service by doing
>
> systemctl --user start test.target
>
Hi Daniel,
did you really use test.target? Target files are usally used for
grouping units [1].
I tried to create a test.service file in ~/.config/systemd/user and
started it with:
systemctl --user start test.service
Then it is possibly to use journalctl --user both with:
journalctl --user -u test
journalctl --user -u test.service
Tested with systemd 231 - what systemd version do you use?
Cheers,
Stefan
[1] https://www.freedesktop.org/software/systemd/man/systemd.target.html
More information about the systemd-devel
mailing list