The requested resource (/application/) is not available
来源:互联网 发布:军工行业 云计算 编辑:程序博客网 时间:2024/06/05 17:57
在tomcat的目录conf\Catalina\localhost下,可以增加xml文件,来指向file系统中任意一处作为网站系统的子根目录,例如:atcs.xml文件:<!-- Context configuration file for the Tomcat Host Manager Web App $Id: host-manager.xml 303743 2005-03-11 22:39:26Z remm $--><Context path="/atcs" docBase="D:\WorkSpace\Huadu_Atcs3\WebContent"privileged="true" antiResourceLocking="false" antiJARLocking="false"></Context>其中docBase指向站点的根目录,path与文件名相同(在此为atcs),这个path最好也要与docBase下的WEB-INF下的web.xml里面的 <context-param> <param-name>webAppRootKey</param-name> <param-value>atcs.root</param-value> </context-param>paraam-value相同。三者相同的情况下,才可以正确的访问网站(访问方式:http://localhost:8080/atcs)这样就作为localhost的一个子站点可以运行了。常见错误:多个工程目录下的web.xml文件的<param-value>atcs.root</param-value>相同,就算在tomcat的conf下配置不同的名,例如配置atcs2.xml指向另外一个工程目录,但是恰巧那个工程下的web.xml里面也配置相同的webAppRootKey,那么将会出现其中一个工程不能够访问的问题。网页出现经典的The requested resource (/atcs/) is not available错误!问题发现方法:在myEclipse下配置log4j,之后会将一些不会报出来的错误亦会报出来,根据信息就可以发现是相同的webAppRootKey覆盖问题。在此我的log4j的报错信息:Web app root system property already set to different value: 'atcs.root' = [D:\workspace2\Huadu_Atcs3\WebContent\] instead of [D:\WorkSpace\Huadu_Atcs3\WebContent\] - Choose unique values for the 'webAppRootKey' context-param in your web.xml files!
当Tomcat启动时抛出webAppRootKey错误时,可启动失败的项目中加入以下参数即可:
<context-param><param-name>webAppRootKey</param-name><param-value>unicomEOMS.root</param-value></context-param>
- The requested resource (/application/) is not available
- The requested resource (...) is not available
- The requested resource is not available.
- The requested resource is not available.
- The requested resource is not available.
- The requested resource () is not available.
- The requested resource is not available.
- The requested resource is not available
- the requested resource is not available
- The requested resource (/) is not available
- The requested resource (/) is not available
- The requested resource (/) is not available
- The requested resource is not available
- The requested resource (/) is not available
- The requested resource is not available
- The requested resource is not available.http404
- The requested resource is not available
- The requested resource (/) is not available
- javascript键盘事件event.keycode大全
- sizeof和strlen的区别
- 记录一下:彩色电子阅读器 Nook Color
- java 数据库连接方式(五)
- OpenVPN协议解析-握手数据包分析
- The requested resource (/application/) is not available
- 解决NP问题——旅行商问题的一点思路之一
- 让你用GCC编译的程序拥有一个自定义的.ico图标
- Intent的URI及其示例
- java 数据库连接方式(六)
- 级联下拉框 ajax jquery springmvc
- 分享使用iphone4的60条技巧
- 蜘蛛流
- hdu 2105