All windows networking commands

Windows: Networking Commands

How to list all Network Adapter?

Type ipconfig or ipconfig /all .

windows ipconfig 2020-03-24

What is my IP address?

Technically, you are asking the public IP address of your network’s router.

Go to https://www.google.com/, then type “What’s my IP address?”. It’ll show on top.

How to find the IP address of my machine?

Technically, you want to find the IP address of your machine’s network adapter.

Type ipconfig . The line IPv6 and IPv4 are your IP addresses (for that network adapter). Sample output:

How to find my MAC address?

Technically, you want to find the MAC address of your machine’s network adapter.

Type ipconfig /all . The line “Physical Address” shows the MAC address of that network adapter on your machine.

How to find the IP address of my router?

Type ipconfig , then the “Default Gateway” line contains your router’s IP address.

Or, type route print . The column “Gateway” shows the IP address of router.

How to find my router’s MAC address?

First, find out your router’s IP address. Then, type arp -a .

ipconfig

ipconfig is most useful internet config tool.

Type ipconfig /? to show help.

  • ipconfig /all = show config
  • ipconfig /displaydns = display DNS cache
  • ipconfig /flushdns = Clear DNS Cache
  • ipconfig /release = Release All IP Address Connections
  • ipconfig /renew = Renew All IP Address Connections
  • ipconfig /registerdns = ReRegister the DNS connections
  • ipconfig /showclassid = Display DHCP Class Information
  • ipconfig /setclassid = Change/Modify DHCP Class ID

windows ipconfig all 2020-03-24

used to test the reachability of a host on an Internet Protocol (IP) network and to measure the round-trip time for messages sent from the originating host to a destination computer.

Ping operates by sending Internet Control Message Protocol (ICMP) echo request packets to the target host and waiting for an ICMP response. In the process it measures the time from transmission to reception (round-trip time) and records any packet loss. The results of the test are printed in the form of a statistical summary of the response packets received, including the minimum, maximum, and the mean round-trip times, and sometimes the standard deviation of the mean.

type ping /? to show help.

traceroute

traceroute is a computer network diagnostic tool for displaying the route (path) and measuring transit delays of packets across an Internet Protocol (IP) network.

Traceroute sends a sequence of Internet Control Message Protocol (ICMP) echo request packets addressed to a destination host. Determining the intermediate routers traversed involves adjusting the time-to-live (TTL), aka hop limit, Internet Protocol parameter. Frequently starting with a value like 128 (Windows) or 64 (Linux), routers decrement this and discard a packet when the TTL value has reached zero, returning the ICMP error message ICMP Time Exceeded.

Читайте также:  Windows movie maker или windows live movie maker

Traceroute works by increasing the TTL value of each successive set of packets sent. The first set of packets sent have a hop limit value of 1, expecting that they are not forwarded by the first router. The next set have a hop limit value of 2, so that the second router will send the error reply. This continues until the destination host receives the packets and returns an ICMP Echo Reply message.

Traceroute uses the returned ICMP messages to produce a list of routers that the packets have traversed. The timestamp values returned for each router along the path are the delay (aka latency) values, typically measured in milliseconds for each packet.

netstat

netstat. Displays protocol statistics and current TCP/IP network connections.

netstat (network statistics) displays network connections (both incoming and outgoing), routing tables, and a number of network interface (network interface controller or software-defined network interface) and network protocol statistics.

It is used for finding problems in the network and to determine the amount of traffic on the network as a performance measurement.

route

Route (command) Manipulates network routing tables.

route is a command used to view and manipulate the TCP/IP routing table. Manual manipulation of the routing table is characteristic of static routing.

arp, Address Resolution Protocol, IP to MAC address

Address Resolution Protocol (arp) is a telecommunications protocol used for resolution of network layer addresses into link layer addresses, a critical function in multiple-access networks. ARP was defined by RFC 826 in 1982. It is Internet Standard STD 37. It is also the name of the program for manipulating these addresses in most operating systems.

ARP has been implemented in many combinations of network and overlaying internetwork technologies, such as IPv4, Chaosnet, DECnet and Xerox PARC Universal Packet (PUP) using IEEE 802 standards, FDDI, X.25, Frame Relay and Asynchronous Transfer Mode (ATM), IPv4 over IEEE 802.3 and IEEE 802.11 being the most common cases.

In Internet Protocol Version 6 (IPv6) networks, the functionality of ARP is provided by the Neighbor Discovery Protocol (NDP).

arp = Displays and modifies the IP-to-Physical address translation tables used by address resolution protocol (ARP).

  • hostname = display hostname
  • control netconnections = open connection GUI

If you have a question, put $5 at patreon and message me.

10 Useful Windows Networking Commands

Windows has some very useful networking utilities that are accessed from a command line (cmd console).

On Windows 10 type cmd in the search box to open a command console.

The networking commands are mainly used for getting system information and troubleshooting networking problems.

Here we look at the 10 commands that I use most often.

1. Ping Command

The ping command is one of the most often used networking utilities for detecting devices on a network and for troubleshooting network problems.

When you ping a device you send that device a short message, which it then sends back (the echo).

The general format is ping hostname or ping IPaddress.

ping www.google.com or ping 216.58.208.68

Читайте также:  Windows server client version

This article covers the ping command in more detail

2. ipconfig Command

Another indispensable and frequently used utility that is used for finding network information about your local machine like IP addresses, DNS addresses etc

