Liunx中tomcat部署工程----无法访问

今天我在myeclipse写了一些测试数据提供给同事用,本地测试没问题,但是部署到liunx上就404无法访问

查看logs下日志文件
SEVERE: Error configuring application listener of class com.sun.faces.config.ConfigureListener
java.lang.NoClassDefFoundError: javax/el/ExpressionFactory
        at java.lang.Class.getDeclaredConstructors0(Native Method)
        at java.lang.Class.privateGetDeclaredConstructors(Class.java:2389)
        at java.lang.Class.getConstructor0(Class.java:2699)
        at java.lang.Class.newInstance0(Class.java:326)
        at java.lang.Class.newInstance(Class.java:308)
        at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3744)
        at org.apache.catalina.core.StandardContext.start(StandardContext.java:4252)
        at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:760)
        at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:740)
        at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:544)
        at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:980)
        at org.apache.catalina.startup.HostConfig.deployDirectories(HostConfig.java:943)
        at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:500)
        at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1203)
        at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:319)
        at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:120)
        at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1022)
        at org.apache.catalina.core.StandardHost.start(StandardHost.java:736)
        at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1014)
        at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
        at org.apache.catalina.core.StandardService.start(StandardService.java:448)
        at org.apache.catalina.core.StandardServer.start(StandardServer.java:700)
        at org.apache.catalina.startup.Catalina.start(Catalina.java:552)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:295)
        at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:433)
Caused by: java.lang.ClassNotFoundException: javax.el.ExpressionFactory
        at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1436)
        at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1282)
        ... 29 more

查了查发现是缺少类,为什么会缺少类呢!通过查看2个tomcat版本发现,liunx上是5.5.30的
本地的是6.0.32的,而在查看6.0.32的lib目录下有以下jar
Liunx中tomcat部署工程----无法访问

5的下边是

Liunx中tomcat部署工程----无法访问

下边这4个包是tomcat6在构建的时候自动加入的,5是不支持的
javaee.jar
jsf-api.jar
jsf-impl.jar
jstl-1.2.jar
全部删掉,这样就可以访问了,因为5不支持!!只有6才支持这几个包

你可能感兴趣的:(tomcat)