RTシリーズとWindowsに関するFAQ
TCP/IPネットワークの接続状況の確認方法
| 新規作成日 | 2000/Nov/16 |
| 最終変更日 | 2022/Dec/28 |
| 文書サイズ | 10KB |
TCP/IPネットワークの接続状況の確認はどうしたら良いですか?(netstat.exe)
[ netstatコマンド ]
netstatコマンドにより、WindowsのTCP/IPネットワークの接続状況を 表示することができます。
netstatコマンドを実行するには、MS-DOSプロンプト(command.com)が必要です。 例えば、「netstat -rn」と実行することにより、Windowsの保持している 経路(パケットの送信先のリスト)をIPアドレスで表示することができます。
「netstat -h」と実行することにより、ヘルプ文を表示します。
「netstat -rn」と実行することにより、「route print」と同等のWindowsの保持している経路
(パケットの送信先のリスト)を表示することができます。
「netstat -rn」の代りに「netstat -r」と実行すると、 IPアドレスをDNSホスト名に変換して表示しますが、 DNS名の解決のためにDNSサーバへ問い合せを行ないます。 また、DNS名の解決に失敗するような場合では、表示が非常に遅くなる可能性 があります。
「netstat -an」と実行することにより、接続(connections)と待ち受けポート (istening ports)が表示されます。
「netstat -an」の代りに「netstat -a」と実行すると、 IPアドレスをDNSホスト名に、ポート番号をニーモニックに変換して表示しますが、 DNS名の解決のためにDNSサーバへ問い合せを行ないます。 また、DNS名の解決に失敗するような場合では、表示が非常に遅くなる可能性 があります。
Ethernetレベルの送受信データ量の集計表示
IP/TCP/UDP/ICMPレベルの送受信データ量の集計表示
C:\> netstat -h
Displays protocol statistics and current TCP/IP network connections.
NETSTAT [-a] [-e] [-n] [-s] [-p proto] [-r] [interval]
-a Displays all connections and listening ports.
-e Displays Ethernet statistics. This may be combined with the -s
option.
-n Displays addresses and port numbers in numerical form.
-p proto Shows connections for the protocol specified by proto; proto
may be TCP or UDP. If used with the -s option to display
per-protocol statistics, proto may be TCP, UDP, or IP.
-r Displays the routing table.
-s Displays per-protocol statistics. By default, statistics are
shown for TCP, UDP and IP; the -p option may be used to specify
a subset of the default.
interval Redisplays selected statistics, pausing interval seconds
between each display. Press CTRL+C to stop redisplaying
statistics. If omitted, netstat will print the current
configuration information once.
|
C:\>netstat /?
Displays protocol statistics and current TCP/IP network connections.
NETSTAT [-a] [-e] [-n] [-s] [-p proto] [-r] [interval]
-a Displays all connections and listening ports.
-e Displays Ethernet statistics. This may be combined with the -s
option.
-n Displays addresses and port numbers in numerical form.
-p proto Shows connections for the protocol specified by proto; proto
may be TCP or UDP. If used with the -s option to display
per-protocol statistics, proto may be TCP, UDP, or IP.
-r Displays the routing table.
-s Displays per-protocol statistics. By default, statistics are
shown for TCP, UDP and IP; the -p option may be used to specify
a subset of the default.
interval Redisplays selected statistics, pausing interval seconds
between each display. Press CTRL+C to stop redisplaying
statistics. If omitted, netstat will print the current
configuration information once.
|
C:\> netstat -rn
Route Table
Active Routes:
Network Address Netmask Gateway Address Interface Metric
0.0.0.0 0.0.0.0 192.168.0.1 192.168.0.2 1
127.0.0.0 255.0.0.0 127.0.0.1 127.0.0.1 1
192.168.0.0 255.255.255.0 192.168.0.2 192.168.0.2 1
192.168.0.2 255.255.255.255 127.0.0.1 127.0.0.1 1
192.168.0.255 255.255.255.255 192.168.0.2 192.168.0.2 1
224.0.0.0 224.0.0.0 192.168.0.2 192.168.0.2 1
255.255.255.255 255.255.255.255 192.168.0.2 0.0.0.0 1
Active Connections
Proto Local Address Foreign Address State
|
C:\>netstat -rn
Route Table
===========================================================================
Interface List
0x1 ........................... MS TCP Loopback interface
0x1000004 ...08 00 46 0d 3e 96 ...... Intel 8255x-based Integrated Fast Ethernet
===========================================================================
===========================================================================
Active Routes:
Network Destination Netmask Gateway Interface Metric
127.0.0.0 255.0.0.0 127.0.0.1 127.0.0.1 1
255.255.255.255 255.255.255.255 255.255.255.255 1000004 1
===========================================================================
Persistent Routes:
None
|
C:\>netstat -rn
Route Table
===========================================================================
Interface List
0x1 ........................... MS TCP Loopback interface
0x1000004 ...08 00 46 0d 3e 96 ...... Intel 8255x-based Integrated Fast Ethernet
===========================================================================
===========================================================================
Active Routes:
Network Destination Netmask Gateway Interface Metric
0.0.0.0 0.0.0.0 192.168.0.1 192.168.0.2 1
127.0.0.0 255.0.0.0 127.0.0.1 127.0.0.1 1
192.168.0.0 255.255.255.0 192.168.0.2 192.168.0.2 1
192.168.0.2 255.255.255.255 127.0.0.1 127.0.0.1 1
192.168.0.255 255.255.255.255 192.168.0.2 192.168.0.2 1
224.0.0.0 224.0.0.0 192.168.0.2 192.168.0.2 1
255.255.255.255 255.255.255.255 192.168.0.2 192.168.0.2 1
Default Gateway: 192.168.0.1
===========================================================================
Persistent Routes:
None
|
[ 関連FAQ ]
[ FAQ for RT-Series ]
[ FAQ for Windows / RTユーティリティ ]