IDEA sets up remote Debug debugging

1. Modify the file %TOMCAT_HOME%\bin\catalina.sh, add the jvm startup parameters, and add the following code to the first line of the file

CATALINA_OPTS="-Xdebug -Xrunjdwp:transport=dt_socket,address=60222,suspend=n,server=y"

Set the server to listen on port 60222, and then start tomcat on the server

startup.sh

2. Set up IDEA

The idea menu bar selects Run->Edit Configurations

The interface shown in the figure below appears, click the "+" button in the upper left corner, select Remote, and then fill in the ip address and port number in positions 3 and 4 in the figure, note that the port number needs to be consistent with the address set on the server side

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325225056&siteId=291194637