5.7 Windows common Network commands

Source: Internet
Author: User

5.7 Windows common network commands ping netstat winipcfg/ipconfig tracert route 5.7.1 Ping command• Function – It is a command to check whether the network is unobstructed or the speed of the network connection. – It is an ICMP-based ICMP response request message and a response response message to complete this function. • Command Format ping [-t] [-a] [-N Count] [-l-length] [-f] [-i TTL] [-v TOS] [-R Count] [-s count] [-j-host list] | [-K host-list] [-w timeout] Destination-list–-t: Indicates that the packet will be sent uninterrupted to the destination IP until we force it to stop. –-l: Defines the size of the sending packet, which defaults to 32 bytes, which we can use to define the maximum to 65500 bytes. –-n: Defines the number of times a packet is sent to the destination IP, which defaults to 3. Example: ping-n 4 www.sjtu.edu.cn 5.7.2 netstat• Features – Displays active TCP connections, computer-listening ports, Ethernet statistics, IP routing tables, IPv4 and IPV6 statistics, etc. • command format netstat [-a] [-e] [-n] [-O] [-P Protocol] [-R] [-S] [Interval ]– If no parameters are present, Netstat displays the active TCP connection. –-a: Displays all active TCP connections and the TCP and UDP ports that the computer listens on. –-E: Displays Ethernet statistics, such as the number of bytes sent and received, and the number of packets. This parameter can be used in conjunction with-S. –-n: Displays the active TCP connection, however, addresses and port numbers are only represented numerically, but no attempt is made to determine the name. –-o: Displays the active TCP connection and includes the process ID (PID) for each connection. You can find a PID-based application on the Processes tab in Windows Task Manager. This parameter can be used in combination with-a,-N, and-P. –-p Protocol: Displays the connection for the protocol specified by the Protocol. In this case, the protocol can be TCP, UDP, Tcpv6, or Udpv6. If this parameter is used with-s to display statistics by protocol, the Protocol can be TCP, UDP, ICMP, IP, Tcpv6, Udpv6, ICMPv6, or IPv6. –-r: Displays the contents of the IP routing table. This parameter is equivalent to the route print command. –interval: Displays the selected information again every Interval seconds. Press CTRL + C to stop displaying the statistics again. If this argument is omitted, Netstat will print only one time for the selected information. 5.7.3 Winipcfg/ipconfig• Feature – Displays information such as the IP address of the network adapter in your computer. – Windows 98 uses the winipcfg command under Windows XP to use the ipconfig command format ipconfig [/all/renew [adapter]/release [adapter]]– If there are no parameters, then The Ipconfig utility will provide the user with all the current TCP/IP configuration values, including the address and subnet mask. –/all: Produces a full display, including information about all network adapters. –/renew [Adapter]: Update DHCP configuration parameters. This option is available only on systems that are running the DHCP client service. To specify an adapter name, type the name of the adapter that is displayed with the ipconfig command without parameters. –/release [Adapter]: publishes the current DHCP configuration. This option disables TCP/IP on the local system and is available only on DHCP clients. To specify an adapter name, type the name of the adapter that is displayed with the ipconfig command without parameters. 5.7.4 tracert• Function – Query the route (that is, the list of routers) that arrives at a machine from this machine. – It is ICMP-based over the ICMP datagram to get a list of routes through the router • The source host sends an IP message to the destination host, and hop is 1, when it arrives at the first router, hop minus 1, 0, then the router sends back an ICMP datagram super-times text, The source host takes out the IP address of the router as the first routed port address of the route • Then the source host sends a second IP message to the destination host, and the hop is set to 2, then the third, fourth IP datagram, ... Until the destination host is reached. • command Format tracert [-d] [-h maximum_hops] [-j computer-list] [w timeout] target_name–-d: Specifies that the address is not resolved to a computer name. –-h Maximum_ Hops: Specifies the maximum number of hops for the search target. –-j host-list: Loose source routing along with the host list (IPV4 only), specifies that the sparse source route list order along the host-list is forwarded. The host-list is a space-separated number of router IP addresses, with a maximum of 9. –-w Timeout: The time-out (in milliseconds) to wait for each reply. –-R: Tracks the round trip path (only for IPv6). –-S:SRCADDR the source address to use (only for IPv6). –-4: Force the use of IPV4. –-6: Force the use of IPV6. –target_name the name of the target computer. 5.7.5 Route• Function – Used to display or modify the Routing table • Command format route [-f] [-p] [command [Destination] [Mask Netmask] [Gateway] [metric metric]] [if interface]]–-f clear The routing table for all gateway portals. –-p is used with the add command to make the route permanent. –command Specifies the command you want to run (add/change/delete/print). –DESTINATION Specifies the network destination for this route. –mask Netmask Specifies the network mask associated with the network target (also known as the subnet mask). –GATEWAY Specifies the address set and subnet mask defined by the network destination to reach the forward or next hop IP address. The –metric metric specifies an integer cost value for the route (from 1 to 9999) that can be used when the routing table (which matches the destination address of the forwarded packet) is selected in multiple routes. –if Interface Specifies the interface index for interfaces that can access the target. To obtain a list of interfaces and their corresponding interface indexes, use the display function of the route print command. You can use decimal or hexadecimal values for interface indexing. Route Example –route print– displays the entire contents of the IP routing table. –route Add 0.0.0.0 mask 0.0.0.0 192.168.12.1– Adds a default route with 192.168.12.1 default gateway address. –route Add 10.41.0.0 Mask 255.255.0.0 10.27.0.1– adds a route to the 255.255.0.0 destination with a 10.27.0.1 subnet mask and 10.41.0.0 next-hop address. –route Delete 10.41.0.0 Mask 255.255.0.0– The route to the 10.41.0.0 destination with the 255.255.0.0 subnet mask. –route Change 10.41.0.0 mask 255.255.0.0 10.27.0.25– changes the next hop address with 10.41.0.0 Target and 255.255.0.0 subnet mask from 10.27.0.1 to 10.27.0.25 : The above information comes from some PPT courseware in the course of network planning design and management maintenance of Jiaotong University.

5.7 Windows common Network commands

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.