1.首先查看占用的端口号:#netstat-antp|grep服务名或端口号

如:

#netstat-antp|grephttpd

#netstat-antp|grep80

结果如下:

tcp00:::port:::*LISTEN30547/xxx

tcp1200::ffff:ip:port::ffff:182.150.22.215:49642CLOSE_WAIT30547/xxx

tcp1200::ffff:ip:port::ffff:182.150.22.215:49654CLOSE_WAIT-

2.可以看出此端口的进程号是:30547

3.kill-930547

4.over