cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Announcements

Cisco announces new innovations in SD-WAN, ISRs, SD-WAN Services, and Catalyst 9000 Series switches


108
Views
5
Helpful
4
Replies
Beginner

Why ip overlaps ?

Hello guys, I faced with problem.

 

R1

int f0/0

ip add 192.168.100.1 255.255.255.252

int f0/0.100

encapsulate do1q 100

ip add 192.168.100.254 255.255.255.0

 

SW

vlan 100

int f0/1

switchport mode trunk

switchport trunk allow vlan 100

 

int fa0/2

switchport mode access

switchport access vlan 100

spanning tree portfast

 

Can someone explain why when I try put ip address on R1 fa0/0 192.168.100.1 and trying to encapsulate IP address 192.168.100.254 I receive that overlapsing int f0/0 

 

 

 

 

Everyone's tags (1)
2 ACCEPTED SOLUTIONS

Accepted Solutions
VIP Mentor

Re: Why ip overlaps ?

Hello,

 

192.168.100.0/22 (or 192.168.100.0 255.255.255.252) is in the same address space as 192.168.100.0/24 (or 192.168.100.0 255.255.255.0), so you get an error.

 

Basically, if you use an /24 address space on one interface, you cannot use any of the subaddresses in that address space on any other interface on the same router.

 

If you convert both IP addresses and subnet masks to binary, you can see that the last octet (all zeros) in the /24 address covers all addresses in that space:

 

192.168.100.1 255.255.255.252
11000000.10101000.01100100.00000001 11111111.11111111.11111111.11111100

 

192.168.100.254 255.255.255.0
11000000.10101000.01100100.00000001 11111111.11111111.11111111.00000000

 

Does that make sense ?

Highlighted
VIP Advisor

Re: Why ip overlaps ?

Hello


@Juliusvar1 wrote:

R1

int f0/0

ip add 192.168.100.1 255.255.255.252

 

int f0/0.100

encapsulate do1q 100

ip add 192.168.100.254 255.255.255.0


Can someone explain why when I try put ip address on R1 fa0/0 192.168.100.1 and trying to encapsulate IP address 192.168.100.254 I receive that overlapsing int f0/0 

 


192.168.100.254/24  = 192.168.100.1-254 addressing

192.168.100.1/252  = 192.168.100.1-2 addressing <--- this overlaps with the above

 



kind regards
Paul

Please don't forget to rate any posts that have been helpful.
4 REPLIES
VIP Mentor

Re: Why ip overlaps ?

Hello,

 

192.168.100.0/22 (or 192.168.100.0 255.255.255.252) is in the same address space as 192.168.100.0/24 (or 192.168.100.0 255.255.255.0), so you get an error.

 

Basically, if you use an /24 address space on one interface, you cannot use any of the subaddresses in that address space on any other interface on the same router.

 

If you convert both IP addresses and subnet masks to binary, you can see that the last octet (all zeros) in the /24 address covers all addresses in that space:

 

192.168.100.1 255.255.255.252
11000000.10101000.01100100.00000001 11111111.11111111.11111111.11111100

 

192.168.100.254 255.255.255.0
11000000.10101000.01100100.00000001 11111111.11111111.11111111.00000000

 

Does that make sense ?

Beginner

Re: Why ip overlaps ?

I got it. Thank you !

VIP Advocate

Re: Why ip overlaps ?

Hi there,

int fa0/0 (/30) overlaps with the subnet assigned to fa0/0.100 (/24).

If you wanted to continue using these IP addresses then you would need to put the interfaces in separte VRFs.

Or you could reduce the subnet size for fa0/0.100 :

!
int f0/0.100
  encapsulate do1q 100
  ip add 192.168.100.254 255.255.255.128
!

cheers,

Seb,

Highlighted
VIP Advisor

Re: Why ip overlaps ?

Hello


@Juliusvar1 wrote:

R1

int f0/0

ip add 192.168.100.1 255.255.255.252

 

int f0/0.100

encapsulate do1q 100

ip add 192.168.100.254 255.255.255.0


Can someone explain why when I try put ip address on R1 fa0/0 192.168.100.1 and trying to encapsulate IP address 192.168.100.254 I receive that overlapsing int f0/0 

 


192.168.100.254/24  = 192.168.100.1-254 addressing

192.168.100.1/252  = 192.168.100.1-2 addressing <--- this overlaps with the above

 



kind regards
Paul

Please don't forget to rate any posts that have been helpful.
CreatePlease to create content
Content for Community-Ad

Blog-Cisco Community Designated VIP Class of 2019