User Tools

Site Tools


route_command

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
route_command [2016/09/20 14:21] – [CentOS] walkeradminroute_command [2023/03/09 22:46] (current) walkeradmin
Line 1: Line 1:
-====== Route Command ======+====== Route Command (now ip route) ====== 
 +<color darkorange>2016 - updated Jun 2017</color>
 \\  \\ 
 +\\ 
 +---
 +The <color #ed1c24>route</color> command has now been replaced. The command was deprecated some time ago, but continued to be used. The replacement is part of the <color #ed1c24>IP</color> command set.
 +\\ 
 +\\ 
 +Pre CentOS 7 you can still use route, but as of v7 the IP command should be used.
 +\\ 
 +\\ 
 +    ip route
 +    
 +    
 +    default via 192.168.27.254 dev enp4s0f0  proto static  metric 100
 +    10.0.0.0/8 dev ens513f0  proto kernel  scope link  src 10.0.222.2  metric 100
 +    11.0.0.0/8 dev ens513f2  proto kernel  scope link  src 11.0.222.4  metric 100
 +    192.168.27.0/24 dev enp4s0f0  proto kernel  scope link  src 192.168.27.222  metric 100
 +\\ 
 +\\ 
 +---
 \\  \\ 
 The <color red>route</color> command allows dynamic setting of a route from the command line, however using <color red>route</color> without any parameters will show the currently configured routes. The <color red>route</color> command allows dynamic setting of a route from the command line, however using <color red>route</color> without any parameters will show the currently configured routes.
Line 6: Line 25:
 \\  \\ 
 ==== Raspbian ==== ==== Raspbian ====
-\\  
 Raspbian Jessie on a Raspberry Pi 3 (LAN connected only, no wifi or bluetooth) Raspbian Jessie on a Raspberry Pi 3 (LAN connected only, no wifi or bluetooth)
 \\  \\ 
Line 17: Line 35:
 137.58.68.0                   255.255.252.0       202    0        0 eth0 137.58.68.0                   255.255.252.0       202    0        0 eth0
 </file> </file>
-Here we can see the default gateway is <color red>137.58.71.254</color>+Here we can see the default gateway is <color red>137.58.71.254</color> on <color red>eth0</color>
 \\  \\ 
-==== CentOS ==== 
 \\  \\ 
 +==== CentOS ====
 CentOS 6.6 on a server with 6 network interfaces (only eth0 is physically connected). CentOS 6.6 on a server with 6 network interfaces (only eth0 is physically connected).
 \\  \\ 
Line 41: Line 59:
 default         192.168.27.254  0.0.0.0         UG    0      0        0 eth0 default         192.168.27.254  0.0.0.0         UG    0      0        0 eth0
 </file> </file>
-Here we can see the default gateway is <color red>192.168.27.254</color>+Here we can see the default gateway is <color red>192.168.27.254</color> on <color red>eth0</color>
 \\  \\ 
 \\  \\ 
 +testing...
route_command.1474377710.txt.gz · Last modified: 2023/03/09 22:35 (external edit)