首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 软件管理 > 软件架构设计 >

struts2.1 服务器起步报错

2013-09-11 
struts2.1 服务器启动报错启动struts2服务器时,报错如下:?Unable to load configuration. - bean - jar:fi

struts2.1 服务器启动报错

启动struts2服务器时,报错如下:

?

Unable to load configuration. - bean - jar:file:/F:/jQuery/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/jQuery/WEB-INF/lib/struts2-core-2.1.6.jar!/struts-default.xml:29:72at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:58)at org.apache.struts2.dispatcher.Dispatcher.init_PreloadConfiguration(Dispatcher.java:360)at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:403)at org.apache.struts2.dispatcher.FilterDispatcher.init(FilterDispatcher.java:190)at org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:275)at org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:397)at org.apache.catalina.core.ApplicationFilterConfig.<init>(ApplicationFilterConfig.java:108)at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:3709)at org.apache.catalina.core.StandardContext.start(StandardContext.java:4356)at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)at org.apache.catalina.core.StandardHost.start(StandardHost.java:719)at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)at org.apache.catalina.core.StandardService.start(StandardService.java:516)at org.apache.catalina.core.StandardServer.start(StandardServer.java:710)at org.apache.catalina.startup.Catalina.start(Catalina.java:578)at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)at java.lang.reflect.Method.invoke(Unknown Source)at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)Caused by: Unable to load bean: type: class:com.opensymphony.xwork2.ObjectFactory - bean - jar:file:/F:/jQuery/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/jQuery/WEB-INF/lib/struts2-core-2.1.6.jar!/struts-default.xml:29:72at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.register(XmlConfigurationProvider.java:222)at org.apache.struts2.config.StrutsXmlConfigurationProvider.register(StrutsXmlConfigurationProvider.java:101)at com.opensymphony.xwork2.config.impl.DefaultConfiguration.reloadContainer(DefaultConfiguration.java:165)at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:55)... 21 moreCaused by: Bean type class com.opensymphony.xwork2.ObjectFactory with the name xwork has already been loaded by bean - jar:file:/C:/Program%20Files/Apache%20Software%20Foundation/Tomcat%206.0/lib/struts2-core-2.0.11.2.jar!/struts-default.xml:30:72 - bean - jar:file:/F:/jQuery/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/jQuery/WEB-INF/lib/struts2-core-2.1.6.jar!/struts-default.xml:29:72at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.register(XmlConfigurationProvider.java:206)... 24 more2010-4-2 16:06:00 org.apache.catalina.core.StandardContext start严重: Error filterStart
?

解决:

1,保证你的struts2.1的基本jar包导入正确,并且web.xml,struts.xml 配置文件没有问题。


2,如果以上都没问题,则 是你的tomcat 安装的路径默认会有空格的,删掉重新安装tomcat ,注意将路径中的空格去掉,问题解决!!!


我的异常网推荐解决方案:com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.register,http://www.myexception.cn/j2ee/307924.html

热点排行