Ping Google only not Facebook!

Durgesh Kumar Patel
2 min readDec 16, 2020

--

Here, I am using Redhat8 operating system to do task in which I have to create setup so that i can ping google but not able to ping Facebook from same system.

As you can see above picture in which i ran command :

route -n : For checking routing table .

route del -net 0.0.0.0 : This cmd helped me to delete that rule which is helping to pinging google and facebook both,

route -n : THEn, i again ran same command because i have to confirm rule is deleted successfully or not .

In above picture I ran commands:

nslookup www.google.com : To see IP of google

route add -net 172.217.166.0 netmask 255.255.255.0 gw 192.168.43.1 enp0s3 : This command help to create rule in Routing table for pinging google IPs only.

route -n : I again ran this command to confirm rule is created successfully or not .

In above picture I ran command :

ping 172.217.166.36 : This command help me to ping ip f google and you can see also i successfully pinged with google ip here .

In above picture i ran command :

nslookup www.facebook.com : To check ip of facebook.

ping 31.13.79.35 : Its help to ping with facebook ip but i created rule which only help ping to google so, as you can see in picture i am not able to ping with facebook ip .

Here task is completed,I am only able to ping with google ip and if you want to ping facebook ip also .So, you have to create rule for Facebook ip also in Routing Table as we created for google.

Thanku For Reading….

--

--

No responses yet