Abdó Roig-Maranges
2013-07-27 19:47:13 UTC
Hello,
I'm happily using systemd 204 user instance to handle my desktop (xorg, awesome
wm, mpd, etc.) in Arch. I started experimenting with systemd 206 trying to adapt
my setup to the changes in cgroups, slices, and all that.
In 206, systemd user session is started automatically by pam_systemd when I
login to a tty. Then, I want to manually launch my window manager, in a new
logind session for my user, on a different tty.
I tried adding User and PAMName to my window manager unit awesome.service:
[Unit]
Description=Awesome window manager
After=***@0.service
Requisite=***@0.service
Requires=dbus.socket
[Service]
User=abdo
PAMName=login
TTYPath=/dev/tty7
Type=simple
SyslogIdentifier=awesome
Environment=DISPLAY=:0
ExecStart=/home/abdo/.config/systemd/scripts/awesome.sh start
KillSignal=SIGINT
TimeoutSec=15
However, as soon as I start the service with
systemctl --user start awesome.service
The unit fails with message
systemd[21209]: Failed at step GROUP spawning /home/abdo/.config/systemd/scripts/awesome.sh: Operation not permitted
Running the same service from the system systemd instance (with an already
running user-owned xorg), works as expected, creating a new session.
I think it fails setting the group for the process, it does not even get to the
PAM stuff. The user abdo is the same for which the systemd user instance is
running, of course.
Is this a bug in systemd or it's me missing something?
Thanks!
Abdó.
I'm happily using systemd 204 user instance to handle my desktop (xorg, awesome
wm, mpd, etc.) in Arch. I started experimenting with systemd 206 trying to adapt
my setup to the changes in cgroups, slices, and all that.
In 206, systemd user session is started automatically by pam_systemd when I
login to a tty. Then, I want to manually launch my window manager, in a new
logind session for my user, on a different tty.
I tried adding User and PAMName to my window manager unit awesome.service:
[Unit]
Description=Awesome window manager
After=***@0.service
Requisite=***@0.service
Requires=dbus.socket
[Service]
User=abdo
PAMName=login
TTYPath=/dev/tty7
Type=simple
SyslogIdentifier=awesome
Environment=DISPLAY=:0
ExecStart=/home/abdo/.config/systemd/scripts/awesome.sh start
KillSignal=SIGINT
TimeoutSec=15
However, as soon as I start the service with
systemctl --user start awesome.service
The unit fails with message
systemd[21209]: Failed at step GROUP spawning /home/abdo/.config/systemd/scripts/awesome.sh: Operation not permitted
Running the same service from the system systemd instance (with an already
running user-owned xorg), works as expected, creating a new session.
I think it fails setting the group for the process, it does not even get to the
PAM stuff. The user abdo is the same for which the systemd user instance is
running, of course.
Is this a bug in systemd or it's me missing something?
Thanks!
Abdó.