Ubuntu将tomcat7 端口改为81

前端之家收集整理的这篇文章主要介绍了Ubuntu将tomcat7 端口改为81前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。

Ubuntu将tomcat7 端口改为81:

apt-get install authbind

vi /etc/default/tomcat7

AUTHBIND=yes (默认为#AUTHBIND=no)
:wq

vi /var/lib/tomcat7/conf/server.xml (默认为8080)

<Connector port="81" protocol="HTTP/1.1"
connectionTimeout="20000"
URIEncoding="UTF-8"
redirectPort="8443" />
:wq

touch /etc/authbind/byport/81

chown tomcat7:tomcat7 /etc/authbind/byport/81

chmod 0755 /etc/authbind/byport/81

service tomcat7 restart

netstat –ntpl | grep 81

原文链接:https://www.f2er.com/ubuntu/349456.html

猜你在找的Ubuntu相关文章