tomcat啓動出現如上錯誤,但是並不影響程序運行,不過看着也煩。
解決方案:
server.xml裏面剛開始是有相關配置的,本來以爲只是樣例就刪除了,其實是有用的。
<Resource name="UserDatabase" auth="Container"
type="org.apache.catalina.UserDatabase"
description="User database that can be updated and saved"
factory="org.apache.catalina.users.MemoryUserDatabaseFactory"
pathname="conf/tomcat-users.xml" />
重新把上面的代碼放到<GlobalNamingResources>標籤裏面,
注意不要放到context裏面,否則又報錯說not bound in the context。
重啓服務器,解決問題。