02-07-2011 03:10 PM - edited 03-06-2019 03:24 PM
Hi all,
i know about /30 subnet we use when we have to use point to point network.
/30 we use when we need only 2 hosts on either end of network.
cansomeone tell me why and when we use /31 subnet mask.
thanks
mahesh
Solved! Go to Solution.
02-08-2011 02:56 AM
Hi Mahesh,
My understanding is that since a point to point doesn't really need a broadcast address, instead of using a /30 which is 4 addresses, you can use a /31 and use 2 address and it works. I havenot really tried it but it works.
Cheers,
-amit singh
02-08-2011 03:30 AM
Hi,
Using a /31 subnet mask helps conserve your IP address space for point to point links. It doubles the number of links that you can number from a given block of addresses. Think of large organisations that have hundreds of WAN links but are rapidly running out of address space.
This is especially useful if you have paid for a block of public addresses from your ISP and so you want to use as many of them as possible.
Not only can a /31 subnet be used on serial interfaces but it can also be assigned to ethernet interfaces:
http://packetlife.net/blog/2008/jun/18/using-31-bit-subnets-on-point-point-links/
02-08-2011 09:32 AM
I have never tried using a /31 but I can say that the 2 address you have configured 192.168.5.2 and 192.158.5.1 are different segments if you use a /31 mask (255.255.255.254)
what happens if you use .2 and .3? (may require you to change some static routes)
02-07-2011 03:16 PM
This should help.
http://www.cisco.com/en/US/docs/ios/12_2t/12_2t2/feature/guide/ft31addr.html
http://tools.ietf.org/html/rfc3021
Cheers,
-amit singh
02-07-2011 03:25 PM
Hi amit,
thanks for reply.
so my understanding was we use /30 for point to point links.
what is difference between /30 /31 then?
mahesh
02-08-2011 02:56 AM
Hi Mahesh,
My understanding is that since a point to point doesn't really need a broadcast address, instead of using a /30 which is 4 addresses, you can use a /31 and use 2 address and it works. I havenot really tried it but it works.
Cheers,
-amit singh
02-08-2011 03:30 AM
Hi,
Using a /31 subnet mask helps conserve your IP address space for point to point links. It doubles the number of links that you can number from a given block of addresses. Think of large organisations that have hundreds of WAN links but are rapidly running out of address space.
This is especially useful if you have paid for a block of public addresses from your ISP and so you want to use as many of them as possible.
Not only can a /31 subnet be used on serial interfaces but it can also be assigned to ethernet interfaces:
http://packetlife.net/blog/2008/jun/18/using-31-bit-subnets-on-point-point-links/
02-08-2011 10:00 AM
Many thanks to amit and sean too.
mahesh
02-08-2011 08:17 AM
Hi Amit,
i tried to use /31 on my network but it did not work.
my router has direct connection to layer 3 switch.
router connects to isp cable modem.
layer 3 config
interface FastEthernet0/11
description Lan connection to 2650XM Router
no switchport
ip address 192.168.5.2 255.255.255.252
spanning-tree portfast
router config to layer 3 switch
sh run int fa1/0
Building configuration...
Current configuration : 183 bytes
!
interface FastEthernet1/0
description Lan connection to Switch 3550SMIA
ip address 192.168.5.1 255.255.255.252
i change the mask to 255.255.255.254 and it did not work?
mahesh
02-08-2011 09:32 AM
I have never tried using a /31 but I can say that the 2 address you have configured 192.168.5.2 and 192.158.5.1 are different segments if you use a /31 mask (255.255.255.254)
what happens if you use .2 and .3? (may require you to change some static routes)
02-08-2011 09:59 AM
Hi,
Many thanks i used IP address 192.168.5.2 and .3 and it worked.
regards
mahesh
06-13-2018 07:24 AM
In that range the .0 and .1 are in the same /31 using a .0 seems crazy but since you don't have a network and broadcast address that is how it works.
10-24-2018 07:29 PM
Correct, think of your subnet training. /31 leave two IPs together, 0 and 1 are both in the same "network". (don't need the quotes, it's true, just no broadcast and network add needed as stated. It is similar to using the .0 address in a full /23. Seems totally odd, but is still an address and yet not, in this subnet, the network address.
10-24-2018 07:31 PM
Correct, think of your subnet training. /31 leave two IPs together, 0 and 1 are both in the same "network". (don't need the quotes, it's true, just no broadcast and network add needed as stated. It is similar to using the .0 address in a full /23. Seems totally odd, but is still an address and yet not, in this subnet, the network address.
10-02-2019 03:48 AM
@Ben Rodriguez wrote:In that range the .0 and .1 are in the same /31 using a .0 seems crazy but since you don't have a network and broadcast address that is how it works.
Using 0 as an address only seems crazy if your thinking about /24 or smaller address space (/31 & /32 aside) if you work with /23 or bigger address apace 0 becomes an entirely valid and normal address to use as the Subnet Boundaries beging with /23 will span multiple octets so if you left 0 out you would be wasting a lot of addresses very quickly
07-19-2020 06:36 AM
Hi Denis,
I believe the first rule to create Point-to-Point link is that we need to configure IP address from the same sub net that opposite end interface is configured with.
04-21-2020 07:42 AM - edited 04-21-2020 07:44 AM
My apologies! I should have kept reading the reply's!
The enterprise business I work for has been using /30 for almost all point to point connections. Wait til they see this!
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide