netstat命令详解状态,netstat命令详解

By admin in 美高梅手机版4858 on 2019年3月29日

    netstat
命令用于呈现各个网络有关音讯,如互连网连接,路由表,接口状态
(Interface Statistics),masquerade 连接,多播成员 (Multicast
Memberships) 等等

    netstat
命令用于浮现种种网络有关音信,如互联网连接,路由表,接口状态
(Interface Statistics),masquerade 连接,多播成员 (Multicast
Memberships) 等等

netstat 命令用于呈现各样网络有关新闻,如网络连接,路由表,接口状态
(Interface Statistics),masquerade 连接,多播成员 (Multicast
Memberships) 等等

netstat命令,netstat命令详解

    netstat
命令用于呈现各个互连网有关音讯,如网络连接,路由表,接口状态 (Interface
Statistics),masquerade 连接,多播成员 (Multicast Memberships) 等等

1 常用选项:

    -a :(all)呈现全部选项,暗许不彰显LISTEN相关

    -t :(tcp)仅显示tcp相关选项

    -u :(udp)仅展现udp相关选项

    -n :以数显IP和端口,能显得数字的一切转化成数字。

    -l :仅列出有在 Listen (监听) 的服務状态

    -p: 展现建立有关链接的程序名

    -r :突显路由消息,路由表

    -e :呈现扩充新闻,例如uid等

    -s :按顺序协议举行总结

    -c :每隔叁个永恒时间,执行该netstat命令。

    -w:raw socket相关

2 -tan 展现全部tcp端口

[[email protected]
~]# netstat -ant

Active Internet connections (servers and established)

Proto Recv-Q Send-Q Local Address Foreign Address State

tcp 0 0 0.0.0.0:111 0.0.0.0:* LISTEN

tcp 0 0 192.168.122.1:53 0.0.0.0:* LISTEN

tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN

tcp 0 0 127.0.0.1:631 0.0.0.0:* LISTEN

tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN

tcp 0 52 192.168.29.3:22 192.168.29.1:51029 ESTABLISHED

tcp 0 0 192.168.29.3:22 192.168.29.1:51180 ESTABLISHED

tcp6 0 0 :::111 :::* LISTEN

tcp6 0 0 :::22 :::* LISTEN

tcp6 0 0 ::1:631 :::* LISTEN

tcp6 0 0 ::1:25 :::*

3 显示全数udp端口 -uan

[[email protected]
~]# netstat -anu

Active Internet connections (servers and established)

Proto Recv-Q Send-Q Local Address Foreign Address State

udp 0 0 0.0.0.0:5353 0.0.0.0:*

udp 0 0 0.0.0.0:47414 0.0.0.0:*

udp 0 0 192.168.122.1:53 0.0.0.0:*

udp 0 0 0.0.0.0:67 0.0.0.0:*

4 展现全体处于监听的tcp端口    -tnl

[[email protected]
~]# netstat -tnl

Active Internet connections (only servers)

Proto Recv-Q Send-Q Local Address Foreign Address State

tcp 0 0 0.0.0.0:111 0.0.0.0:* LISTEN

tcp 0 0 192.168.122.1:53 0.0.0.0:* LISTEN

tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN

tcp 0 0 127.0.0.1:631 0.0.0.0:* LISTEN

tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN

tcp6 0 0 :::111 :::* LISTEN

tcp6 0 0 :::22 :::* LISTEN

tcp6 0 0 ::1:631 :::* LISTEN

tcp6 0 0 ::1:25 :::* LISTEN

5 展现全体处于监听状态的udp端口 -unl

[[email protected]
~]# netstat -unl

Active Internet connections (only servers)

Proto Recv-Q Send-Q Local Address Foreign Address State

udp 0 0 0.0.0.0:5353 0.0.0.0:*

udp 0 0 0.0.0.0:47414 0.0.0.0:*

udp 0 0 0.0.0.0:20815 0.0.0.0:*

udp 0 0 192.168.122.1:53 0.0.0.0:*

udp 0 0 0.0.0.0:67 0.0.0.0:*

udp 0 0 0.0.0.0:68 0.0.0.0:*

udp 0 0 0.0.0.0:68 0.0.0.0:*

