Fatal Error: ClassNotFoundException

Avatar

Avatar
Validate 1
Level 1
ArchanaVijayakumar
Level 1

Likes

0 likes

Total Posts

4 posts

Correct reply

0 solutions
Top badges earned
Validate 1
View profile

Avatar
Validate 1
Level 1
ArchanaVijayakumar
Level 1

Likes

0 likes

Total Posts

4 posts

Correct reply

0 solutions
Top badges earned
Validate 1
View profile
ArchanaVijayakumar
Level 1

24-06-2020

When execute the AEM jar via command prompt using 

"java -Xmx5130m -jar <path>\aem-author-4502.jar -gui"

 

it shows the below error dialog box 

Capture.PNG

 

 

 

 

But when I run the jar by double clicking it works fine.
Can anyone facing the same before or any solution to overcome this.?

 

Java version 8

AEM jar version 6.4

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Give Back 50
Employee
berliant
Employee

Likes

207 likes

Total Posts

315 posts

Correct reply

98 solutions
Top badges earned
Give Back 50
Give Back 5
Give Back 3
Give Back 25
Give Back 10
View profile

Avatar
Give Back 50
Employee
berliant
Employee

Likes

207 likes

Total Posts

315 posts

Correct reply

98 solutions
Top badges earned
Give Back 50
Give Back 5
Give Back 3
Give Back 25
Give Back 10
View profile
berliant
Employee

24-06-2020

Your current execution includes a path D:/AEM-Jar/author/aem-author-4502.jar

Can you switch to D:/AEM-Jar/author/ and run the execution command from that path?

 

Answers (3)

Answers (3)

Avatar

Avatar
Give Back 5
Employee
vanegi
Employee

Likes

392 likes

Total Posts

378 posts

Correct reply

148 solutions
Top badges earned
Give Back 5
Give Back 3
Give Back 10
Give Back
Boost 50
View profile

Avatar
Give Back 5
Employee
vanegi
Employee

Likes

392 likes

Total Posts

378 posts

Correct reply

148 solutions
Top badges earned
Give Back 5
Give Back 3
Give Back 10
Give Back
Boost 50
View profile
vanegi
Employee

24-06-2020

Hi Archana,

After reviewing the exception logs which is complaining about the insufficient heap size, it is advised that your allocated heap does not exceed 50% of your total RAM. Having said that if you have 2P GB RAM, increasing to -XmxPG should be okay. 

 

To fix the error, it is recommended to increase -Xmx depending on the instance RAM size as calculated above.

 

Hope this helps!!

 

Thanks,

Vaishali

Avatar

Avatar
Give Back 10
MVP
Varun_Shakya
MVP

Likes

124 likes

Total Posts

97 posts

Correct reply

24 solutions
Top badges earned
Give Back 10
Ignite 3
Ignite 1
Give Back 5
Give Back 3
View profile

Avatar
Give Back 10
MVP
Varun_Shakya
MVP

Likes

124 likes

Total Posts

97 posts

Correct reply

24 solutions
Top badges earned
Give Back 10
Ignite 3
Ignite 1
Give Back 5
Give Back 3
View profile
Varun_Shakya
MVP

24-06-2020

Try this 

java -XX:MaxPermSize=256m -Xmx1024M -jar <Name of jar file>

Avatar

Avatar
Affirm 50
MVP
Vaibhavi
MVP

Likes

216 likes

Total Posts

181 posts

Correct reply

61 solutions
Top badges earned
Affirm 50
Validate 1
Ignite 1
Give Back 5
Give Back 3
View profile

Avatar
Affirm 50
MVP
Vaibhavi
MVP

Likes

216 likes

Total Posts

181 posts

Correct reply

61 solutions
Top badges earned
Affirm 50
Validate 1
Ignite 1
Give Back 5
Give Back 3
View profile
Vaibhavi
MVP

24-06-2020

Hi @ArchanaVijayakumar 

 

I believe you have followed the technical requirements listed here. https://docs.adobe.com/docs/en/aem/6-1/deploy/technical-requirements.html#Virtual%20&%20Cloud%20Comp...

Difference I can notice in your scenario with the command line startup and double clicking jar is maxheap size allocation. 

Can you please try this below solutions:

