I ran this command to "block" an IP address:

route add -host reject

It works. I can see it in the list of routes:

root@mypc:~# route
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
default         _gateway         UG    0      0        0 enp3s0 -      !H    0      -        0 -

Cool. How do I delete the route?

I tried:

root@mypc:~# route del gw - netmask metric 0

But it gave this (error?):

-: Unknown host

How do I delete a route?

1 Answer 1


Run the original command but with delete instead of add:

route delete -host reject

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .