LAB4 - IPv4 Networking.pdf
Document Details
Uploaded by WellRoundedQuantum5312
Full Transcript
NETW-0005 NETWORKING 1 LAB 4 – IPv4 Networking - IPv4 - DHCP - DNS - Tools and Terms - Troubleshooting IPv4 (INTERNET PROTOCOL VERSION 4) - Every computer or network device requires a “unique” address on the network - There are 4 ma...
NETW-0005 NETWORKING 1 LAB 4 – IPv4 Networking - IPv4 - DHCP - DNS - Tools and Terms - Troubleshooting IPv4 (INTERNET PROTOCOL VERSION 4) - Every computer or network device requires a “unique” address on the network - There are 4 main elements in a standard IPv4 address although not all 4 are required depending on the abilities your network device requires ADDRESS NOTES IP ADDRESS 192.168.0.30 Must be a unique address on your network NETMASK / 255.255.255.0 Determines the Network ID and the Host ID SUBNET MASK GATEWAY 192.168.0.1 Directs traffic that is not on your network DNS 8.8.8.8 Phone book of the internet - IPv4 addresses are 32 bits and comprised of 4 octets NETW-0005 NETWORKING 1 - Computers use BINARY (1 and 0) but we need to convert TO / FROM DECIMAL, a human readable format - Use the following table to assist you with all conversions TO / FROM BINARY POSITION BIT 8 7 6 5 4 3 2 1 VALUE 128 64 32 16 8 4 2 1 BINARY to DECIMAL - Example) 1 0 0 1 1 0 0 1 = ? POSITION BIT 8 7 6 5 4 3 2 1 VALUE 128 64 32 16 8 4 2 1 BINARY 1 0 0 1 1 0 0 1 ANSWER 128 16 8 1 - Add the VALUE of any POSITION BIT that contains a BINARY 1 - 128 + 16 + 8 + 1 = 153 DECIMAL to BINARY - Example) 207 = ? POSITION BIT 8 7 6 5 4 3 2 1 VALUE 128 64 32 16 8 4 2 1 BINARY 1 1 NULL NULL 1 1 1 1 ANSWER 128 16 8 1 NETW-0005 NETWORKING 1 - Show your work NUMBER POSITION BIT FROM LEFT REMAINING NUMBER 207 - 128 = 79 79 - 64 = 15 15 - 32 = null 15 - 16 = null 15 - 8 = 7 7 - 4 = 3 3 - 2 = 1 1 - 1 = 0 - Start from the left and place a BINARY 1 in each spot and subtract from the DECIMAL number remaining - 207 = 1 1 0 0 1 1 1 1 NETWORK VS HOST ID - IPv4 Addresses contain a NETWORK ID and a HOST ID - NETWORK ID is starting from the left and following the 1’s in the SUBNET MASK - HOST ID is the remaining bits that are 0’s in the SUBNET MASK - The NETWORK ID is 192.168.100.0 - The HOST ID is 10 - This network can contain 254 HOSTS (but isn’t there 256 possible numbers) - 192.168.100.0 can’t be used because it is the NETWORK ID - 192.168.100.255 can’t be used because it is the BROADCAST ADDRESS NETW-0005 NETWORKING 1 SPECIAL IPv4 ADDRESSES ADDRESS ADDRESS TYPE NOTES - This address is used to test device you are on Loopback Address - Any address starting with 127.0.0.1 can be used 127.0.0.1 Home Address - Confirms that your NIC is working - “There is no place like 127.0.0.1” - Automatic Private IP Addressing - Used to configure ad hoc network if no addressing 169.254.x.x APIPA Address is available (static or dynamic) - Not routable CIDR (CLASSLESS INTERDOMAIN ROUTING) - Another way of expressing a NETWORK ID - How many bits long is the SUBNET MASK SUBNET MASK REPRESENTATION CIDR REPRESENTATION IP ADDRESS = 192.168.215.44 192.168.215.44 /24 SUBNET MASK = 255.255.255.0 IP ADDRESS = 10.2.10.54 10.2.10.54 /16 SUBNET MASK = 255.255.0.0 WHAT IS IPV6? - We have long run out of IPv4 addresses so they came out with IPv6 in 1998 - IPv6 can run alongside with IPv4 on NIC (Dual Stack) - IPv6 solves several problems with IPv4 o Out of IPv4 (32 bit) addresses 1. 4,294,967,296 addresses o IPv6 (128 bit) addresses 1. 340,282,366,920,938,463,463,374,607,431,768,211,456 addresses o Auto Configuring o Every workstation has multiple IPv6 addresses o Eliminates the need for NAT (Network Address Translation) - We will visit IPv6 later in ROUTING and NETWORKING courses NETW-0005 NETWORKING 1 HOW ARE WE USING IPv4 IF ADDRESSES ARE ALL USED? - We are using NAT (Network Address Translation) for our internal networks - An entire network can be behind a single public network address - Example: Home Router o Everybody uses 192.168.0.0 or 192.168.1.0 network at home o Internet will see all traffic from that network come from the single public IP Address 182.140.25.142 o The home router performs the NAT so that it knows what computer in the private network sent \ receive the data DHCP (DYNAMIC HOST CONFIGURATION PROTOCOL) - If duplicate IPv4 addresses are found on the same network, the network can crash, or devices will not be allowed to join the network - We use DHCP to manage the addresses for us o Can be a Windows DHCP Server o Your home router is your DHCP server and a DHCP client from your ISP o Can be used to assign network information 1. IP ADDRESS 2. SUBNET MASK 3. GATEWAY 4. DNS 5. OTHER (Time Server, PXE Server, WINS, etc) NETW-0005 NETWORKING 1 - Uses the DORA process o Discovery = Client BROADCASTS, “I need an address” o Offer = DHCP Server make and offer “You want this address?” o Request = Client ask DHCP Server “can I take this address” o Acknowledge = DHCP Server tells client “You can use this address” - DHCP Server takes that address out of the pool and records who is using it - DHCP Server sets a LEASE time of 24 hours o At halfway point, client asks DHCP Server if they can keep the address and renews the LEASE - If NO DHCP Server is found, you must configure a STATIC address, or you will receive an APIPA address NETW-0005 NETWORKING 1 DNS (DOMAIN NAME SYSTEM) - Phone book of the internet since we can remember names but not numbers - Steps for a DNS request 1. Host asks DNS server for www.newegg.ca IP Address 2. DNS server responds with IP address for the record www.newegg.ca 3. Host uses IP address to visit www.newegg.ca 4. If DNS server does not know the answer, it asks its DNS server Each DNS server will cache the answer until record expires - Steps for a client looking up an address 1. Check local DNS cache 2. Check hosts file at C:\Windows\System32\Drivers\ETC\hosts 3. Check DNS server - Networking 3 is a DNS course ! TOOLS AND TERMS - ARP (Address Resolution Protocol) o Used to discover the MAC address (HW Static Address) associated to IP Address - IPCONFIG o Provides the current configured IP information for the host computer - IPCONFIG /ALL o Provides more detailed information / RELEASE = give up or clear DHCP address information / RENEW = request a new DHCP address /DISPLAYDNS = Shows DNS cached records /FLUSHDNS = Clear DNS cached records NETW-0005 NETWORKING 1 - PING o Are you there? o PING by NAME or IP ADDRESS to see if you get a response o May not always respond if FIREWALL is on remote device o Server\Router may be configured to not respond to PINGS 1. DDOS (Distributed Denial Of Service) Attack o Example: PING 192.168.215.40 o Example: PING www.tsn.ca - NETSTAT o See what/who is connected to your computer o Show PROTOCOL / ADDRESS:PORT / STATE o NETSTAT /? - TRACERT / PATHPING o How many router or network hops to our destination o If you can’t reach a destination (IP or WEBSITE) this shows where connection is broken o Show route traffic takes to destination o Example: TRACERT www.tsn.ca o Example: PATHPING 204.26.241.55 - NETSH o CMD line utility to manage network settings o Manage, set IPv4, set IPv6, Firewall settings o Interactive Tool – Similar to DISKPART o Example: netsh interface ip set address "connection name" static 192.168.0.101 255.255.255.0 192.168.0.1 NETW-0005 NETWORKING 1 TROUBLESHOOTING - Start with you and work your way out 1. Ping your 127.0.0.1 address 2. Ping your Gateway 3. Ping any Internet address (8.8.8.8) 4. Ping any Internet name address (www.google.ca) - These steps never change! - Do not call your instructor over until you have completed these steps