jenkins is missing dependency on daemon

Bug #1257733 reported by Noa Resare
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
jenkins (Ubuntu)
Triaged
Low
Unassigned

Bug Description

When installing jenkins on a fully updated vanilla 13.10 system and running /etc/init.d/jenkins status a line is printed claiming that /usr/bin/daemon is missing.

Steps to reproduce:
1. Uninstall packages jenkins and daemon on your fully updated minimal Ubuntu 13.10 system (dpkg -P jenkins deamon)
2. Install only jenkins: (apt-get install jenkins)
3. Attempt to run /etc/init.d/jenkins status

Expected outcome:
regular status output

Actual outcome:
the command prints the following:
daemon package not installed
/etc/init.d/jenkins: line 128: /usr/bin/daemon: No such file or directory

Version:
root@ubuntu:~# apt-cache policy jenkins |grep Insta
  Installed: 1.509.2+dfsg-2

Revision history for this message
Hans Joachim Desserud (hjd) wrote :

Thanks for taking your time to report this issue and help making Ubuntu better.

I get the same error message when I attempt to run `/etc/init.d/jenkins status` after installing Jenkins on an out-of-the-box Ubuntu Trusty. daemon was not installed in advance nor was it pulled in along with the other dependencies.

I looked a bit into this and found that the Jenkins package in Debian [1] depends on daemon but after that package has been synced to Ubuntu, suddenly it doesn't [2]. There's also some other differences in the dependencies listed. Since they have the exact same version number they should be identical, so I investigated further.

I then checked the debian/control file to see what it listed. Among the dependencies for the binary jenkins package was "${jenkins-daemon-deps}" which sounded promising. This in turn seems to be defined in the file debian/debian_control_vars which contains the following:
jenkins-daemon-deps= daemon, psmisc, net-tools, procps, psmisc

So I belive ${jenkins-daemon-deps} should be used as a variable/short-hand for adding those addiational dependencies, but when the package is built on Ubuntu it for some reason doesn't seem to happen.

(On another note, I'm not sure why psmisc is listed twice. )

[1] http://packages.debian.org/unstable/jenkins
[2] http://packages.ubuntu.com/trusty/jenkins

Changed in jenkins (Ubuntu):
status: New → Confirmed
tags: added: saucy trusty
Revision history for this message
James Page (james-page) wrote :

Please note that from 13.10 onwards, packaging will install both the init script and the upstart configuration.

Instead of running the init script directly, please use the service command i.e. service jenkins start|stop|restart.

This will use the correct configuration depending on which init system is in use - in Ubuntu's case, its upstart.

Changed in jenkins (Ubuntu):
status: Confirmed → Triaged
importance: Undecided → Low
Revision history for this message
Noa Resare (nresare) wrote :

I see. It seems like a bad thing to break the functionality of "/etc/init.d/jenkins status" without removing it however.

I propose that we re-enable the daemon dependency until the jenkins sysv init script is removed to at least not provide a broken user experience.

Revision history for this message
mcguire (jonathand131-gmail) wrote :

This bug affects Ubuntu 15.04 which now use systemd instead of upstart :

root@chaton:~# service jenkins start
root@chaton:~# service jenkins status
● jenkins.service - LSB: Start jenkins at boot time
   Loaded: loaded (/etc/init.d/jenkins)
   Active: active (exited) since mar. 2015-05-05 09:53:06 CEST; 3s ago
     Docs: man:systemd-sysv-generator(8)
  Process: 839 ExecStop=/etc/init.d/jenkins stop (code=exited, status=0/SUCCESS)
  Process: 913 ExecStart=/etc/init.d/jenkins start (code=exited, status=0/SUCCESS)

mai 05 09:53:06 chaton jenkins[913]: daemon package not installed
mai 05 09:53:06 chaton jenkins[913]: * Starting Jenkins Continuous Integration Server jenkins
mai 05 09:53:06 chaton jenkins[913]: /etc/init.d/jenkins: ligne 89: /usr/bin/daemon: Aucun fichier ou dossier de ce type
mai 05 09:53:06 chaton jenkins[913]: Setting up max open files limit to 8192
mai 05 09:53:06 chaton su[938]: Successful su for jenkins by root
mai 05 09:53:06 chaton su[938]: + ??? root:jenkins
mai 05 09:53:06 chaton su[938]: pam_unix(su:session): session opened for user jenkins by (uid=0)
mai 05 09:53:06 chaton jenkins[913]: -su: /usr/bin/daemon: Aucun fichier ou dossier de ce type
mai 05 09:53:06 chaton jenkins[913]: ...fail!
mai 05 09:53:06 chaton systemd[1]: Started LSB: Start jenkins at boot time.
root@chaton:~# ps ax|grep jenkins
  978 pts/1 S+ 0:00 grep --color=auto jenkins

tags: added: vivid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.