啟動(dòng)安裝版tomcat7.0.52報(bào)錯(cuò):java.io.FileNotFoundException: Could not resolve xml resource [null] with public ID [null], system ID [web-init.xml] and base URI [jndi:/localhost/WEB-INF/web.xml] to a known, local entity.
tomcat7.0.52開始的版本才會(huì)出這個(gè)問(wèn)題,是因?yàn)榘踩目紤]tomcat7.0.52開始的版本把xmlBlockExterna屬性默認(rèn)為true,要解決這個(gè)問(wèn)題,兩種方法:
(1)把tomcat版本換成7.0.52之前的版本。
(2)把xmlBlockExterna設(shè)成false。
但是我現(xiàn)在必須使用tomcat7.0.52及其以上版本,所以采用方法(2)。解決方法如下:
tomcat安裝配置文件context.xml添加false設(shè)置
E:/tomcat/Tomcat7.0.52/conf/context.xml
設(shè)置前:<Context>
設(shè)置后:<Context xmlBlockExternal="false">
新聞熱點(diǎn)
疑難解答
圖片精選
網(wǎng)友關(guān)注