1.Remove the -Xmx param and try to run the jar. (This will pick the standard heapsize. Suggesting this to know if the issue is due to heapsize allowcation in the system). 

2. Please check the stderr.log. you should see the errors related to startup here. 

ArchanaVijayakumar

I'm facing the same err after removing Xmx param from the command and also I have included the error log details

 

@Vaibhavi 


Low-memory action set to fork
Using 64bit VM settings, min.heap=1024MB, min permgen=256MB, default fork arguments=[-Xmx1024m, -XX:MaxPermSize=256m]
**** WARNING: insufficent heap memory ******************************************
The JVM reports 910 MB but we recommend at least 1024 MB +/- 20
Use your JVM's heap size option (like -Xmx1024M) to set that size.
Will fork a JVM to get enough memory.
********************************************************************************
No console, will fork to get enough memory
Not forking JVM as -nofork option is set
Setting properties from filename 'D:/AEM-Jar/author/aem-author-4502.jar'
Option '-quickstart.server.port' set to '4502' from filename aem-author-4502.jar
Verbose option not active, closing stdin and redirecting stdout and stderr
Redirecting stdout to D:\AEM-Jar\author\crx-quickstart\logs\stdout.log
Redirecting stderr to D:\AEM-Jar\author\crx-quickstart\logs\stderr.log
ResourceProvider paths=[/gui, /gui/default]
loadProperties: found /gui/default/gui.properties
loadProperties: found /gui/gui.properties
getResourceURL: found /gui/cq55icon_round_WIN_512x512.gif
getResourceURL: found /gui/cq55icon_round_WIN_256x256.gif
getResourceURL: found /gui/cq55icon_round_WIN_128x128.gif
getResourceURL: found /gui/cq55icon_round_WIN_64x64.gif
getResourceURL: found /gui/cq55icon_round_WIN_48x48.gif
getResourceURL: found /gui/cq55icon_round_WIN_32x32.gif
getResourceURL: found /gui/cq55icon_round_WIN_16x16_block.gif
getResourceURL: found /gui/gui_bg_start.png
getResourceURL: found /gui/gui_bg_on_blank.png
getResourceURL: found /gui/gui_bg_off.png
RAWProcessor succesfully installed
Opening browser using cmd=rundll32 url.dll,FileProtocolHandler "http://localhost:4502/"
Startup time:71 seconds
http://localhost:4502/
Quickstart started
Exception in thread "sling-oak-5" java.lang.NullPointerException
at org.apache.sling.commons.threads.impl.DefaultThreadPool$LoggingThreadLocalChangeListener.changed(DefaultThreadPool.java:172)
at org.apache.sling.commons.threads.impl.ThreadLocalCleaner.changed(ThreadLocalCleaner.java:210)
at org.apache.sling.commons.threads.impl.ThreadLocalCleaner.diff(ThreadLocalCleaner.java:173)
at org.apache.sling.commons.threads.impl.ThreadLocalCleaner.cleanup(ThreadLocalCleaner.java:148)
at org.apache.sling.commons.threads.impl.ThreadPoolExecutorCleaningThreadLocals.afterExecute(ThreadPoolExecutorCleaningThreadLocals.java:75)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Exception in thread "sling-oak-2" java.lang.NullPointerException
at org.apache.sling.commons.threads.impl.DefaultThreadPool$LoggingThreadLocalChangeListener.changed(DefaultThreadPool.java:172)
at org.apache.sling.commons.threads.impl.ThreadLocalCleaner.changed(ThreadLocalCleaner.java:210)
at org.apache.sling.commons.threads.impl.ThreadLocalCleaner.diff(ThreadLocalCleaner.java:173)
at org.apache.sling.commons.threads.impl.ThreadLocalCleaner.cleanup(ThreadLocalCleaner.java:148)
at org.apache.sling.commons.threads.impl.ThreadPoolExecutorCleaningThreadLocals.afterExecute(ThreadPoolExecutorCleaningThreadLocals.java:75)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
CHILD process: shutdown hook
CHILD process: exiting

Vaibhavi

Perfect, so exception is due to heapsize. Please follow the below post.

https://experienceleaguecommunities.adobe.com/t5/adobe-experience-manager/insufficent-heap-memory-er...