Find the corresponding pid by port number
Port 34048
[root@hs-152] # lsof-iRu 34048
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
Perl 22328 root 11u IPv4 75021910 0t0 TCP inc.huisou.com:34048- > 192.168.27.166:mysql (ESTABLISHED)
Find pid22328.
And then determine exactly what this 22328 is doing.
[root@hs-152 ~] # ps-ef | grep 22328
Root 22328 6033 38 14:59? 00:02:29 perl / usr/local/bin/pt-online-schema-change-- alter add COLUMN `remark` text COMMENT 'remarks'-- print-- charset utf8-- chunk-time 0.100000-- critical-load Threads_connected:1000,Threads_running:80-- max-load Threads_connected:1000 Threads_running:80-- recurse=1-- check-interval 5.000000-- alter-foreign-keys-method=none-- force-- execute-- statistics-- max-lag 3.000000-- no-version-check-- recursion-method=processlist-- progress percentage,1-- user=dba-- password=jsrh2sdshj-- host=192.168.27.166-- port=3306 dreamdream cardbook tours dreamboat orderlogs
Root 25682 24819 0 15:06 pts/0 00:00:00 grep-color=auto 22328
At this point, you can see that this is adding a field to a table
After we finally determine the mission, we can kill the process.
Kill-9 22328