I. Description of the problem
Today, when you start the Tomcat server in IntelliJ idea, you get the error shown in the following illustration:
Error: Agent throwing exception error : Java.rmi.server.ExportException:Port already in use:1099; nested exception is:java.net.BindExcep Tion:address already in Use:jvm_bind
This says that port 1099 is occupied by other processes.
Two. Solutions
Locate the 1099-port process, go to the Windows command, and see what process is consuming 1099 ports
Using the command : Netstat-aon|findstr 1099 to find the 1099-port-consuming process, as shown in the following illustration:
Then close the process that occupies the port: taskkill-f-pid 3756
This will enable Tomcat to start normally. The problem was solved successfully.
The following is the small series encountered Linux under Tomcat start error: Portalreadyinuse a problem, to share the solution.
The cause of the problem is many, the title does not explain the specific issues.
In this only to say my operation, encountered problems and solutions, hoping to play a role in the discussion.
Start Tomcat with the following error:
Error:exception thrown by the agent:java.rmi.server.ExportException:Port already in use:7800; Nested exception is:
Java.net.BindException:Address already in use
Checked the ${tomcat_home}/conf/server.xml,context.xml,web.xml and other configuration files, did not find the location configured 7800 ports.
So Google search, an article gave me a hint: https://bowerstudios.com/node/636
So I found the answer from the ${tomcat_home}/bin/catalina.sh startup file.
Java_opts= "-server-xms2048m-xmx2048m-xx:permsize=512m-xx:maxpermsize=512m-dcom.sun.management.jmxremote- Dcom.sun.management.jmxremote.pwd.file=/opt/app/appcode/jmxremote.password-dcom.sun.management.jmxremote.ssl= false-dcom.sun.management.jmxremote.authenticate=false-dcom.sun.management.jmxremote.port=7803 "
Analysis, because Tomcat is not configured by me, I only maintenance, and thus can not fully grasp the configuration of the essence of the installation personnel.