Create a network Topology Setup in such a way so that System A can ping to two Systems => System B and System C but both these systems should not be pinging each other. without using any security rule
e.g firewall etc.

Prerequisite:

  • 3 VM(Virtual Machine).

Solution:

First, we need to delete all the IP addresses from all the OS routing tables. after that add the System A Ip in System B and System C routing table, at last, add the System B and System C Ip in System A routing table. huh, that’s simple 😅.

Step-1)Delete all the rules from all the Systems:

route del -net 192.168.0.0(IP_ADDRESS) gw 192.168.0.1(GATEWAY) netmask 255.255.255.0(NETMASK) enp0s3(NIC Card)
Deleting Rule in System A
Deleting Rule in System B
Deleting Rule in System B

Step-2)Adding IP address of System A in System B and System C routing table

  • First of all, we need System A IP address.
System A IP address
  • Now we need to add this IP in System B and System C
Adding an IP Address of System A in System B routing table
Adding an IP Address of System A in System C routing table
  • Explanation: Here why I have used netmask 255.255.255.255 because it means to allow only one host i.e System A. Gateway 0.0.0.0 means has no gateway.

Step-3)Adding System B and System C IP address in the System A route table.

  • We need to gather the IP addresses of System B and System C
System B Ip address
System C Ip address
  • Now we need to add these IP addresses to the System A routing table.

Output

  • Let’s ping the System.
System A pinging to System B
System A pinging to System C
System B pinging to System A
System C pinging to System A
  • That’s great it's working 😃.
  • Now let’s test connectivity to System B — System C
System B not able to ping System C
System C not able to ping System B
  • That’s also great it is not working, why it is not working because we haven’t added the IP addresses of System B and System C to each other 😄.

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store