Bug#791412: systemd invoking a service on its own

Michael Biebl email at michaelbiebl.de
Sat Jul 4 14:44:16 BST 2015


Am 04.07.2015 um 15:35 schrieb Ritesh Raj Sarraf:
> Package: systemd
> Version: 220-7
> Severity: normal
> 
> 
> I have a .service defined for laptop-mode-tools
> 
> rrs at chutzpah:~$ cat /lib/systemd/system/laptop-mode.service 
> [Unit]
> Description=Laptop Mode Tools
> 
> [Service]
> Type=oneshot
> #RemainAfterExit=no
> ExecStart=/usr/sbin/laptop_mode init auto
> ExecStop=/usr/sbin/laptop_mode init stop
> ExecStopPost=/bin/rm -f /var/run/laptop-mode-tools/enabled
> StandardOutput=tty
> StandardError=tty
> 
> [Install]
> WantedBy=multi-user.target
> 
> 
> 
> Do you see the following behavior of systemd to be normal ?
> I have no idea as to why it is invoking laptop-mode-tools every 22 seconds.

I'm pretty sure it's not systemd triggering the start request on it's
own. Do you install any acpi/apm/udev rules hooks? If so, I'd start
looking there.


> Another problem is:
> The ExecStart script executes /usr/sbin/laptop_mode, which internally backgroups another script, after acquiring a persistent lock.
> For what I've debugged so far, it turns out systemd quietly kills (or does not allow invocation of)  scripts that are backgrounded

Type=oneshot is not supposed to be used for processes which background.




-- 
Why is it that all of the instruments seeking intelligent life in the
universe are pointed away from Earth?

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: OpenPGP digital signature
URL: <http://alioth-lists.debian.net/pipermail/pkg-systemd-maintainers/attachments/20150704/4d1f3cba/attachment-0002.sig>


More information about the Pkg-systemd-maintainers mailing list