networktool

Ping -?

Ping the target host with an IPv4 stack.

PING [-n count] [-l size] [-s SourceIp] TargetIp

  -n       - Specifies the number of echo request datagrams to be sent.   -l       - Specifies the size of the data buffer in the echo request datagram.   -s       - Specifies the source adapter as IPv4 address.   SourceIp - Specifies the IPv4 address of the source machine.   TargetIp - Specifies the IPv4 address of the target machine.

NOTES:   1. This command uses the ICMPv4 ECHO_REQUEST datagram to elicit an      ECHO_REPLY from a host.

EXAMPLES:   * To ping the target host with 64 bytes data:     fs0:\> ping -l 64 192.168.0.1

  * To ping the target host by sending 20 echo request datagrams:     fs0:\> ping -n 20 202.120.100.1

  * To ping the target host by specifying the source adapter as IPv4 address:     fs0:\> ping -s 202.120.100.12 202.120.100.1

 

 ifconfig -?

Modifies the default IP address of the UEFI IPv4 Network Stack.

IFCONFIG [-r [Name]] [-l [Name]] IFCONFIG [-s <Name> dhcp | <static <IP> <Mask>  <Gateway>> | <dns <IP>>]

  -r          - Renew configuration of interface and set dhcp policy.   -l          - Lists the configuration.   -s          - Sets the configuration.   Name        - Specifies an adapter name (for example, eth0).   IP          - Specifies the IPv4 address in four integer values:                   - Example: 192.168.0.10   SubnetMask  - Specifies a subnet mask in four integer values:                   - Example: 255.255.255.0   GatewayMask - Specifies a default gateway in four integer values:                   - Example: 192.168.0.1

NOTES:   1. This command modifies the default IP address for the UEFI IP4      network stack.   2. Use '-r' to renew configuration of interface and set dhcp policy.   3. Use '-l' to list the DNS and other address related settings for all      interfaces or the specified interface.   4. Use '-s <Name> static <IP> <SubnetMask> <GatewayMask>' with      static IP4 address configuration for specified interface.   5. Use '-s <Name> dhcp' for DHCP4 to request the IP4 address      configuration dynamically for specified interface.   6. Use '-s <Name> dns <IP>' must under manual policy.

EXAMPLES:   * To list the configuration for the eth0 interface:     fs0:\> ifconfig -l eth0

  * To use DHCP4 to request the IPv4 address configuration dynamically for the     eth0 interface:     fs0:\> ifconfig -s eth0 dhcp

  * To use the static IPv4 address configuration for the eth0 interface:     fs0:\> ifconfig -s eth0 static 192.168.0.5 255.255.255.0 192.168.0.1

  * To configure DNS server address for the eth0 interface:     fs0:\> ifconfig -s eth0 dns 192.168.0.8 192.168.0.9

 

ifconfig -l

-----------------------------------------------------------------

name         : eth0 Media State  : Media disconnected policy       : static mac addr     : 00:1E:67:C0:CF:9A

ipv4 address : 0.0.0.0

subnet mask  : 0.0.0.0

default gateway: 0.0.0.0

  Routes (0 entries):

DNS server   :

-----------------------------------------------------------------

name         : eth1 Media State  : Media present policy       : dhcp mac addr     : 00:1E:67:C0:CF:9B

ipv4 address : 10.239.49.7

subnet mask  : 255.255.255.0

default gateway: 10.239.49.241

  Routes (2 entries):     Entry[0]      Subnet : 10.239.49.0      Netmask: 255.255.255.0      Gateway: 0.0.0.0     Entry[1]      Subnet : 0.0.0.0      Netmask: 0.0.0.0      Gateway: 10.239.49.241

DNS server   :       10.248.2.5

      10.239.27.228

     172.17.6.9

-----------------------------------------------------------------

Shell> ping -l 64 10.239.49.7 Ping 10.239.49.7 64 data bytes. Echo request sequence 1 timeout. Echo request sequence 2 timeout. Echo request sequence 3 timeout. Echo request sequence 4 timeout. Echo request sequence 5 timeout. Echo request sequence 6 timeout. Echo request sequence 7 timeout. Echo request sequence 8 timeout. Echo request sequence 9 timeout. Echo request sequence 10 timeout.

