Hi AEM Guru's,
When trying to start our AEM instance i am getting below error. This is bit urgent .. Please help
sudo -u cqadm ./start 02.06.2021 01:54:15.040 INFO [main] Setting sling.home=crx-quickstart (command line) ./start: line 89: crx-quickstart/conf/cq.pid: Permission denied
02.06.2021 01:54:15.065 INFO [main] Starting Apache Sling in /opt/cqadm/aem5.6/aemcms/author_407/crx-quickstart
02.06.2021 01:54:15.078 INFO [main] Checking launcher JAR in folder /opt/cqadm/aem5.6/aemcms/author_407/crx-quickstart/launchpad 02.06.2021 01:54:15.451 INFO [Apache Sling Control Listener@/127.0.0.1:2889] Apache Sling Control Listener started02.06.2021 01:54:15.451 ERROR [main] Cannot launch: Cannot install jar:file:/opt/cqadm/aem5.6/aemcms/author_407/crx-quickstart/app/cq-quickstart-5.6.0-standalone.jar!/resources/org.apache.sling.launchpad.base.jar for use 02.06.2021 01:54:15.451 ERROR [main] java.io.FileNotFoundException: /opt/cqadm/aem5.6/aemcms/author_407/crx-quickstart/launchpad/Loader_tmp_1622616855081org.apache.sling.launchpad.base.jar (Permission denied) 02.06.2021 01:54:15.451 ERROR [main] at java.io.FileOutputStream.open(Native Method) 02.06.2021 01:54:15.451 ERROR [main] at java.io.FileOutputStream.<init>(FileOutputStream.java:221) 02.06.2021 01:54:15.451 ERROR [main] at java.io.FileOutputStream.<init>(FileOutputStream.java:171) 02.06.2021 01:54:15.451 ERROR [main] at org.apache.sling.launchpad.base.shared.Loader.spool(Loader.java:270) 02.06.2021 01:54:15.451 ERROR [main] at org.apache.sling.launchpad.base.shared.Loader.installLauncherJar(Loader.java:161) 02.06.2021 01:54:15.451 ERROR [main] at org.apache.sling.launchpad.app.Main.doStart(Main.java:357) 02.06.2021 01:54:15.451 ERROR [main] at org.apache.sling.launchpad.app.Main.doStart(Main.java:322) 02.06.2021 01:54:15.451 ERROR [main] at org.apache.sling.launchpad.app.Main.main(Main.java:123) 02.06.2021 01:54:15.453 ERROR [main] Failed to start Sling; terminating
Solved! Go to Solution.
Views
Replies
Total Likes
Hi @niks1
Please ensure root user is not starting the AEM instance. A service user should be created who should have complete access to /opt/cqadm and the same user should be used to start the application.
Please login as root user and make sure none of the java process are running.
Then navigate to /opt/cqadm
Execute the below command:
Thanks!
Hi @niks1
Please ensure root user is not starting the AEM instance. A service user should be created who should have complete access to /opt/cqadm and the same user should be used to start the application.
Please login as root user and make sure none of the java process are running.
Then navigate to /opt/cqadm
Execute the below command:
Thanks!
Views
Replies
Total Likes
Hi @niks1
Please login as root user and make sure none of the java process are running.
Then navigate to /opt/cqadm
Execute the below command:
Views
Replies
Total Likes
Views
Replies
Total Likes
Hi @niks1! I have updated my answer with a couple of things to check.
Views
Replies
Total Likes
Hi @niks1!
The interesting bits of that log extract are the following:
ERROR [main] java.io.FileNotFoundException: /opt/cqadm/aem5.6/aemcms/author_407/crx-quickstart/launchpad/Loader_tmp_1622616855081org.apache.sling.launchpad.base.jar (Permission denied)
It seems that at least the mentioned file sis not accessible by the executing user cqadm, probably even more files.
Please double check on the ownership and permissions of all files in your crx-quickstart directory (recursively) to ensure that they all belong to the executing user.
chown -r cqadm: /opt/cqadm/aem5.6/aemcms/author_407/*
This is a common issue if the instance has been started with a different user (most likely: root) in the past. If this is the case, please have a close look at the startup and error logs once file permissions have been corrected and you restart the instance to see if there are any other side effects.
Update
As you mention that file ownership and permissions look ok, please double check on that trying to read the according file (e. g. just user "cat". That won't produce any readable output but it will show if the user has read access).
Have you just checked the ownership/permissions or did you actually re-set them (recursively)?
Would you mind sharing the current ownership/permissions of that specific file?
If ownership and permissions are really set correctly, then there must be some other mechanism that prevents file access. I've seen security tools like selinux causing similar issues in the past. So please double check on the general system logs (/var/log/messages and the like) to see if you find any message related to the AEM startup.
You may also want to execute the startup not using the sudo command from you initial post but actually changing user (su) to the cqadm user and trying to start from there.
General advice on trouble shooting:
Hope that helps!
Views
Replies
Total Likes
Views
Replies
Total Likes
Views
Likes
Replies
Views
Likes
Replies