[RTFACT-16909] artifactory service start fails with zip installation on ubuntu 18.04 Created: 09/Jun/18  Updated: 25/Jun/19

Status: Open
Project: Artifactory Binary Repository
Component/s: None
Affects Version/s: 6.0.2
Fix Version/s: None

Type: Bug Priority: Normal
Reporter: Makson Lee Assignee: Unassigned
Resolution: Unresolved Votes: 7
Labels: None
Environment:

ubuntu: 18.04


Issue Links:
Contains(WBSGantt)
is contained in RTFACT-16618 Support Ubuntu 18.04 LTS - Debian ins... Open

 Description   

$ sudo service artifactory start

Job for artifactory.service failed because the service did not take the steps required by its unit configuration.
See "systemctl status artifactory.service" and "journalctl -xe" for details.

$ tail -10 /var/log/syslog

Jun  9 10:25:09 artifactory systemd[1]: Failed to start Setup Systemd script for Artifactory in Tomcat Servlet Engine.
Jun  9 10:25:14 artifactory systemd[1]: artifactory.service: Service hold-off time over, scheduling restart.
Jun  9 10:25:14 artifactory systemd[1]: artifactory.service: Scheduled restart job, restart counter is at 2.
Jun  9 10:25:14 artifactory systemd[1]: Stopped Setup Systemd script for Artifactory in Tomcat Servlet Engine.
Jun  9 10:25:14 artifactory systemd[1]: Starting Setup Systemd script for Artifactory in Tomcat Servlet Engine...
Jun  9 10:25:14 artifactory artifactoryManage.sh[10797]: /usr/bin/java
Jun  9 10:25:14 artifactory artifactoryManage.sh[10797]: Artifactory Tomcat already started
Jun  9 10:25:14 artifactory systemd[1]: artifactory.service: Can't open PID file /opt/artifactory/run/artifactory.pid (yet?) after start: No such file or directory
Jun  9 10:25:14 artifactory systemd[1]: artifactory.service: Failed with result 'protocol'.
Jun  9 10:25:14 artifactory systemd[1]: Failed to start Setup Systemd script for Artifactory in Tomcat Servlet Engine.



 Comments   
Comment by Batel Tova [ 13/Jun/18 ]

This is a service installation a zip installation that equal to RTFACT-16618

Comment by Louis-Gabriel Thibault [ 20/Dec/18 ]

Please see http://vivin.net/2018/09/26/getting-artifactory-running-on-ubuntu-18-04/

Comment by heapifyman [ 07/Jan/19 ]

Louis-Gabriel Thibault it appears the link above is dead?

Comment by Louis-Gabriel Thibault [ 07/Jan/19 ]

Link is dead to me too.

Problem is bionic systemd being more restrictive with PID file permission (see http://manpages.ubuntu.com/manpages/bionic/man5/systemd.service.5.html section PIDFile=). So the idea is to modify artifactoryService.sh so its PID file routines perform as root and not as user artifactory. There are 4 lines where the solution is to inject "su" or "sudo -u" IIRC. 

Hope this helps.

I'm sorry I cannot provide specifics right now; I'll update this post when I can.

 

Comment by Jason Williams [ 11/Jan/19 ]

Wayback machine archived it:

http://web.archive.org/web/20181012191636/http://vivin.net/2018/09/26/getting-artifactory-running-on-ubuntu-18-04/

Comment by Louis-Gabriel Thibault [ 11/Jan/19 ]

Nice catch Jason Williams. I just reviewed your link and confirm this is a working fix for us.

Comment by heapifyman [ 12/Jan/19 ]

Louis-Gabriel Thibault the changes described in the linked tutorial seem to be working. Thanks.

However, they are reverted again once artifactory gets updated via apt, for example.

How would you prevent that from happening?

Generated at Mon Jul 22 21:18:34 UTC 2019 using JIRA 7.6.3#76005-sha1:8a4e38d34af948780dbf52044e7aafb13a7cae58.