Presentation is loading. Please wait.

Presentation is loading. Please wait.

Efficient IP Addressing Subnetting 1. Review: IP Addressing Suppose hosts had arbitrary addresses – Then every router would need a lot of information.

Similar presentations


Presentation on theme: "Efficient IP Addressing Subnetting 1. Review: IP Addressing Suppose hosts had arbitrary addresses – Then every router would need a lot of information."— Presentation transcript:

1 Efficient IP Addressing Subnetting 1

2 Review: IP Addressing Suppose hosts had arbitrary addresses – Then every router would need a lot of information – …to know how to direct packets toward the host 2 host LAN 1... host LAN 2... router WAN 1.2.3.45.6.7.82.4.6.81.2.3.55.6.7.92.4.6.9 1.2.3.4 1.2.3.5 forwarding table

3 3 Review: IP Addressing scalability Number related hosts from a common subnet – 1.2.3.0/24 on the left LAN – 5.6.7.0/24 on the right LAN host LAN 1... host LAN 2... router WAN 1.2.3.41.2.3.71.2.3.1565.6.7.85.6.7.95.6.7.212 1.2.3.0/24 5.6.7.0/24 forwarding table

4 4 Review: Scalability- Adding new hosts No need to update the routers – E.g., adding a new host 5.6.7.213 on the right – Doesn’t require adding a new forwarding entry host LAN 1... host LAN 2... router WAN 1.2.3.41.2.3.71.2.3.1565.6.7.85.6.7.95.6.7.212 1.2.3.0/24 5.6.7.0/24 forwarding table host 5.6.7.213

5 Some Questions: IP Addressing How are IP addresses managed – Given out Single point – Hierarchical – Documentation Record of what is given out and to whom – Accounting What remains? 5

6 6 Giving out: Obtaining a Block of Addresses The Internet Assigned Numbers Authority (IANA) is responsible for the global coordination of IP addressing, and other Internet protocol resources – Internet Corporation for Assigned Names and Numbers (ICANN) Internet Corporation for Assigned Names and Numbers Allocates large address blocks to Regional Internet Registries – Regional Internet Registries (RIRs) Allocates address blocks within their regions Allocated to Internet Service Providers and large institutions – Internet Service Providers (ISPs) Allocate address blocks to their customers Who may, in turn, allocate to their customers… Prefix: assigned to an institution – Addresses: assigned by the institution to their nodes

7 Regional Internet Registries Five RIRs to cater to five large global regions African Network Information Centre (AfriNIC) for AfricaAfrican Network Information CentreAfrica American Registry for Internet Numbers (ARIN) for the United States, Canada, and several parts of the Caribbean region. American Registry for Internet Numbers Caribbean region Asia-Pacific Network Information Centre (APNIC) for Asia, Australia, and neighboring countries Asia-Pacific Network Information Centre AsiaAustralia Latin America and Caribbean Network Information Centre (LACNIC) for Latin America and parts of the Caribbean region Latin America and Caribbean Network Information CentreLatin America RIPE NCC (RIPE NCC) for Europe, the Middle East, and Central Asia RIPE NCCEuropeMiddle East Central Asia 7

8 8 Record: Figuring Out Who Owns an Address Address registries – Public record of address allocations – Internet Service Providers (ISPs) should update when giving addresses to customers – However, records are notoriously out-of-date Ways to query – http://www.db.ripe.net/whois to find RIPE NCC database for IP addresses http://www.db.ripe.net/whois – http://www.geektools.com/whois.php – …

9 9 Are 32-bit Addresses Enough? Not all that many unique addresses – 2 32 = 4,294,967,296 (just over four billion) – Plus, some are reserved for special purposes – And, addresses are allocated in larger blocks And, many devices need IP addresses – Computers, PDAs, routers, tanks, toasters, … Long-term solution: a larger address space – IPv6 has 128-bit addresses (2 128 = 3.403 × 10 38 ) Short-term solutions: limping along with IPv4 – Private addresses – Network address translation (NAT) – Dynamically-assigned addresses (DHCP)

10 10 Hard Policy Questions How much address space per geographic region? – Equal amount per country? – Proportional to the population? – What about addresses already allocated? Address space portability? – Keep your address block when you change providers? Keeping the address registries up to date? – What about mergers and acquisitions? – Delegation of address blocks to customers? As a result, the registries are horribly out of date

