IP Addressing and Configuration

This document provides a comprehensive guide to Internet Protocol (IP) addressing, covering its structure, types, and configuration within Microsoft networking environments.

Understanding IP Addresses

An IP address is a unique numerical label assigned to each device connected to a computer network that uses the Internet Protocol for communication. It serves two main functions: host or network interface identification and location addressing.

IPv4 vs. IPv6

There are two primary versions of the IP protocol currently in use:

IP Address Classes (IPv4)

Historically, IPv4 addresses were divided into classes (A, B, C, D, E). While this classful addressing scheme is largely superseded by Classless Inter-Domain Routing (CIDR), understanding these classes can be helpful for legacy systems.

Class Range Default Subnet Mask Usable for
A 1.0.0.1 - 126.255.255.254 255.0.0.0 Large networks
B 128.0.0.1 - 191.255.255.254 255.255.0.0 Medium to large networks
C 192.0.0.1 - 223.255.255.254 255.255.255.0 Small networks
D 224.0.0.0 - 239.255.255.255 N/A Multicast
E 240.0.0.0 - 255.255.255.254 N/A Experimental

Private vs. Public IP Addresses

IP addresses are categorized based on their scope:

Network Address Translation (NAT) is commonly used to allow devices with private IP addresses to access the Internet using a single public IP address.

Subnetting

Subnetting is the process of dividing a larger IP network into smaller subnetworks. This helps to:

Subnetting is achieved using a subnet mask. The subnet mask uses a binary pattern of 1s to identify the network portion of an IP address and 0s to identify the host portion.

Tip: Classless Inter-Domain Routing (CIDR) notation (e.g., 192.168.1.0/24) is the modern standard for representing IP network addresses and their associated subnet masks. The number after the slash indicates the number of bits used for the network portion.

IP Address Configuration on Windows

You can configure IP settings on a Windows machine through the graphical interface or using command-line tools.

Graphical Interface

  1. Open "Network Connections" (e.g., by searching for it or going through Control Panel).
  2. Right-click on the network adapter you want to configure and select "Properties".
  3. Select "Internet Protocol Version 4 (TCP/IPv4)" and click "Properties".
  4. Choose "Obtain an IP address automatically" for DHCP or "Use the following IP address" to manually configure.
  5. Enter the IP address, subnet mask, default gateway, and DNS server addresses as required.
  6. Click "OK" to save changes.

Command-Line (netsh)

To configure a static IP address using the command prompt (run as administrator):

netsh interface ip set address name="[Adapter Name]" static [IP Address] [Subnet Mask] [Default Gateway]

Example:

netsh interface ip set address name="Ethernet" static 192.168.1.100 255.255.255.0 192.168.1.1

To configure DNS servers:

netsh interface ip add dns name="[Adapter Name]" [DNS Server IP] index=0
netsh interface ip add dns name="[Adapter Name]" [Alternate DNS Server IP] index=1

Common IP Configuration Parameters

Note: For most home and small office networks, using DHCP (Dynamic Host Configuration Protocol) to automatically assign IP addresses is recommended. This simplifies network management and reduces the chance of configuration errors.

Troubleshooting IP Connectivity

When facing network connectivity issues, the following command-line tools are invaluable: