0

Scenario:1

Suppose external Router R1 has interface a connected with interface b of the site Router R2. And Router R1 using IP address 80.0.0.0/8 for a. Router R2 has 4 subnets 80.0.0.0/10, 80.64.0.0/10, 80.128.0.0/10, 80.192.0.0/10. enter image description here My first question is router R1 with interface a and router R2 interface b has same ip address 80.0.0.0/8 or interface a using 80.0.0.0/8 and interface b using 80.0.0.0/10?

My second question is router R2's interface c has ip address 80.0.0.0/10?or any of the IP address of the block 80.0.0.0/10 for example 80.0.0.1/10?

Scenario:2

Suppose a host A, host B, router connected to 3 different ports of switch.Suppose host A has interface M and Mac address aaaa connected to switch port of N. enter image description here

My question is switch port interface N and host interface M could share same Mac address or switch has 3 different Mac address for it's interface N, P, Q?

S. M.
  • 415
  • 7
  • 32
  • Router R1 using IP address 80.0.0.0/8 isn't possible since that address has all host bits set to zero. It's the network prefix and unusable as an actual interface address. Router R2 has 4 subnets 80.0.0.0/10, 80.64.0.0/10, 80.128.0.0/10, 80.192.0.0/10 is also not possible as these subnets all overlap with 80.0.0.0/8. – Zac67 Feb 16 '22 at 13:25
  • @Zac67 If A wants to send frame to B. My question is layer2 frame from A to switch reached by port number Or Mac address? A using destination Mac of B, but A reached to switch by using port number? – S. M. Feb 16 '22 at 18:53
  • The switch receives A's frame (on port N, learns/updates A's MAC association), looks up B's MAC in its SAT/CAM, sees the association with port Q and forwards the frame out of that port. – Zac67 Feb 16 '22 at 18:58
  • @Zac67 SAT/CAM full form? – S. M. Feb 16 '22 at 19:02
  • Source address table and content-addressable memory (table). – Zac67 Feb 16 '22 at 19:07
  • @Zac67 suppose router R1 has interface a has IP address 81.0.0.1 and IP address of interface b of R2 could be any belongs to any of 4 subnets. I mean interface b has IP address could be 80.0.0.1 or 80.64.0.2 or 80.128.0.2 or 80.192.0.5? – S. M. Feb 16 '22 at 19:10
  • R1's port a and R2's port b are required to share a common subnet in order to communicate. 81.0.0.1/24 and 81.0.0.2/24 would work. OTOH, 81.0.0.1/7, 80.0.0.1/7, 80.64.0.2/7, 80.128.0.2/7, and/or 80.192.0.5/7 would also work. You might want to read up on what the subnet mask is about. – Zac67 Feb 16 '22 at 19:38
  • @Zac67 when 80.0.0.1/7, 80.64.0.2/7, 80.128.0.2/7, and/or 80.192.0.5/7 use for then it could not be overlapped with 80.0.0.1/10, 80.64.0.2/10, 80.128.0.2/10, 80.192.0.5/10 c, e, g, i interface, if I design? – S. M. Feb 16 '22 at 19:51
  • Yes, they would overlap - I was referring to those two interfaces only. All the /10 subnets are part of 80.0.0.1/7. You should really read up on basic subnetting. – Zac67 Feb 16 '22 at 19:57
  • @Zac67 if A connected by Ethernet to switch then both interface M and N has unique Mac address? – S. M. Feb 16 '22 at 20:59
  • A switch doesn't use MAC addresses on its interfaces, a switch is transparent on layer 2. Routers and hosts use MAC addresses. And all of them must be unique. – Zac67 Feb 16 '22 at 21:18
  • @Zac67 but switch ports also transparent, why they use ports? – S. M. Feb 16 '22 at 21:23
  • @Zac67 what do you mean by Mac address transparent on layer 2? – S. M. Feb 16 '22 at 21:33
  • 1
    @Zac67 “Transparent” means that when you connect a switch to an Ethernet system, no changes are made in the Ethernet frames that are bridged – S. M. Feb 16 '22 at 22:37
  • @Zac67 router every interface has unique routing table? – S. M. Feb 18 '22 at 14:37
  • Yes, each router has its own routing table and makes its own forwarding decision. – Zac67 Feb 18 '22 at 16:05
  • @Zac67 all interface of one router has one routing table? – S. M. Feb 18 '22 at 16:06

1 Answers1

3

My first question is router R1 with interface a and router R2 interface b has same ip address 80.0.0.0/8 or interface a using 80.0.0.0/8 and interface b using 80.0.0.0/10?

80.0.0.0 is a unique address, regardless of the subnet mask. So two devices cannot have that same address. Remember though that 80.0.0.0 is not a valid host address with a mask of /8 (or /10). You could use 80.0.0.1

Interfaces a and b can be on any unique subnet. They don't have to be part of the 80.0.0.0/8 subnet.

The routing table of R1 should have a route to 80.0.0.0/8, with the next hop of interface b on R2.

My second question is router R2's interface c has ip address 80.0.0.0/10?or any of the IP address of the block 80.0.0.0/10 for example 80.0.0.1/10?

Since 80.0.0.0/10 is not a valid host address, the next available address in that subnet is 80.0.0.1

My question is switch port interface N and host interface M could share same Mac address or switch has 3 different Mac address for it's interface N, P, Q?

The switch's interfaces don't have MAC addresses. Another (old) name for a switch is a transparent bridge. It transparently forwards frames based on its MAC forwarding table. If the switch has some control or management function, such as spanning tree or a management interface, those functons will have MAC addresses

Ron Trunk
  • 68,291
  • 5
  • 66
  • 126