11 What the IP Address Meltdown Means For You Article in PC worldArticle in PC world: posted on Dec 1, 2010 5:39 pm: Brief synopsis The world is running out of IPv4 Internet addresses, without which the Internet can't function in its existing form. This has been known for some time, of course, but the situation has become a little more urgent with the news that in October and November, nearly all of the remaining blocks of addresses were assigned to various Regional Internet Registries (RIR) around the world……. Remaining five blocks of IP addresses given out by beginning of 2011 to the five RIRs….. 11

12 Objectives Economising IP address use: To subnet an IP Address from given network requirements – Why subnet – Hierarchy in subnetted addresses – How to subnet Identify network class Identify network requirements Calculate sub-network addresses Calculate available host addresses Calculate new subnet mask Assign new addresses 12

13 Advantages of Subnetting With subnetting, IP addresses use a 3-layer hierarchy: » Network » Subnet » Host Improves efficiency of IP addresses by not consuming an entire address space for each physical network. Reduces router complexity. Since external routers do not know about subnetting, the complexity of routing tables at external routers is reduced. Note: Length of the subnet mask need not be identical at all subnetworks. 13

14 Subnetting Problem: Organizations have multiple networks which are independently managed – Solution 1: Allocate one or more addresses for each network Difficult to manage From the outside of the organization, each network must be addressable. – Solution 2: Add another level of hierarchy to the IP addressing structure University Network Medical School Library Engineering School 14

15 The network prefix identifies a network and the host number identifies a specific host (actually, interface on the network). How do we know how long the network prefix is? – The network prefix is implicitly defined using class-based addressing – The network prefix is indicated by a subnet mask or netmask Two-level hierarchy network prefixhost number 15

16 Subnetting- Three level Hierarchy Split the host number portion of an IP address into a subnet number and a (smaller) host number. Result is a 3-layer hierarchy Then: Subnets can be freely assigned within the organization Internally, subnets are treated as separate networks Subnet structure is not visible outside the organization network prefix host number subnet number network prefix host number extended network prefix 16

17 Routers and hosts use an extended network prefix (subnet mask) to identify the start of the host numbers * There are different ways of subnetting. Commonly used netmasks for university networks with /16 prefix (Class B) are 255.255.255.0 and 255.255.0.0 Subnet Masks 17

18 Each layer-2 network (Ethernet segment, FDDI segment) is allocated a subnet address. Typical Addressing Plan for an Organization that uses subnetting 128.143.0.0/16 18

19 Advantages of Subnetting With subnetting, IP addresses use a 3-layer hierarchy: » Network » Subnet » Host Improves efficiency of IP addresses by not consuming an entire address space for each physical network. Note: Length of the subnet mask need not be identical at all subnetworks. 19

20 Task: Create subnetwork addresses Create subnetwork addresses for 20 different network addresses, using IP address 201.222.5.0 sales Admin 20

21 Convert the decimal dotted notation address 201.222.5.0 to binary: 11001001.11011110.00000101.00000000 STEP 1: Convert the decimal dotted notation 21

22 Determine the Class of the IP Address 201.222.5.0: CLASS C Step 2: Class of the IP Address 22

23 Based on the Class, determine what part of the IP address is the network portion and what part of the address is the host portion: 201.222.5.0 11001001.11011110.00000101.00000000 Network.Network.Network.Host Step 3. Find Network portion and Host portion 201. 222. 5. 0 23

24 Determine how many bits you need to borrow from the last octet (host portion) of the IP Address to give you the needed 20 subnets: 2 to the power of 2 = 4 subnets (less 2) 2 to the power of 3 = 8 subnets (less 2) 2 to the power of 4 = 16 subnets (less 2) 2 to the power of 5 = 32 subnets (less 2) 2 to the power of 6 - 64 subnets (less 2) Step 4: How many bits to borrow 24

25 Since you borrowed five bits from the host for subnets, determine how many hosts can you have on each of those subnets? 2 to the power of 3 = 8 hosts (less 2) giving you 6 hosts per subnet. Step 5: Determine how many hosts can you have on each of those subnets 11001001.11011110.00000101.00000000 Remaining bits = Number of hosts 25

26 Determine the Subnetworks’ Numbers from the borrowed 5 bits: 32 possible combinations Subnet #Binary Subnetwork 100000 200001 300010 400011 500100 600101 700110 800111 901000 1001001 1101010 1201011 1301100..…….. 3211111 Step 6: Determine the Binary Subnetworks Field Numbers 26

27 Determine the Range of Binary Host Field Numbers for Each Subnetwork: 3 bits: 8 possible hosts on each subnet Subnet #Binary SubnetworkRange of Host #’s 100000 200001000 - 111 300010000 - 111 400011000 - 111 500100000 - 111 600101000 - 111 700110000 - 111 800111000 - 111 901000000 - 111 1201100000 - 111..……..----------- 3211111 Step 7: Determine the Range of Binary Host Field Numbers for Each Subnetwork: 27

28 Subnet #Binary SubnetworkRange of Host #’sDecimal Host Numbers 100000 200001000 - 111.8 -.15 300010000 - 111.16 -.23 400011000 - 111.24 -.31 500100000 - 111.32 -.39 600101000 - 111.40 -.47 700110000 - 111.48 -.55 800111000 - 111.56 -.63 901000000 - 111.64 -.71 1001001000 - 111.72 -.79 1101010000 - 111.80 -.87 1201011000 - 111.88 -.95 1301100000 - 111.96 - 103..……..--------------------- 3211111 Step 8: Determine Decimal Host Numbers for Each Subnetwork 28

29 Step 9. Determine Our Subnet Addresses: # Binary SubnetworkRange of Host #’sSubnet Address 10000 0000 20000 1000201.222.5.8 3000 1 0 000201.222.5.16 40001 1000201.222.5.24 50010 0000201.222.5.32 60010 1000201.222.5.40 70011 0000201.222.5.48 80011 1000 201.222.5.56 90100 0000201.222.5.64 100100 1000201.222.5.72 110101 0000201.222.5.80 120101 1000201.222.5.88 130110 0000201.222.5.96...…….------------------------------------ 321111 1000 29

30 Step 10. Determine Host Addresses of the Six Nodes of Each Subnet: # Subnetwork Range of Host #’s Decimal Host #’sSubnet Address Host Address Range 100000 200001 000 - 111.8 -.15 201.222.5.8 201.222.5.9 thru 201.222.5.14 300010 000 - 111.16 -.23201.222.5.16 201.222.5.17 thru 201.222.5.22 400011 000 - 111.24 -.31201.222.5.24 201.222.5.25 thru 201.222.5.30 500100 000 - 111.32 -.39201.222.5.32 201.222.5.33 thru 201.222.5.38 600101 000 - 111.40 -.47201.222.5.40 201.222.5.41 thru 201.222.5.46 700110 000 - 111.48 -.55201.222.5.48 201.222.5.49 thru 201.222.5.54 800111 000 - 111.56 -.63201.222.5.56 201.222.5.57 thru 201.222.5.62 901000 000 - 111.64 -.71201.222.5.64 201.222.5.65 thru 201.222.5.70 1001001 000 - 111.72 -.79201.222.5.72 201.222.5.73 thru 201.222.5.78 1101010 000 - 111.80 -.87201.222.5.80 201.222.5.81 thru 201.222.5.86 1201011 000 - 111.88 -.95201.222.5.88 201.222.5.89 thru 201.222.5.94 1301100 000 - 111.96 - 103201.222.5.96 201.222.5.97 thru 201.222.5.--...……. ----------- ------------------------- ------------------------------------- 3211111 30

31 Based on the Class, determine the subnet mask for network 201.222.5.0 (remember that 5 bits were borrowed): 11111111.11111111.11111111.11111 000 Network Network Network Subnet Host Step 12: Find New Subnet mask 255. 255. 255. 248 31

32 YOU DID IT! 32

33 African Network Information Centre (AfriNIC) [1] for Africa African Network Information Centre [1]Africa American Registry for Internet Numbers (ARIN) [2] for the United States, Canada, and several parts of the Caribbean region. American Registry for Internet Numbers [2]Caribbean region Asia-Pacific Network Information Centre (APNIC) [3] for Asia, Australia, and neighboring countries Asia-Pacific Network Information Centre [3]AsiaAustralia Latin America and Caribbean Network Information Centre (LACNIC) [4] for Latin America and parts of the Caribbean region Latin America and Caribbean Network Information Centre [4]Latin America RIPE NCC [5] for Europe, the Middle East, and Central Asia RIPE NCC [5]EuropeMiddle EastCentral Asia 33


Download ppt "Efficient IP Addressing Subnetting 1. Review: IP Addressing Suppose hosts had arbitrary addresses – Then every router would need a lot of information."

Similar presentations


Ads by Google