udp 0 0 0.0.0.0:9804 0.0.0.0:*

udp6 0 0 :::12799 :::*

udp6 0 0 :::37953 :::*

6 彰显路由表 –rn

[[email protected]
~]# netstat -nr

Kernel IP routing table

Destination Gateway Genmask Flags MSS Window irtt Iface

0.0.0.0 192.168.29.1 0.0.0.0 UG 0 0 0 ens33

192.168.29.0 0.0.0.0 255.255.255.0 U 0 0 0 ens33

192.168.122.0 0.0.0.0 255.255.255.0 U 0 0 0 virbr0

[[email protected]
~]# route -n

Kernel IP routing table

Destination Gateway Genmask Flags Metric Ref Use Iface

0.0.0.0 192.168.29.1 0.0.0.0 UG 100 0 0 ens33

192.168.29.0 0.0.0.0 255.255.255.0 U 100 0 0 ens33

192.168.122.0 0.0.0.0 255.255.255.0 U 0 0 0 virbr0

7 展现每种体协会议的总结音讯

(1)展现全数端口的总计音信 netstat -s

[[email protected]
~]# netstat -s

Ip:

3808 total packets received

0 forwarded

0 incoming packets discarded

2444 incoming packets delivered

2254 requests sent out

32 outgoing packets dropped

Icmp:

676 ICMP messages received

0 input ICMP message failed.

ICMP input histogram:

destination unreachable: 148

echo replies: 528

717 ICMP messages sent

0 ICMP messages failed

ICMP output histogram:

destination unreachable: 148

echo request: 569

[……]

(2)显示 TCP 端口的总括消息 netstat -st

[[email protected]
~]# netstat -st

IcmpMsg:

InType0: 528

InType3: 148

OutType3: 148

netstat命令详解状态,netstat命令详解。OutType8: 569

Tcp:

0 active connections openings

2 passive connection openings

0 failed connection attempts

0 connection resets received

2 connections established

1637 segments received

1418 segments send out

0 segments retransmited

0 bad segments received.

0 resets sent

(3)展现 UDP 端口的总括消息 netstat -su

[[email protected]
~]# netstat -su

IcmpMsg:

InType0: 528

InType3: 148

OutType3: 148

OutType8: 569

Udp:

0 packets received

140 packets to unknown port received.

0 packet receive errors

169 packets sent

0 receive buffer errors

0 send buffer errors

UdpLite:

IpExt:

InMcastPkts: 27

OutMcastPkts: 33

InBcastPkts: 766

InOctets: 410294

OutOctets: 432666

InMcastOctets: 4963

OutMcastOctets: 5444

InBcastOctets: 179503

InNoECTPkts: 3848

8 突显 PID 和进程名称 netstat -p

[[email protected]
~]# netstat -p

Active Internet connections (w/o servers)

Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name

tcp 0 52 centos7.3.local:ssh gateway:51029 ESTABLISHED 1552/sshd:
[email protected]

tcp 0 0 centos7.3.local:ssh gateway:51180 ESTABLISHED 1854/sshd:
[email protected]

Active UNIX domain sockets (w/o servers)

Proto RefCnt Flags Type State I-Node PID/Program name Path

unix 2 [ ] DGRAM 8520 1/systemd /run/systemd/notify

unix 2 [ ] DGRAM 8522 1/systemd /run/systemd/cgroups-agent

unix 5 [ ] DGRAM 8542 1/systemd /run/systemd/journal/socket

unix 28 [ ] DGRAM 8544 1/systemd /dev/log

unix 2 [ ] DGRAM 11419 1/systemd /run/systemd/shutdownd

unix 3 [ ] STREAM CONNECTED 23993 1276/ibus-x11

 

netstat
命令用于体现各样互连网有关新闻,如互联网连接,路由表,接口状态 (Interface
Statistics),masquerade 连接,多播…

1 常用选项:

1 常用选项:

1 常用选项:

    -a :(all)显示全部选项,默许不彰显LISTEN相关

    -a :(all)彰显全数选项,默许不呈现LISTEN相关

    -a :(all)展现全部选项,暗许不展现LISTEN相关

    -t :(tcp)仅呈现tcp相关选项

    -t :(tcp)仅浮现tcp相关选项

    -t :(tcp)仅体现tcp相关选项

    -u :(udp)仅展现udp相关选项

    -u :(udp)仅展现udp相关选项

    -u :(udp)仅呈现udp相关选项

    -n :以数显IP和端口,能显得数字的全套转化成数字。

    -n :以数显IP和端口,能显得数字的全部转化成数字。

    -n :以数显IP和端口,能显得数字的整整转化成数字。

    -l :仅列出有在 Listen (监听) 的服務状态

    -l :仅列出有在 Listen (监听) 的服務状态

    -l :仅列出有在 Listen (监听) 的服務状态

    -p: 呈现建立相关链接的次序名

    -p: 展现建立有关链接的顺序名

    -p: 展现建立有关链接的次序名

    -r :呈现路由新闻,路由表

    -r :展现路由音信,路由表

    -r :显示路由音信,路由表

    -e :展现扩充音信,例如uid等

    -e :显示增添音信,例如uid等

    -e :彰显扩展音讯,例如uid等

    -s :按梯次协议实行总括

    -s :按顺序协议进行总括

    -s :按顺序协议进行总计

    -c :每隔3个永恒时间,执行该netstat命令。

    -c :每隔二个原则性时间,执行该netstat命令。

    -c :每隔三个稳住时间,执行该netstat命令。

    -w:raw socket相关

    -w:raw socket相关

    -w:raw socket相关

2 -tan 展现全部tcp端口

2 -tan 显示全体tcp端口

2 -tan 展现全部tcp端口

[root@centos7 ~]# netstat
-ant

[root@centos7 ~]# netstat
-ant

[root@CentOS7
~]# netstat -ant

Active Internet connections (servers and established)

Active Internet connections (servers and established)

Active Internet connections (servers and established)

Proto Recv-Q Send-Q Local Address Foreign Address State

Proto Recv-Q Send-Q Local Address Foreign Address State

Proto Recv-Q Send-Q Local Address Foreign Address State

tcp 0 0 0.0.0.0:111 0.0.0.0:* LISTEN

tcp 0 0 0.0.0.0:111 0.0.0.0:* LISTEN

tcp 0 0 0.0.0.0:111 0.0.0.0:* LISTEN

tcp 0 0 192.168.122.1:53 0.0.0.0:* LISTEN

tcp 0 0 192.168.122.1:53 0.0.0.0:* LISTEN

tcp 0 0 192.168.122.1:53 0.0.0.0:* LISTEN

tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN

tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN

tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN

tcp 0 0 127.0.0.1:631 0.0.0.0:* LISTEN

tcp 0 0 127.0.0.1:631 0.0.0.0:* LISTEN

tcp 0 0 127.0.0.1:631 0.0.0.0:* LISTEN

tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN

tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN

tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN

tcp 0 52 192.168.29.3:22 192.168.29.1:51029 ESTABLISHED

tcp 0 52 192.168.29.3:22 192.168.29.1:51029 ESTABLISHED

tcp 0 52 192.168.29.3:22 192.168.29.1:51029 ESTABLISHED

tcp 0 0 192.168.29.3:22 192.168.29.1:51180 ESTABLISHED

tcp 0 0 192.168.29.3:22 192.168.29.1:51180 ESTABLISHED

tcp 0 0 192.168.29.3:22 192.168.29.1:51180 ESTABLISHED

tcp6 0 0 :::111 :::* LISTEN

tcp6 0 0 :::111 :::* LISTEN

tcp6 0 0 :::111 :::* LISTEN

tcp6 0 0 :::22 :::* LISTEN

tcp6 0 0 :::22 :::* LISTEN

tcp6 0 0 :::22 :::* LISTEN

tcp6 0 0 ::1:631 :::* LISTEN

tcp6 0 0 ::1:631 :::* LISTEN

tcp6 0 0 ::1:631 :::* LISTEN

tcp6 0 0 ::1:25 :::*

tcp6 0 0 ::1:25 :::*

tcp6 0 0 ::1:25 :::*

3 突显全部udp端口 -uan

3 显示全数udp端口 -uan

3 呈现全数udp端口 -uan

[root@centos7 ~]# netstat
-anu

