Debian 7 install Tomcat 7
The Tomcat 7 installed on CentOS7 is started and CentOS7 comes with the httpd service. Port 80 is occupied. After the httpd service is uninstalled, install Tomcat 7 after openjdk is installed, then we found that the default port is 8080, and we used the netstat command to check the port usage. We found that CentOS7 did not have this command. This is not scientific. The specific reason was not analyzed, what's more, the service tomcat iptables command is changed to systemctl start iptables... It's speechless, and the result is not tossed out on CentOS7. It's good to change the port to 1024 or above, but not to the port lower than 1024. I guess it's a permission problem, the default port 1024 does not grant permissions.
Debian is installed with an angry version, and apache2 is included in Debian. This is annoying.
Apt-get remove apache *
Remove all of them, and then install java to save effort. Run the command directly.
Apt-get update
Apt-get install java-package
Apt-get install tomcat7
After everything is done, modify the port number, the/etc/tomcat7/server. xml file, you know. After the modification, I found that port 80 is still difficult to use. It's strange. I thought it might be a permission problem. After some time, I found
Vi/etc/default/tomcat7
# Modify the last AUTHBIND = yes. Remember to remove.
# The effect of setting this parameter to yes is described in English. The general meaning is that you have to do this when you set the port number Xiaoyu 1023.
Restart the service.
Service tomcat7 start
OK.
To change the default webapps directory, edit/etc/tomcat7/server. xml.
Prerequisites: Create the webapps directory under/usr, and then edit the server. xml file. Add a Context at the end of the Directory, that is, </Host>.
<Context path = "" docBase = "/usr/webapps" debug = "0" reloadable = "true"> </Context>
Load Balancing between Apache and multiple Tomcat clusters in Linux
Nginx Tomcat Cluster load balancing solution notes
Instance details Tomcat component installation + Nginx reverse proxy Tomcat + Apache use mod_jk and mod_proxy Reverse Proxy and load balancing
Deploy a log server using Rsyslog + LogAnalyzer + MySQL in CentOS 6.5
Build an Apache + Tomcat environment (JK deployment process)
Tomcat details: click here
Tomcat: click here
This article permanently updates the link address: