Download presentation
Presentation is loading. Please wait.
Published byAnn Horn Modified over 8 years ago
1
Wrapping up subnetting, mapping IPs to physical ports BSAD 146 Dave Novak Sources: Network+ Guide to Networks, Dean 2013
2
Last time What is a process? Process-level communication TCP How different from IP Connection-based service Reliability aspects UDP
3
Outline Subnet review Assigning logical IPs to physical ports An example
4
Subnets Single class C supports 254 hosts Can’t use 00000000 or 11111111 as host addresses But, 255.255.255.240 subnet only supports 14 subnets * 14 hosts/per subnet = 196 hosts What happened to the rest of the IP addresses explained by these slides Can’t use any combinations of 0000 or 1111 for EITHER the network ID OR host ID
5
IPv4 Class C address Class C address examples 202.182.103.0 An octet is a group of 8 bits IPv4 has 32 total bits First 3 octets of class C provides the NETWORK reference Last octet of class C provides the HOST reference
6
Subnets A single Class C example Subnetting 4 bits prefix, 4 bits suffix There are 14 valid 4-bit network IDs for the subnetted class C address Where does 14 come from ? 2 4 = 16 16 – 2 = 14 CANNOT use 0000 or 1111 The same 14, 4-bit host IDs are used on each of the 14 255.255.255.240 subnets 4 bits Binary is base 2
7
Subnets 255.255.255.240 = subnet mask 0001 1000 0010 1001 0011 1010 0100 1011 0101 1100 0110 1101 0111 1110 Each 4 bit group represents a subnet and a host number on each subnet Subnet 0001 has 14 hosts Subnet 0010 has 14 hosts. Subnet 1110 has 14 hosts
8
Subnets Host numbering on subnet not sequential from one subnet to another Subnet #1 = 0001 This is the NETWORK reference for Subnet #1 host #1 on subnet #1 = 00010001 = 17 host #2 on subnet #1 = 00010010 = 18 host #3 on subnet #1 = 00010011 = 19 …… host #14 on subnet #1 = 00011110 = 30
9
Subnets Move on to subnet #2 Subnet #2 = 0010 host #1 on subnet #2 = 00100001 = 33 host #2 on subnet #2 = 00100010 = 34 host #3 on subnet #2 = 00100011 = 35 ….. host #14 on subnet #2 = 00101110 = 46
10
Subnets We can determine host address for each of the 14 subnets this way… Subnet #14 = 1110 host #1 on subnet #14 = 11100001 = 225 host #2 on subnet #14 = 11100010 = 226 And so on… host #14 on subnet #14 = 11101110 = 238
11
Subnets IP ranges for class C network address 197.70.115.0 with mask 255.255.255.240 (supporting 14 subnets with 14 hosts each): 1) 197.70.115.16 -.31 host ranges (.17 -.30) 2) 197.70.115.32 -.47 host ranges (.33 -.46) 3) 197.70.115.48 -.63 host ranges (.49 -.62) 4) 197.70.115.64 -.79 host ranges (.65 -.78) 5) 197.70.115.80 -.95 …
12
Subnets Subnetting is not a perfect solution (with CIDR available, subnetting may not even be considered a “good” solution) “Lose” potentially valid host IP addresses in the process of creating more logical networks Can allocate addresses more effectively by subdividing the static, class-based IPv4 address space, but lose valid addresses in process
13
CIDR With respect to CIDR, the same example we are discussion with respect to subnetting is 197.70.115.0 / 28 n = 24 bits is STANDARD Class C IPv4, so n < 24 supernet n > 24 subnet CIDR Mask = 255.255.255.240 (same as subnet mask) Wildcard Mask = 0.0.0.15 Number of leftmost bits in mask
14
CIDR Notation example Source: CIDR conversion table, University of Wisconsin: https://kb.wisc.edu/ns/page.php?id=3493https://kb.wisc.edu/ns/page.php?id=3493
15
IP assignment High-level overview of concepts and technologies Generally, not discussing specific hardware, software, or vendors high level and generic –may be exceptions to some of the general points when specific technologies are studied in detail Logical versus physical operations / functions Logical functions in software are not always easily mapped to something physical
16
IP assignment IP is software IP addresses are software Addresses are mapped to logical (virtual or software-based) interface on physical device
17
Interface Configuration In case where network protocol stack only works with specific physical network (IPX/SPX, AppleTalk, SNA), the network interface does not need to be identified to software Software knows what interface type is because there are no other choices Legacy Novell network Novell software / hardware IPX / SPX May not require much configuration by admin
18
Interface Configuration MAC address is physically associated with hardware (the NIC) Physical interface on the NIC (the RJ45 connection on card) associated with physical address (the MAC) Can’t be changed (short of replacing NIC) Can’t be configured 1234 4-port Switch Physical interface 1 maps to Physical Address 00-E3-B9-6F-5A-EA Physical interface 2 maps to Physical Address 00-A1-B9-3D-8B-EC So on… 4 interfaces 4 MAC addresses
19
Interface Configuration The TCP/IP networking protocol stack independent of physical network (LAN technology and topology) IP addresses are implemented in software, not hardware (admin must create mappings to interfaces via software) Logical IP to physical interfaces (connection) Admin assigns IP addresses to various interfaces
20
Routing Interface Consider a very basic hypothetical router: one physical interface out, one physical interface in Router 12 1243 Some type of outside link to Internet (T1, T3, OC 3, etc…) Switch on LAN PC 1 PC 2PC 3 Uplink port to router Some type of inside link to LAN (Ethernet using Cat 5, Cat 6, some type of fiber, etc…
21
Routing Interface 12 1243 Some type of outside link to Internet Router Switch on LAN PC 1 PC 2PC 3 Uplink port to router Switch physical interfaces #1 - #4 map to 4 physical MAC addresses on PCs and the router (4 physical interfaces 4 MAC addresses - 3 on PCs, 1 on router). PCs maintain ARP lookup table to map logical IP addresses to physical MAC address Two physical router interfaces (#1 and #2) – LAN (inside) only “knows” about #2 Any IP address not local to LAN, goes first to router physical interface #2 and then out physical interface #1 to some other router somewhere on the internet (ANY and ALL IP addresses not on LAN) In this case, 2 physical interfaces handle many different logical IP addresses
22
Routing Interface 12 1243 Some type of outside link to Internet Router Switch on LAN PC 1 PC 2PC 3 Assume our LAN has other switches and PCs and has ownership of an unsubnetted class C address block 195.70.115.0 Anything coming in from outside going to any address in the class C block 195.70.115.0 (the network reference is 195.70.115) comes to the LAN via physical interface #1 on the router Each physical interface on router also has a MAC address Each physical interface on router is mapped to a logical IP address within the 195.70.115.0 address space Router interface #1 = 195.70.115.1 mapped to 00-A5-B5-3D-2B-AA Router interface #2 = 195.70.115.2 mapped to 00-A5-B5-3A-5C-BC
23
Routing Interface 12 1243 Some type of outside link to Internet Router Switch on LAN PC 1 PC 2PC 3 Incoming packet for IP address 195.70.115.4 1 st – router physical interface #1 gets packet from remote sender because some outside core routers know IP interface 195.70.115.1 handles all traffic destined for the entire 195.70.115.0 network 2 nd – router examines IP address of packet, consults routing table, determines it is local and then resolves MAC address to decide where to send the packet on the LAN 195.70.115.4 = 00-A1-B9-3D-8B-EC and Forwards packet out router physical interface #2, which is mapped to IP address 195.70.115.2 3 rd – in this case, everything local is forwarded out router physical interface #2 mapped to IP 195.70.115.2 to switch physical interface #4 Switch knows 00-A1-B9-3D-8B-EC goes out switch physical port #2. Destination PC 2 gets packet, reads MAC address and processes
24
Routing Interface Class C IP address block 195.70.115.0 195.70.115.0 195.70.115.255 In our example, router handles many logical IP addresses on single physical interface (that is associated with one MAC address)
25
Routing Interface Assume we subnet using mask 255.255.255.192 (2 bits in prefix, 6 in suffix) Binary representation of subnet mask is 11111111.11111111.11111111.11000000
26
Application Transport Network Address DestinationGateway 195.70.115.128195.70.115.67 195.70.115.69 195.70.115.64195.70.115.69 Default195.70.115.65 Source Host Network Address DestinationGateway 195.70.115.128195.70.115.129 195.70.115.67 195.70.115.64195.70.115.67 Default195.70.115.65 Gateway or Router 195.70.115.129 195.70.115.64 Application Transport Network Address DestinationGateway 195.70.115.128195.70.115.140 195.70.115.64195.70.115.129 Default195.70.115.129 Destination Host 195.70.115.128 By subnetting scheme, we know default gateway is connected to network 195.70.115.64 Based on a Class B example in TCP/IP Network Administration [online] http://www.unix.org.ua/orelly/networking/tcpip/ch02_05.htm Default = address 195.70.115.65
27
Summary Subnet review Assigning logical IPs to physical ports An example
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.