[root@centos7 ~]# netstat
-anu

[root@centos7 ~]# netstat
-anu

Active Internet connections (servers and established)

Active Internet connections (servers and established)

Active Internet connections (servers and established)

Proto Recv-Q Send-Q Local Address Foreign Address State

Proto Recv-Q Send-Q Local Address Foreign Address State

Proto Recv-Q Send-Q Local Address Foreign Address State

udp 0 0 0.0.0.0:5353 0.0.0.0:*

udp 0 0 0.0.0.0:5353 0.0.0.0:*

udp 0 0 0.0.0.0:5353 0.0.0.0:*

udp 0 0 0.0.0.0:47414 0.0.0.0:*

udp 0 0 0.0.0.0:47414 0.0.0.0:*

udp 0 0 0.0.0.0:47414 0.0.0.0:*

udp 0 0 192.168.122.1:53 0.0.0.0:*

udp 0 0 192.168.122.1:53 0.0.0.0:*

udp 0 0 192.168.122.1:53 0.0.0.0:*

udp 0 0 0.0.0.0:67 0.0.0.0:*

udp 0 0 0.0.0.0:67 0.0.0.0:*

udp 0 0 0.0.0.0:67 0.0.0.0:*

4 彰显全数处于监听的tcp端口    -tnl

4 展现全部处于监听的tcp端口    -tnl

4 呈现全体处于监听的tcp端口    -tnl

[root@centos7 ~]# netstat
-tnl

[root@centos7 ~]# netstat
-tnl

[root@centos7 ~]# netstat
-tnl

Active Internet connections (only servers)

Active Internet connections (only servers)

Active Internet connections (only servers)

Proto Recv-Q Send-Q Local Address Foreign Address State

Proto Recv-Q Send-Q Local Address Foreign Address State

Proto Recv-Q Send-Q Local Address Foreign Address State

tcp 0 0 0.0.0.0:111 0.0.0.0:* LISTEN

tcp 0 0 0.0.0.0:111 0.0.0.0:* LISTEN

tcp 0 0 0.0.0.0:111 0.0.0.0:* LISTEN

tcp 0 0 192.168.122.1:53 0.0.0.0:* LISTEN

tcp 0 0 192.168.122.1:53 0.0.0.0:* LISTEN

tcp 0 0 192.168.122.1:53 0.0.0.0:* LISTEN

tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN

tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN

tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN

tcp 0 0 127.0.0.1:631 0.0.0.0:* LISTEN

tcp 0 0 127.0.0.1:631 0.0.0.0:* LISTEN

tcp 0 0 127.0.0.1:631 0.0.0.0:* LISTEN

tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN

tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN

tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN

tcp6 0 0 :::111 :::* LISTEN

tcp6 0 0 :::111 :::* LISTEN

tcp6 0 0 :::111 :::* LISTEN

tcp6 0 0 :::22 :::* LISTEN

tcp6 0 0 :::22 :::* LISTEN

tcp6 0 0 :::22 :::* LISTEN

tcp6 0 0 ::1:631 :::* LISTEN

tcp6 0 0 ::1:631 :::* LISTEN

tcp6 0 0 ::1:631 :::* LISTEN

tcp6 0 0 ::1:25 :::* LISTEN

tcp6 0 0 ::1:25 :::* LISTEN

tcp6 0 0 ::1:25 :::* LISTEN

5 呈现全数处于监听状态的udp端口 -unl

5 突显全部处于监听状态的udp端口 -unl

5 显示全数处于监听状态的udp端口 -unl

[root@centos7 ~]# netstat
-unl

[root@centos7 ~]# netstat
-unl

[root@centos7 ~]# netstat
-unl

Active Internet connections (only servers)

Active Internet connections (only servers)

Active Internet connections (only servers)

Proto Recv-Q Send-Q Local Address Foreign Address State

Proto Recv-Q Send-Q Local Address Foreign Address State

Proto Recv-Q Send-Q Local Address Foreign Address State

udp 0 0 0.0.0.0:5353 0.0.0.0:*

udp 0 0 0.0.0.0:5353 0.0.0.0:*

udp 0 0 0.0.0.0:5353 0.0.0.0:*

