How do I disable the route / from CentOS or RHEL 6 Linux server?

zeroconf (Zero configuration networking), is a techniques that automatically creates a usable Internet Protocol (IP) network without manual operator intervention or special configuration servers. route is part of zeroconf under RHEL 6 / CentOS 6 or older versions. To see current routing table, enter:
# route -n
Sample outputs:

Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
74.8x.4y.zz U     0      0        0 eth1 U     0      0        0 eth0     U     1002   0        0 eth0     U     1003   0        0 eth1       UG    0      0        0 eth0         74.8x.yy.zz         UG    0      0        0 eth1

Every time the server or Linux desktop boots, the zeroconf route is enabled and added to the kernel routing table. To disable zeroconf route under RHEL / CentOS / Fedora Linux, enter:
# vi /etc/sysconfig/network
Append the following directive:


Save and close the file. Reboot the system / server or restart the networking service:
# /etc/init.d/network restart
Verify routing table, enter:
# route -n
# ip route

🐧 Get the latest tutorials on Linux, Open Source & DevOps via RSS feed or Weekly email newsletter.

🐧 9 comments so far... add one

CategoryList of Unix and Linux commands
Disk space analyzersdf ncdu pydf
File Managementcat cp mkdir tree
FirewallAlpine Awall CentOS 8 OpenSUSE RHEL 8 Ubuntu 16.04 Ubuntu 18.04 Ubuntu 20.04
Network UtilitiesNetHogs dig host ip nmap
OpenVPNCentOS 7 CentOS 8 Debian 10 Debian 8/9 Ubuntu 18.04 Ubuntu 20.04
Package Managerapk apt
Processes Managementbg chroot cron disown fg jobs killall kill pidof pstree pwdx time
Searchinggrep whereis which
User Informationgroups id lastcomm last lid/libuser-lid logname members users whoami who w
WireGuard VPNAlpine CentOS 8 Debian 10 Firewall Ubuntu 20.04
9 comments… add one
  • Dougle Nov 10, 2011 @ 10:59

    What are the benefits of disabling this route?

    • Dan Nov 22, 2011 @ 14:43

      Ask yourself, conversely, what are the benefits of having that route?

      • CMac Oct 31, 2013 @ 18:53

        Thats not really an answer, the answer to this would be you defeat the possibility of having machines setup networks between each other in the absence of operator intervention.

        • Stefan Lasiewski Jan 30, 2014 @ 1:33

          I ask myself, what are the benefits of changing a default setting, especially when I have bigger fish to fry. If it ain’t broken, don’t fix it.

          • Michael Grivas May 4, 2017 @ 12:47

            … until something breaks and you are lost in a sea of “defaults” and “unknown configurations” !
            The best recipe for serious troubles.
            The reason we keep our place tidy, is to be able to get what we want when we want it. I have the feeling that you have not lived any troubleshooting nightmares, swearing at the people that prepared that stuff.
            I suppose, you never got a NFS mount not working just because of such a default route driving somewhere else.

  • Ridd1ck Nov 18, 2011 @ 13:10

    How can i set the default gateway be in the last line of routing table?

    • Dan Nov 22, 2011 @ 14:47

      That is outside of the scope of this article.
      However, googling will show you that you edit /etc/sysconfig/network and add the keyword “gateway” like so:

      Replace with the default gateway you desire. After, just restart networking. (/etc/init.d/networking restart)

    • 🐧 nixCraft Dec 6, 2011 @ 8:01
  • Shivendra singh Nov 18, 2011 @ 13:35

    yes i want to red hed software.

Leave a Reply

Your email address will not be published.

Use HTML <pre>...</pre> for code samples. Still have questions? Post it on our forum