The route
command is included in the net-tools
package on CentOS and RHEL 7. To install the route
command, you can use the following steps:
net-tools
package:sudo yum install net-tools
This will install the route
command and other network tools, such as ifconfig
and netstat
.
route -n
This will print the routing table of your system, indicating that the route
command is installed and working correctly.