linux关于端口的查询命令。

来源:互联网 发布:信用卡网络怎么套现 编辑:程序博客网 时间:2024/06/05 06:54

lsof -i :22

查看22号端口命令,根据端口查命令

netstat -anp|grep vnc

根据命令查端口

ps -ef|grep xxx

ps -aux|grep xxx

查看某个进程信息

top:看cpu

free -m:看内存

测试udp端口:

nc -vuz ip port


一个网卡绑定多 ip
方法一、建立eth0:1在网卡后加冒号和数字的文件
cp /etc/sysconfig/network-scripts/eth0 /etc/sysconfig/network-scripts/eth0:1
再修改下eth0:1就可以了.
方法二、
在/etc/sysconfig/network-scripts/下创建一个文件:ifcfg-ethX-rangeX ("X"为网卡号) 
文件内容: 
IPADDR_START=<start ip> 
IPADDR_END=<end ip> 
CLONENUM=0 
可以有 256个 ip