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

Unclean exit when the pcscd is killed by systemd (for example on reboot) #70

Closed
Jakuje opened this issue Sep 11, 2019 · 0 comments
Closed

Comments

@Jakuje
Copy link
Contributor

Jakuje commented Sep 11, 2019

The pcscd daemon exits with exit code 1 when it is killed by systemd, which confuses system thinking that there was some failure on the exit:

Sep 11 13:22:54 workstation-uefi pcscd[8750]: 08450216 pcscdaemon.c:193:signal_thread() Received signal: 15
Sep 11 13:22:54 workstation-uefi pcscd[8750]: 00000015 pcscdaemon.c:213:signal_thread() Direct suicide
Sep 11 13:22:54 workstation-uefi pcscd[8750]: 00000004 pcscdaemon.c:786:at_exit() cleaning /var/run/pcscd
Sep 11 13:22:54 workstation-uefi systemd[1]: Stopping PC/SC Smart Card Daemon...
Sep 11 13:22:54 workstation-uefi systemd[1]: pcscd.service: Main process exited, code=exited, status=1/FAILURE
Sep 11 13:22:54 workstation-uefi systemd[1]: pcscd.service: Failed with result 'exit-code'.
Sep 11 13:22:54 workstation-uefi systemd[1]: Stopped PC/SC Smart Card Daemon.

Reading through the code, it looks like it exits always with 1 (except for the alarm) so I think we should either

  • modify the shipped systemd service file to mark the exit code 1 as a successful exit code using SuccessExitStatus or - sign in front of ExecStart.
  • modify the pcscd to exit "cleanly" in case of termination by systemd.

I do not have any strong opinions which way is more correct, nor the systemd maintainers do so this is merely cosmetic issue avoiding bogus error messages filling log files on every reboot.

Initially filled as a Fedora bug: https://bugzilla.redhat.com/show_bug.cgi?id=1751153

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant