我正在尝试启动Tomcat 7.0服务器。在启动期间,抛出此错误:
October 31, 2013 10:34:44 AM org.apache.catalina.core.StandardServer await
SEVERE: StandardServer.await: create[localhost:8005]:
java.net.SocketException: Address family not supported by protocol family: create
at java.net.ServerSocket.createImpl(ServerSocket.java:308)
at java.net.ServerSocket.getImpl(ServerSocket.java:257)
at java.net.ServerSocket.bind(ServerSocket.java:376)
at java.net.ServerSocket.<init>(ServerSocket.java:237)
at org.apache.catalina.core.StandardServer.await(StandardServer.java:427)
at org.apache.catalina.startup.Catalina.await(Catalina.java:766)
at org.apache.catalina.startup.Catalina.start(Catalina.java:712)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:601)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:322)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:456)
如何正确启动服务器?
答案 0 :(得分:1)
你原来的问题提到你不能ping localhost。如果是这种情况,那么Tomcat也无法在localhost上启动。
请参阅https://askubuntu.com/questions/34783/what-would-cause-ping-localhost-to-fail