8
votes

After the fresh install of JFrog Artifactory server I am not able to start up the application. I am using a percona 5.6 mysql db server.


artifactory.service - Setup Systemd script for Artifactory in Tomcat Servlet Engine
   Loaded: loaded (/usr/lib/systemd/system/artifactory.service; enabled; vendor preset: disabled)
   Active: activating (auto-restart) (Result: resources) since Mon 2018-01-22 04:22:34 EST; 2s ago
  Process: 8618 ExecStart=/opt/jfrog/artifactory/bin/artifactoryManage.sh start (code=exited, status=0/SUCCESS)

Jan 22 04:22:34 xxx-xxxx-xxxx systemd[1]: Failed to start Setup Systemd script for Artifactory in Tomcat Servlet Engine.
Jan 22 04:22:34 xxx-xxxx-xxxx systemd[1]: Unit artifactory.service entered failed state.
Jan 22 04:22:34 xxx-xxxx-xxxx systemd[1]: artifactory.service failed.

When I checked artifactory.bootstrap.log I am getting following error.

2018-01-22 04:07:43 [ARTIFACTORY] [INFO ] master.key file currently missing - waiting for Access to create it. Reattempting to check master.key file existence in 1 second.

If you need any more logs to diagnose please let me know.

Regards,

4
looks like the Access service did not start successfully, can you check you catalina logs (in $ARTIFACTORY_HOME/logs/catalina/ ) ? Might be Access which cannot connect to your mysql DB server - jroquelaure
Had to give up on this approach and went with a docker install. Thank you for the advice. Will try this one more time later. - Senthil
Had to give up on this approach and went with a docker install, Will try this one more time later. - Senthil
How long did you let the process run? I was impatient with my first run. When Artifactory started spewing errors - mostly that "master.key file currently missing" I stopped it and tried again. Turns out the error message is expected. I unpacked the zip again to replace any corrupted config/derby files and reran. After about a minute the errors stopped, Access was up and the landing page worked. - Paxic
@jroquelaure, what is the Access service? How can I verify that it is running, which version it is, and whether that version matches with what Artifactory expects? - dokaspar

4 Answers

1
votes

I had the same problem. Running under Ubuntu 16.04 and the deb installation package for 5.10.1.

It looks like the $ARTIFACTORY_HOME points to /var/opt/jfrog/artifactory, with the binaries in /opt/jfrog/artifactory. Changing $ARTIFACTORY_HOME to point to /opt/jfrog/artifactory allows it to start, but puts all the data there as well (access, backup, data, logs and support directories). This is fine for me as we only have a demo licence and we're just doing some testing, but less than ideal if you want to keep your data under /var.

I did try leaving $ARTIFACTORY_HOME alone and creating links to the other directories but that didn't seem to work. I haven't bothered investigating that though, since I now have a test system that looks like it works.

1
votes

I had this error recently with version 6.7.3 using java 8 on Solaris 11.
First I unzipped the file, checked all my file permissions, they were good.
Then, I set my ARTIFACTORY_HOME and JAVA_HOME in the artifactory.default file

Next, I ran the following
openssl rand -hex 16 > /m1/artifactory-oss-6.7.3/etc/security/master.key

and started Artifactory.

I found the openssl command to manually create the master.key here:
https://www.jfrog.com/jira/browse/RTFACT-15699

0
votes

Check this link: https://www.jfrog.com/confluence/display/RTF4X/Master+Key+Encryption

go to Security >> Security Configuration >> Encript button

that will create the artifactory.key file, duplicate it and rename the copy to master.key

Edit 1

found out in version 5 you need the JAVA_HOME set, in version 4 doesn't matter,

0
votes

i got similar issue and fixed it by correcting owner / group permissions on /var/opt/jfrog/artifactory/access/etc path.

i was creating the below directories using ansible playbook before running artifactory docker image.

/var/opt/jfrog/artifactory/access/etc

/var/opt/jfrog/artifactory/backup
/var/opt/jfrog/artifactory/data
/var/opt/jfrog/artifactory/etc
/var/opt/jfrog/artifactory/logs