linux中tomcat启动错误:java.net.BindException: Permis...


用tomcat用户登陆,启动tomcat,发现tomcat没法启动,出现错误:LifecycleException:  Protocol handler initialization failed: java.net.BindException: Permission denied <null>:80 java

经过  netstat -lnp|grep 80  发现没有程序占用80端口 tomcat

缘由是只有root用户才可访问1024如下的端口。

解决方法一:

   重将server.xml中的端口改成8080 ,而后经过iptables将80端口跳转到8080端口

   而后:iptables -t nat -A PREROUTING -p tcp --dport 80 -j REDIRECT --to-port 8080

tcp

相关文章
相关标签/搜索