export JPDA_TRANSPORT=dt_socket
export JPDA_ADDRESS=8787
./catalina.sh jpda start
Pay attention to the port to kill pkill java
Add port 8787 to the firewall
ufw status
The default of Ubuntu 11.04 is UFW (ufw is short for uncomplicated firewall, uncomplicated firewall, cumbersome settings still need to go to iptables) firewall, which already supports interface operation. Run the ufw command on the command line to see a series of possible operations prompted.
The simplest operation:
sudo ufw status (if you are root, remove sudo, ufw status) to check the status of the firewall, mine returns: inactive (default is inactive).
sudo ufw version firewall version:
ufw 0.29-4ubuntu1
Copyright 2008-2009 Canonical Ltd.
The ubuntu system has ufw installed by default.
1. Installation
sudo apt-get install ufw
2. Enable
sudo ufw enable
sudo ufw default deny
After running the above two commands, the firewall is turned on and automatically turned on when the system starts. Close all external access to the machine, but the machine accesses external normally.
3. Enable/Disable
sudo ufw allow|deny [service]
Open or close a port, for example:
sudo ufw allow smtp allows all external IPs to access the 25/tcp (smtp) port of the machine
sudo ufw allow 22/tcp allows all external IPs to access the 22/tcp (ssh) port of the machine
This is very important. It is recommended to enable ssh remote login for software such as SecureCRT. Or do not open the firewall.
sudo ufw allow 53 allows external access to port 53 (tcp/udp)