Creating a setup so that you can ping Google but not Facebook at the same time.

Abhishek kumar
Mar 14, 2021

For this specific Task I am using RHEL8, First Configure it. After Ping google.com and facebook.com from your local system. you will be able to ping both using commands #ping -4 google.com, #ping -4 facebook.com.

Next you have to see your routing table by the command #route -n

Delete existing routing table so that you can configure new one #route del -net 0.0.0.0

Ping both google and Facebook, it shows network is unreachable.

use nslookup google.com for finding the ip address of google.

Add the new routing table by the command #route add -net <IP address of google> netmask <address> gw <gateway of system> <ethernet card name>

Now use #ping -4 google.com, google is pingable.

#ping -4 facebook.com, It is still unreachable.

Now task is completed.

Thanks for reading.

--

--