10 packets transmitted, 0 received, 100% packet loss, time 0ms Shell> ping -l 64 10.239.193.111 Ping 10.239.193.111 64 data bytes. 64 bytes from 10.239.193.111 : icmp_seq=1 ttl=0 time=10069ms 64 bytes from 10.239.193.111 : icmp_seq=2 ttl=0 time=5801ms 64 bytes from 10.239.193.111 : icmp_seq=3 ttl=0 time=15013ms 64 bytes from 10.239.193.111 : icmp_seq=4 ttl=0 time=8114ms 64 bytes from 10.239.193.111 : icmp_seq=5 ttl=0 time=6483ms 64 bytes from 10.239.193.111 : icmp_seq=6 ttl=0 time=5933ms 64 bytes from 10.239.193.111 : icmp_seq=7 ttl=0 time=7193ms 64 bytes from 10.239.193.111 : icmp_seq=8 ttl=0 time=55630ms 64 bytes from 10.239.193.111 : icmp_seq=9 ttl=0 time=7413ms 64 bytes from 10.239.193.111 : icmp_seq=10 ttl=0 time=37578ms

10 packets transmitted, 10 received, 0% packet loss, time 159227ms

Rtt(round trip time) min=5801ms max=55630ms avg=15922ms Shell> ping -l 64 127.0.0.1 Ping 127.0.0.1 64 data bytes. Echo request sequence 1 timeout. Echo request sequence 2 timeout. Echo request sequence 3 timeout. Echo request sequence 4 timeout. Echo request sequence 5 timeout. Echo request sequence 6 timeout. Echo request sequence 7 timeout. Echo request sequence 8 timeout. Echo request sequence 9 timeout. Echo request sequence 10 timeout.

10 packets transmitted, 0 received, 100% packet loss, time 0ms

 

Shell> ping -n 20 10.239.193.111 Ping 10.239.193.111 16 data bytes. 16 bytes from 10.239.193.111 : icmp_seq=1 ttl=0 time=11475ms 16 bytes from 10.239.193.111 : icmp_seq=2 ttl=0 time=5693ms 16 bytes from 10.239.193.111 : icmp_seq=3 ttl=0 time=59567ms 16 bytes from 10.239.193.111 : icmp_seq=4 ttl=0 time=6243ms 16 bytes from 10.239.193.111 : icmp_seq=5 ttl=0 time=12569ms 16 bytes from 10.239.193.111 : icmp_seq=6 ttl=0 time=260751ms 16 bytes from 10.239.193.111 : icmp_seq=7 ttl=0 time=11573ms 16 bytes from 10.239.193.111 : icmp_seq=8 ttl=0 time=8678ms 16 bytes from 10.239.193.111 : icmp_seq=9 ttl=0 time=7164ms 16 bytes from 10.239.193.111 : icmp_seq=10 ttl=0 time=10076ms 16 bytes from 10.239.193.111 : icmp_seq=11 ttl=0 time=72610ms 16 bytes from 10.239.193.111 : icmp_seq=12 ttl=0 time=6766ms 16 bytes from 10.239.193.111 : icmp_seq=13 ttl=0 time=5799ms 16 bytes from 10.239.193.111 : icmp_seq=14 ttl=0 time=11815ms 16 bytes from 10.239.193.111 : icmp_seq=15 ttl=0 time=9054ms 16 bytes from 10.239.193.111 : icmp_seq=16 ttl=0 time=45082ms 16 bytes from 10.239.193.111 : icmp_seq=17 ttl=0 time=8900ms 16 bytes from 10.239.193.111 : icmp_seq=18 ttl=0 time=220869ms 16 bytes from 10.239.193.111 : icmp_seq=19 ttl=0 time=8125ms 16 bytes from 10.239.193.111 : icmp_seq=20 ttl=0 time=8878ms

20 packets transmitted, 20 received, 0% packet loss, time 791687ms

Rtt(round trip time) min=5693ms max=260751ms avg=39584ms

 

