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

Install section is missing in the systemd unit file #44

Closed
ghost opened this issue Feb 15, 2016 · 2 comments
Closed

Install section is missing in the systemd unit file #44

ghost opened this issue Feb 15, 2016 · 2 comments
Labels

Comments

@ghost
Copy link

ghost commented Feb 15, 2016

I just tried to set up marmoset with CentOS 7 (systemd 219). After copying the unit file provided in the repository and executing "systemctl daemon-reload", the service is recognized:

[root@localhost ext]# systemctl status marmoset
● marmoset.service - marmoset API
Loaded: loaded (/etc/systemd/system/marmoset.service; static; vendor preset: disabled)
Active: inactive (dead)

However activating it fails:

[root@localhost ext]# systemctl enable marmoset
The unit files have no [Install] section. They are not meant to be enabled
using systemctl.
Possible reasons for having this kind of units are:

  1. A unit may be statically enabled by being symlinked from another unit's
    .wants/ or .requires/ directory.
  2. A unit's purpose may be to act as a helper for some other unit which has
    a requirement dependency on it.
  3. A unit may be started when needed via activation (socket, path, timer,
    D-Bus, udev, scripted systemctl call, ...).

The error message clearly states that the unit file needs an [Install] section to be enabled. Unless I'm missing anything else or you plan to use it in another way as described in the message, I believe the [Install] section should be added to the file.

@bastelfreak
Copy link
Member

this seems to be an issue with older systemd version, I'm unable to reproduce this on 228-4, however it is best practice to have a working [install] section so I added one in #46. Please verify if this fixed your issue.

@ghost
Copy link
Author

ghost commented Feb 15, 2016

works:

[root@localhost ext]# systemctl enable marmoset
Created symlink from /etc/systemd/system/multi-user.target.wants/marmoset.service to /etc/systemd/system/marmoset.service.

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

No branches or pull requests

1 participant