udp 0 0 0.0.0.0:47414 0.0.0.0:*

udp 0 0 0.0.0.0:47414 0.0.0.0:*

udp 0 0 0.0.0.0:47414 0.0.0.0:*

udp 0 0 0.0.0.0:20815 0.0.0.0:*

udp 0 0 0.0.0.0:20815 0.0.0.0:*

udp 0 0 0.0.0.0:20815 0.0.0.0:*

udp 0 0 192.168.122.1:53 0.0.0.0:*

udp 0 0 192.168.122.1:53 0.0.0.0:*

udp 0 0 192.168.122.1:53 0.0.0.0:*

udp 0 0 0.0.0.0:67 0.0.0.0:*

udp 0 0 0.0.0.0:67 0.0.0.0:*

udp 0 0 0.0.0.0:67 0.0.0.0:*

udp 0 0 0.0.0.0:68 0.0.0.0:*

udp 0 0 0.0.0.0:68 0.0.0.0:*

udp 0 0 0.0.0.0:68 0.0.0.0:*

udp 0 0 0.0.0.0:68 0.0.0.0:*

udp 0 0 0.0.0.0:68 0.0.0.0:*

udp 0 0 0.0.0.0:68 0.0.0.0:*

udp 0 0 0.0.0.0:9804 0.0.0.0:*

udp 0 0 0.0.0.0:9804 0.0.0.0:*

udp 0 0 0.0.0.0:9804 0.0.0.0:*

udp6 0 0 :::12799 :::*

udp6 0 0 :::12799 :::*

udp6 0 0 :::12799 :::*

udp6 0 0 :::37953 :::*

udp6 0 0 :::37953 :::*

udp6 0 0 :::37953 :::*

6 显示路由表 –rn

6 突显路由表 –rn

6 呈现路由表 –rn

[root@centos7 ~]# netstat
-nr

[root@centos7 ~]# netstat
-nr

[root@centos7 ~]# netstat
-nr

Kernel IP routing table

Kernel IP routing table

Kernel IP routing table

Destination Gateway Genmask Flags MSS Window irtt Iface

Destination Gateway Genmask Flags MSS Window irtt Iface

Destination Gateway Genmask Flags MSS Window irtt Iface

0.0.0.0 192.168.29.1 0.0.0.0 UG 0 0 0 ens33

0.0.0.0 192.168.29.1 0.0.0.0 UG 0 0 0 ens33

0.0.0.0 192.168.29.1 0.0.0.0 UG 0 0 0 ens33

192.168.29.0 0.0.0.0 255.255.255.0 U 0 0 0 ens33

192.168.29.0 0.0.0.0 255.255.255.0 U 0 0 0 ens33

192.168.29.0 0.0.0.0 255.255.255.0 U 0 0 0 ens33

192.168.122.0 0.0.0.0 255.255.255.0 U 0 0 0 virbr0

192.168.122.0 0.0.0.0 255.255.255.0 U 0 0 0 virbr0

192.168.122.0 0.0.0.0 255.255.255.0 U 0 0 0 virbr0

[root@centos7 ~]# route -n

[root@centos7 ~]# route -n

[root@centos7 ~]# route -n

Kernel IP routing table

Kernel IP routing table

Kernel IP routing table

Destination Gateway Genmask Flags Metric Ref Use Iface

Destination Gateway Genmask Flags Metric Ref Use Iface

Destination Gateway Genmask Flags Metric Ref Use Iface

0.0.0.0 192.168.29.1 0.0.0.0 UG 100 0 0 ens33

0.0.0.0 192.168.29.1 0.0.0.0 UG 100 0 0 ens33

0.0.0.0 192.168.29.1 0.0.0.0 UG 100 0 0 ens33

192.168.29.0 0.0.0.0 255.255.255.0 U 100 0 0 ens33

192.168.29.0 0.0.0.0 255.255.255.0 U 100 0 0 ens33

192.168.29.0 0.0.0.0 255.255.255.0 U 100 0 0 ens33

192.168.122.0 0.0.0.0 255.255.255.0 U 0 0 0 virbr0

192.168.122.0 0.0.0.0 255.255.255.0 U 0 0 0 virbr0