Shell> ping -g ping: Invalid argument - '-g' Shell> 16 bytes from 10.239.193.111 : icmp_seq=12 ttl=0 time=6bytes from 10.239.193.111 : icmp_seq=19 ttl=016 bytes from 10.239.193.111 : icmp_seq=11 ttl=0 time=72610ms                                       ping -g 10.239.193.111 ping: Invalid argument - '-g' Shell> ping -z 10.239.193.111 ping: Invalid argument - '-z' Shell> ping -n 20 20 10.239.193.111 ping: Too many arguments. Shell> ping -l 10.239.193.111 10.239.193.111 ping: Invalid argument - '10.239.193.111' Shell> ping -l ping: Too few arguments. Shell> ping -n ping: Too few arguments. Shell> ping ping: Too few arguments. Shell> ping -l 256.168.0.1 ping: Invalid argument - '256.168.0.1' Shell> ping -l 192.257.0.1 ping: Invalid argument - '192.257.0.1' Shell> ping -n 192.257.0.1 ping: Invalid argument - '192.257.0.1' Shell> ping -l 192.168.257.1 ping: Invalid argument - '192.168.257.1' Shell> ping -l 192.168.0.257 ping: Invalid argument - '192.168.0.257' Shell> ping -l 10.239.193.111 ping: Invalid argument - '10.239.193.111' Shell> ping -l 20 256.168.0.1 ping: Invalid argument - '256.168.0.1' Shell> ping -l 20 10.239.193.111 Ping 10.239.193.111 20 data bytes. 20 bytes from 10.239.193.111 : icmp_seq=1 ttl=0 time=72931ms 20 bytes from 10.239.193.111 : icmp_seq=2 ttl=0 time=80077ms 20 bytes from 10.239.193.111 : icmp_seq=3 ttl=0 time=262805ms 20 bytes from 10.239.193.111 : icmp_seq=4 ttl=0 time=624063ms 20 bytes from 10.239.193.111 : icmp_seq=5 ttl=0 time=92228ms 20 bytes from 10.239.193.111 : icmp_seq=6 ttl=0 time=156735ms 20 bytes from 10.239.193.111 : icmp_seq=7 ttl=0 time=143051ms 20 bytes from 10.239.193.111 : icmp_seq=8 ttl=0 time=21195ms 20 bytes from 10.239.193.111 : icmp_seq=9 ttl=0 time=62586ms 20 bytes from 10.239.193.111 : icmp_seq=10 ttl=0 time=43810ms

10 packets transmitted, 10 received, 0% packet loss, time 1559481ms

Rtt(round trip time) min=21195ms max=624063ms avg=155948ms Shell> ping -l 20 256.168.0.1 ping: Invalid argument - '256.168.0.1'

 

Shell> ping -ip6 ping: Invalid argument - '-ip6' Shell> ping -s 10.239.193.111 10.239.193.112 ping: No configured interfaces were found. Shell> ping -s 10.239.193.111 10.239.49.7 ping: No configured interfaces were found. Shell> ping -s 10.239.49.7 10.239.193.111 Ping 10.239.193.111 16 data bytes. 16 bytes from 10.239.193.111 : icmp_seq=1 ttl=0 time=99397ms 16 bytes from 10.239.193.111 : icmp_seq=2 ttl=0 time=93967ms 16 bytes from 10.239.193.111 : icmp_seq=3 ttl=0 time=6814ms 16 bytes from 10.239.193.111 : icmp_seq=4 ttl=0 time=55093ms 16 bytes from 10.239.193.111 : icmp_seq=5 ttl=0 time=70490ms 16 bytes from 10.239.193.111 : icmp_seq=6 ttl=0 time=38701ms 16 bytes from 10.239.193.111 : icmp_seq=7 ttl=0 time=7809ms 16 bytes from 10.239.193.111 : icmp_seq=8 ttl=0 time=10106ms 16 bytes from 10.239.193.111 : icmp_seq=9 ttl=0 time=30933ms 16 bytes from 10.239.193.111 : icmp_seq=10 ttl=0 time=13023ms

10 packets transmitted, 10 received, 0% packet loss, time 426333ms

Rtt(round trip time) min=6814ms max=99397ms avg=42633ms Shell> ping -s 10.239.49.7 10.239.193.112 Ping 10.239.193.112 16 data bytes. 16 bytes from 10.239.193.112 : icmp_seq=1 ttl=0 time=31879ms 16 bytes from 10.239.193.112 : icmp_seq=2 ttl=0 time=16886ms 16 bytes from 10.239.193.112 : icmp_seq=3 ttl=0 time=11407ms 16 bytes from 10.239.193.112 : icmp_seq=4 ttl=0 time=20227ms 16 bytes from 10.239.193.112 : icmp_seq=5 ttl=0 time=26316ms 16 bytes from 10.239.193.112 : icmp_seq=6 ttl=0 time=9699ms 16 bytes from 10.239.193.112 : icmp_seq=7 ttl=0 time=12143ms 16 bytes from 10.239.193.112 : icmp_seq=8 ttl=0 time=13077ms 16 bytes from 10.239.193.112 : icmp_seq=9 ttl=0 time=10480ms 16 bytes from 10.239.193.112 : icmp_seq=10 ttl=0 time=5771ms

10 packets transmitted, 10 received, 0% packet loss, time 157885ms

Rtt(round trip time) min=5771ms max=31879ms avg=15788ms

 

posted @ 2016-11-14 14:58  boowii  阅读(554)  评论(0编辑  收藏  举报