LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   tomcat webapp deploying in windows but not in linux (https://www.linuxquestions.org/questions/linux-newbie-8/tomcat-webapp-deploying-in-windows-but-not-in-linux-4175422270/)

mlnm 08-15-2012 04:29 PM

tomcat webapp deploying in windows but not in linux
 
Hi,im trying to deploy my project on tomcat 7 in rhel5
i deployed it in windows machine it works perfectly.But it doesnt on rhel5.In the catalina.out log it shows ERROR LiSTNER START.
And im getting following error on tomcat :404 -the resource not found.
Thanks in advance..

kbp 08-15-2012 06:34 PM

Could you please copy and paste the exact error, I'm pretty sure tomcat didn't write it in l33t format :)

mlnm 08-16-2012 01:44 PM

This is the error im getting on tomcat log: catalina.out
Aug 15, 2012 5:04:35 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-bio-8080"]
Aug 15, 2012 5:04:35 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["ajp-bio-8009"]
Aug 15, 2012 5:04:35 PM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 1259 ms
Aug 15, 2012 5:04:35 PM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
Aug 15, 2012 5:04:35 PM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.27
Aug 15, 2012 5:04:35 PM org.apache.catalina.startup.HostConfig deployWAR
INFO: Deploying web application archive /opt/apache-tomcat-7.0.27/webapps/cypherlogics.war
Aug 15, 2012 5:04:36 PM org.apache.catalina.core.StandardContext startInternal
SEVERE: Error listenerStart
Aug 15, 2012 5:04:36 PM org.apache.catalina.core.StandardContext startInternal
SEVERE: Context [/cypherlogics] startup failed due to previous errors
Aug 15, 2012 5:04:36 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory /opt/apache-tomcat-7.0.27/webapps/host-manager
Aug 15, 2012 5:04:36 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory /opt/apache-tomcat-7.0.27/webapps/examples
Aug 15, 2012 5:04:36 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory /opt/apache-tomcat-7.0.27/webapps/ROOT
Aug 15, 2012 5:04:36 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory /opt/apache-tomcat-7.0.27/webapps/docs
Aug 15, 2012 5:04:36 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory /opt/apache-tomcat-7.0.27/webapps/manager
Aug 15, 2012 5:04:36 PM org.apache.coyote.AbstractProtocol start
Thank u for ur reply ......

kbp 08-16-2012 06:47 PM

You'll need to increase your logging level to see what the error is, you can read http://tomcat.apache.org/tomcat-6.0-..._%28default%29 for the gorey details but I think the following should work (untested)

Try creating <your_app>/WEB-INF/classes/logging.properties with content:
Code:

java.util.logging.ConsoleHandler.level = FINEST
java.util.logging.ConsoleHandler.formatter = java.util.logging.SimpleFormatter
org.apache.catalina.level = FINEST

The ConcoleHandler should already be specified in the JDK's default logging.properties so we don't need to specify it here.

mlnm 08-28-2012 04:57 PM

Im so sorry for not replying in time ,i got a little sick so couldn't post my reply.
I enabled the logging.properties and checked out catalina.out log and i found this error:

SEVERE: Parse error in application web.xml file at jndi:/localhost/CypherLogics/WEB-INF/web.xml
org.xml.sax.SAXParseException; systemId: jndi:/localhost/CypherLogics/WEB-INF/web.xml; lineNumber: 18; columnNumber: 19; Error at (18, 19) : Can't convert argument: null
at org.apache.tomcat.util.digester.Digester.createSAXException(Digester.java:2687)
at org.apache.tomcat.util.digester.Digester.createSAXException(Digester.java:2719)
at org.apache.tomcat.util.digester.Digester.endElement(Digester.java:1054)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endElement(AbstractSAXParser.java:606)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanEndElement(XMLDocumentFra gmentScannerImpl.java:1741)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XM LDocumentFragmentScannerImpl.java:2898)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:607)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragm entScannerImpl.java:488)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:835)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:764)
at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:123)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1210)
at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:568)
at org.apache.tomcat.util.digester.Digester.parse(Digester.java:1537)
at org.apache.catalina.startup.ContextConfig.parseWebXml(ContextConfig.java:1825)
at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1201)
at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:855)
at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:345)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5161)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:895)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:871)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:615)
at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:962)
at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1603)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
at java.util.concurrent.FutureTask.run(FutureTask.java:166)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:722)
Caused by: java.lang.IllegalArgumentException: Can't convert argument: null
at org.apache.tomcat.util.IntrospectionUtils.convert(IntrospectionUtils.java:966)
at org.apache.tomcat.util.digester.CallMethodRule.end(CallMethodRule.java:476)
Note:It is working in windows without any errors.
i would be waiting for your reply......thank you

kbp 09-02-2012 05:54 PM

Quote:

SEVERE: Parse error in application web.xml file at jndi:/localhost/CypherLogics/WEB-INF/web.xml
org.xml.sax.SAXParseException; systemId: jndi:/localhost/CypherLogics/WEB-INF/web.xml; lineNumber: 18; columnNumber: 19; Error at (18, 19) : Can't convert argument: null
This seems fairly clear .. can you post the first 20 lines of web.xml? .. please make sure you put it in code tags so it's easier to read

mlnm 09-04-2012 09:25 AM

Here is the first 20 lines of my web application's web.xml:

1 <?xml version="1.0" encoding="UTF-8"?>
2 <web-app xmlns:javaee="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
3 <javaee:display-name>ECMchannelsmain</javaee:display-name>
4 <welcome-file-list>
5 <welcome-file>Channel.jsp</welcome-file>
6 <welcome-file>index.htm</welcome-file>
7 <welcome-file>index.jsp</welcome-file>
8 <welcome-file>default.html</welcome-file>
9 <welcome-file>default.htm</welcome-file>
10 <welcome-file>default.jsp</welcome-file>
11 </welcome-file-list>
12 <listener>
13 <javaee:listener-class>com.proteam.ecm.FrameWork1.DBListener</javaee:listener-class>
14 </listener>
15 <context-param>
16 <javaee:param-name>log4jExposeWebAppRoot</javaee:param-name>
17 <javaee:param-value>false</javaee:param-value>
18 </context-param>
19 <servlet>
20 <servlet-name>SiteChannelsServlet</servlet-name>
The smiles appearing are the column symbols(:)they were not created by me.

kbp 09-04-2012 06:58 PM

Code:

<?xml version="1.0" encoding="UTF-8"?>
  <web-app xmlns:javaee="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
  <javaee:display-name>ECMchannelsmain</javaee:display-name>
  <welcome-file-list>
    <welcome-file>Channel.jsp</welcome-file>
    <welcome-file>index.htm</welcome-file>
    <welcome-file>index.jsp</welcome-file>
    <welcome-file>default.html</welcome-file>
    <welcome-file>default.htm</welcome-file>
    <welcome-file>default.jsp</welcome-file>
  </welcome-file-list>
  <listener>
    <javaee:listener-class>com.proteam.ecm.FrameWork1.DBListener</javaee:listener-class>
  </listener>
  <context-param>
    <javaee:param-name>log4jExposeWebAppRoot</javaee:param-name>
    <javaee:param-value>false</javaee:param-value>
  </context-param>
  <servlet>
    <servlet-name>SiteChannelsServlet</servlet-name>

See what I mean about being easier to read in code tags? .. when you're posting just highlight the section that's code and click the "#" button.

In regard to the problem, have you added dependencies on log4j ?


All times are GMT -5. The time now is 12:27 PM.