192.168.122.0 0.0.0.0 255.255.255.0 U 0 0 0 virbr0

7 展现每种体协会议的总结新闻

7 展现每种体协会议的总结消息

7 展现各种体协会议的总计音信

(1)展现全数端口的总括新闻 netstat -s

(1)呈现全体端口的总括音信 netstat -s

(1)突显全体端口的总括音信 netstat -s

[root@centos7 ~]# netstat
-s

[root@centos7 ~]# netstat
-s

[root@centos7 ~]# netstat
-s

Ip:

Ip:

Ip:

3808 total packets received

3808 total packets received

3808 total packets received

0 forwarded

0 forwarded

0 forwarded

0 incoming packets discarded

0 incoming packets discarded

0 incoming packets discarded

2444 incoming packets delivered

2444 incoming packets delivered

2444 incoming packets delivered

2254 requests sent out

2254 requests sent out

2254 requests sent out

32 outgoing packets dropped

32 outgoing packets dropped

32 outgoing packets dropped

Icmp:

Icmp:

Icmp:

676 ICMP messages received

676 ICMP messages received

676 ICMP messages received

0 input ICMP message failed.

0 input ICMP message failed.

0 input ICMP message failed.

ICMP input histogram:

ICMP input histogram:

ICMP input histogram:

destination unreachable: 148

destination unreachable: 148

destination unreachable: 148

echo replies: 528

echo replies: 528

echo replies: 528

717 ICMP messages sent

717 ICMP messages sent

717 ICMP messages sent

0 ICMP messages failed

0 ICMP messages failed

0 ICMP messages failed

ICMP output histogram:

ICMP output histogram:

ICMP output histogram:

destination unreachable: 148

destination unreachable: 148

destination unreachable: 148

echo request: 569

echo request: 569

echo request: 569

[……]

[……]

[……]

(2)显示 TCP 端口的总结新闻 netstat -st

(2)呈现 TCP 端口的总括新闻 netstat -st

(2)展现 TCP 端口的总结消息 netstat -st

[root@centos7 ~]# netstat
-st

[root@centos7 ~]# netstat
-st

[root@centos7 ~]# netstat
-st

IcmpMsg:

IcmpMsg:

IcmpMsg:

InType0: 528

InType0: 528

InType0: 528

InType3: 148

InType3: 148

InType3: 148

OutType3: 148

OutType3: 148

OutType3: 148

OutType8: 569

OutType8: 569

OutType8: 569

Tcp:

Tcp:

Tcp:

0 active connections openings

0 active connections openings

0 active connections openings

2 passive connection openings

2 passive connection openings

2 passive connection openings

0 failed connection attempts

0 failed connection attempts

0 failed connection attempts

0 connection resets received

0 connection resets received

0 connection resets received

2 connections established

2 connections established

2 connections established

1637 segments received

1637 segments received

1637 segments received

1418 segments send out

1418 segments send out

1418 segments send out

0 segments retransmited

0 segments retransmited

0 segments retransmited

0 bad segments received.

0 bad segments received.

0 bad segments received.

0 resets sent

0 resets sent

0 resets sent

(3)呈现 UDP 端口的总计音信 netstat -su

(3)显示 UDP 端口的总结消息 netstat -su

(3)展现 UDP 端口的计算消息 netstat -su

[root@centos7 ~]# netstat
-su

[root@centos7 ~]# netstat
-su

[root@centos7 ~]# netstat
-su

IcmpMsg:

IcmpMsg:

IcmpMsg:

InType0: 528

InType0: 528

InType0: 528

InType3: 148

InType3: 148

InType3: 148

OutType3: 148

OutType3: 148

OutType3: 148

OutType8: 569

OutType8: 569

OutType8: 569

Udp:

Udp:

Udp:

0 packets received

0 packets received

0 packets received

140 packets to unknown port received.

140 packets to unknown port received.

140 packets to unknown port received.

0 packet receive errors

0 packet receive errors

0 packet receive errors

169 packets sent

169 packets sent

169 packets sent

0 receive buffer errors

0 receive buffer errors

0 receive buffer errors

0 send buffer errors

0 send buffer errors

0 send buffer errors

UdpLite:

UdpLite:

UdpLite:

