Skip to main content

Exception in thread "main" java.lang.NoClassDefFoundError during starting your Tomcat

If you are using Tomcat v.6 or v.7, you probably get the following error:
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/juli/logging/LogFactory at org.apache.catalina.startup.Bootstrap.<clinit>(Bootstrap.java:54) Caused by: java.lang.ClassNotFoundException: org.apache.juli.logging.LogFactory at java.net.URLClassLoader$1.run(URLClassLoader.java:217) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:205) at java.lang.ClassLoader.loadClass(ClassLoader.java:323) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294) at java.lang.ClassLoader.loadClass(ClassLoader.java:268) at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:336) ... 1 more Could not find the main class: org.apache.catalina.startup.Bootstrap. Program will exit.

This error occurs because it misses the tomcat-juli.jar in the Launch environment
So to solve it do the following steps:

  1. Double click on the installed Ode v1.x Server in the 'Server' View.
  2.  Click on Open launch configuration. figure1
  3. Choose  Classpath tab > Add External JARs > [your TOMCAT_DIR]\bin\tomcat-juli.jar. figure 2,3,4
  4.  Then Apply then OK.
  5. Start your Ode v1.x Server in the Server View by right clicking on it > Start or press the start icon.
Ode server at localhost

click on User Entries then add external jars

Choose tomcat-juli.jar

click Apply the OK

Start your server up by clicking on start or icon



Comments

Popular posts from this blog

Error Class names are only accepted if annotation processing is explicitly requested

Do you get the following error? Class names, 'Hello', are only accepted if annotation processing is explicitly requested 1 error In case you got this error, then you forget to add .java to the file name when you compile it So when you want to compile a file using cmd console window write the filename.java extension Example: Javac Hello.java If you write it in this way the error will go away. So don’t forget to include suffix with your file name during compilation.

Multitenancy

What is Multitenancy? Multitenancy is an architecture in which a single instance of a software application serves multiple customers. It gives the ability to use the same software and interfaces to configure resources and it isolates customer-specific traffic and data. Each customer is called a tenant. Tenants may be given the ability to configure some parts of the application, such as color of the user interface ( UI ) or business rules , but they cannot change the application's code . This means that although tenants are using the same building blocks in their configuration, the appearance or workflow of the application may be different for two tenants. Also, the Service Level Agreement (SLA) of each tenant can differ [1]. Multitenancy vs. Singletenancy: Multitenancy can be economical because software development and maintenance costs are shared. It can be contrasted with single-tenancy, an architecture in which each customer has their own software instance and ...

An attempt was made to insert a node where it is not permitted

Do you face this Error while you are writing code to generate xml file from java? Exception in thread "main" org.w3c.dom.DOMException : HIERARCHY_REQUEST_ERR: An attempt was made to insert a node where it is not permitted.        at com.sun.org.apache.xerces.internal.dom.CoreDocumentImpl.insertBefore(Unknown Source)        at com.sun.org.apache.xerces.internal.dom.NodeImpl.appendChild(Unknown Source)        at generatexml.WriteXMLFile.main( WriteXMLFile.java:30 ) Well the answer is: Don't insert the node where it isn't permitted. Change your generated directory file path from 'C' to other directory ex, D or to any directory you have. Make sure the ‘appendChild’ is referring to the right element. Don’t appending twice, only make it once. Ex, //Writetoxml.java   Element rootElement = doc . createElement ( " Company " );   doc . appendChild ( ro...