![](https://seccdn.libravatar.org/avatar/5f188c5fb664dc110d55f04cd59a6e74.jpg?s=120&d=mm&r=g)
Le jeudi 25 août 2011 à 14:27 +0200, Dr. Werner Fink a écrit :
Hi,
does anyone know how systemd.service(5):
ExecStart= [...] Unless Type=forking is set, the process started via this command line will be considered the main process of the daemon. The command line accepts % specifiers as described in systemd.unit(5). On top of that basic environment variable substitution is supported, where ${FOO} is replaced by the string value of the environment variable of the same name. Also $FOO may appear as separate word on the command line in which case the variable is replaced by its value split at whitespaces. Note that the first argument (i.e. the binary to execute) may not be a variable, and must be a literal and absolute path name.
will work ... currently it does not and a
systemctl show kdm@tty7.service
will cause
[...] Type=forking Restart=no PIDFile=/var/run/kdm.pid NotifyAccess=none RestartUSec=100ms TimeoutUSec=1min 30s ExecStartPre={ path=/bin/echo ; argv[]=/bin/echo %p %P %I %n %N %f ; ignore=no ; start_time=[n/a] ; stop_time=[n/a] ; pid=0 ; code=(null) ; status=0/ } ExecStart={ path=/usr/bin/%p ; argv[]=/usr/bin/%p ; ignore=no ; start_time=[n/a] ; stop_time=[n/a] ; pid=0 ; code=(null) ; status=0/ } [...]
also a
systemctl start kdm@tty7.service
According to upstream, you are not supposed to create path "on the fly" like this. And ExecStart is not started in a shell, so it doesn't expand everything like a shell. If %p and other don't work, please open a bugreport on https://bugs.freedesktop.org/ against systemd. -- Frederic Crozat <fcrozat@novell.com> SUSE -- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-factory+help@opensuse.org