IpExt:

IpExt:

IpExt:

InMcastPkts: 27

InMcastPkts: 27

InMcastPkts: 27

OutMcastPkts: 33

OutMcastPkts: 33

OutMcastPkts: 33

InBcastPkts: 766

InBcastPkts: 766

InBcastPkts: 766

InOctets: 410294

InOctets: 410294

InOctets: 410294

OutOctets: 432666

OutOctets: 432666

OutOctets: 432666

InMcastOctets: 4963

InMcastOctets: 4963

InMcastOctets: 4963

OutMcastOctets: 5444

OutMcastOctets: 5444

OutMcastOctets: 5444

InBcastOctets: 179503

InBcastOctets: 179503

InBcastOctets: 179503

InNoECTPkts: 3848

InNoECTPkts: 3848

InNoECTPkts: 3848

8 显示 PID 和进程名称 netstat -p

8 突显 PID 和经过名称 netstat -p

8 彰显 PID 和进程名称 netstat -p

[root@centos7 ~]# netstat
-p

[root@centos7 ~]# netstat
-p

[root@centos7 ~]# netstat
-p

Active Internet connections (w/o servers)

Active Internet connections (w/o servers)

Active Internet connections (w/o servers)

Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name

Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name

Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name

tcp 0 52 centos7.3.local:ssh gateway:51029 ESTABLISHED 1552/sshd:
root@pts

tcp 0 52 centos7.3.local:ssh gateway:51029 ESTABLISHED 1552/sshd:
root@pts

tcp 0 52 centos7.3.local:ssh gateway:51029 ESTABLISHED 1552/sshd:
root@pts

tcp 0 0 centos7.3.local:ssh gateway:51180 ESTABLISHED 1854/sshd:
root@pts

tcp 0 0 centos7.3.local:ssh gateway:51180 ESTABLISHED 1854/sshd:
root@pts

tcp 0 0 centos7.3.local:ssh gateway:51180 ESTABLISHED 1854/sshd:
root@pts

Active UNIX domain sockets (w/o servers)

Active UNIX domain sockets (w/o servers)

Active UNIX domain sockets (w/o servers)

Proto RefCnt Flags Type State I-Node PID/Program name Path

Proto RefCnt Flags Type State I-Node PID/Program name Path

Proto RefCnt Flags Type State I-Node PID/Program name Path

unix 2 [ ] DGRAM 8520 1/systemd /run/systemd/notify

unix 2 [ ] DGRAM 8520 1/systemd /run/systemd/notify

unix 2 [ ] DGRAM 8520 1/systemd /run/systemd/notify

unix 2 [ ] DGRAM 8522 1/systemd /run/systemd/cgroups-agent

unix 2 [ ] DGRAM 8522 1/systemd /run/systemd/cgroups-agent

unix 2 [ ] DGRAM 8522 1/systemd /run/systemd/cgroups-agent

unix 5 [ ] DGRAM 8542 1/systemd /run/systemd/journal/socket

unix 5 [ ] DGRAM 8542 1/systemd /run/systemd/journal/socket

unix 5 [ ] DGRAM 8542 1/systemd /run/systemd/journal/socket

unix 28 [ ] DGRAM 8544 1/systemd /dev/log

unix 28 [ ] DGRAM 8544 1/systemd /dev/log

unix 28 [ ] DGRAM 8544 1/systemd /dev/log

unix 2 [ ] DGRAM 11419 1/systemd /run/systemd/shutdownd

unix 2 [ ] DGRAM 11419 1/systemd /run/systemd/shutdownd

unix 2 [ ] DGRAM 11419 1/systemd /run/systemd/shutdownd

unix 3 [ ] STREAM CONNECTED 23993 1276/ibus-x11

unix 3 [ ] STREAM CONNECTED 23993 1276/ibus-x11

unix 3 [美高梅手机版4858 , ] STREAM CONNECTED 23993 1276/ibus-x11

 

 

正文永久更新链接地址:http://www.linuxidc.com/Linux/2017-06/144864.htm

美高梅手机版4858 1

发表评论

电子邮件地址不会被公开。 必填项已用*标注

网站地图xml地图
Copyright @ 2010-2019 美高梅手机版4858 版权所有