Basic Use: Finding Your IP Address and Default Gateway

Type the command ipconfig at the prompt.

The following is displayed

Ip config has a number of switches the most common are:

ipconfig /all – displays more information about the network setup on your systems including the MAC address.

ipconfig /release – release the current IP address

ipconfig /renew – renew IP address

ipconfig /? -shows help

ipconfig/flushdns – flush the dns cache

3. Hostname Command

A very simple command that displays the host name of your machine. This is much quicker than going to the control panel>system route.

4. getmac Command

Another very simple command that shows the MAC address of your network interfaces

5. arp Command

This is used for showing the address resolution cache. This command must be used with a command line switch arp -a is the most common.

Type arp at the command line to see all available options.

6. NSlookup

Used for checking DNS record entries. See Using NSlookup for more details

7. Nbtstat

Diagnostic tool for troubleshooting netBIOS problems. See This technet article.

8 Net Command

Used for managing users,service,shares etc see here

9. Netstat Command

Used for displaying information about tcp and udp connections and ports. See tcp and udp ports and sockets and how to use the netstat command

10. TaskKill Command

View a list of running tasks using the tasklist command and kill them by name or processor ID using the taskKill command- See this tutorial.

Windows Network Commands for TCP/IP

PING: Test the network connection with a remote IP address

The -t option to ping continuously until Ctrl-C is pressed.
If you specify the -t option you can always get statistics without interrupting pings by pressing Ctrl + Break

This command is also useful to generate network load by specifying the size of the packet with the -l option and the packet size in bytes.

Tracert

TRACERT: Displays all intermediate IP addresses through which a packet passes through, between the local machine and the specified IP address.

This command is useful if the ping command does return any data, to determine at what level the connection failed.

IpConfig

IPCONFIG: Displays or refresh the TCP/IP configuration

This command, when executed with no options, displays the current IP address, the subnet mask and default gateway (network interfaces of the local machine)

  • /all: Displays all network configuration, including DNS, WINS, DHCP servers, etc .
  • /renew [adapter]: Renews DHCP configuration for all adapters (if adapter is not specified) or a specific adapter indicated by the [adapter] parameter.
  • /release [adapter]: Sends a DHCPRELEASE message to the DHCP server to release the current DHCP configuration and cancel the IP address configuration for all adapters (if adapter is not specified) or a specific adapter indicated by the [adapter] parameter. This parameter disables TCP/IP for network cards configured to automatically obtain an IP address.
  • /flushdns: Empty and reset the DNS client resolver cache. This option is useful to exclude negative entries and all other entries added dynamically to the cache.
  • /displaydns: Displays the DNS client resolver cache, which includes entries preloaded from the local host file and any recently obtained records for name queries resolved by the host computer. The DNS Client service uses this information to quickly resolve frequently queried names, before querying the configured DNS servers.
  • /registerdns: Refreshes all DHCP leases and re-registers DNS names.
Читайте также:  Как сделать экран приветствия как у windows 10

NetStat

Route

ARP: Resolving IP addresses to MAC addresses. Displays and modifies the translation tables of IP addresses to physical addresses used by the ARP address resolution protocol.

  • -a Displays active ARP entries by interrogating the current data protocol. If adr_inet is specified, only the physical and IP addresses of the specified computer are displayed. If more than one network interface uses ARP, entries for each ARP table are displayed.
  • -g is the same as -a
  • adr_inet Specifies an internet address.
  • -N adr_if Displays ARP entries for the network interface specified by adr_if.
  • -d Deletes the host specified by adr_inet.
  • -s Adds the host and associates the adr_inet internet address with the adr_eth physical address. The physical address is given as 6 hexadecimal bytes separated by hyphens. The entry is permanent.
  • adr_eth Specifies a physical address.
  • adr_if Specifies the internet interface whose address translation table should be modified. When not specified, the first applicable interface will be used.

Nbtstat

NBTSTAT: Update cache of the LMHOSTS file. Displays protocol statistics and current TCP/IP connections using NBT (NetBIOS over TCP/IP).

-a (adapter status) display the table (names) of the remote machine (known name).
-A (adapter status) display the table (names) of the remote machine (IP address).
-c (cache) display the remote name cache including the IP addresses.
-n (names) Lists local NetBIOS names.
-r (resolved) Lists names resolved by broadcast and via WINS.
-R (Reload) Clear and reload the table cache with the remote names.
-S (Sessions) Lists the sessions table with the destination IP addresses.
-s (sessions) Lists the sessions table with the destination IP addresses converted to host names via the hosts file.
Example :
nbtstat -A @IP
This command returns the NetBIOS name, system name, users connected . to the remote machine.

Telnet

The telnet command to access to a remote host in Terminal mode (passive screen) . It also allows you to check if any TCP service is running on a remote server by specifying the IP address after the TCP port number. Thus we can test whether the SMTP Service is running on a Microsoft Exchange server, using the IP address of the SMTP connector, and then 25 as the port number. The most common ports are:

  • ftp (21),
  • telnet (23),
  • smtp (25),
  • www (80),
  • kerberos (88),
  • pop3 (110),
  • nntp (119)
  • and nbt (137-139).

Hostname

Nslookup

Nslookup sends DNS requests to a DNS server

The nslookup command to send DNS requests to a server. By default, if you do not specify the DNS server, the command will use the one that is configured for your network interface (the one you use to surf the internet, for example).

Оцените статью