在 linux debian 中,如何从路由中删除默认网关
in linux debian, how to cut the default gateway from route
我正在尝试从路由中删除默认网关
route | grep UG |cut -f 2 -d ' '
但是我收到一条空行...
路由的正常输出是
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
default 10.0.2.2 0.0.0.0 UG 1024 0 0 eth0
10.0.2.0 * 255.255.255.0 U 0 0 0 eth0
link-local * 255.255.0.0 U 1000 0 0 eth0
请帮帮我...
谢谢
route -n | grep '^0.0.0' | awk '{print }'
我正在尝试从路由中删除默认网关
route | grep UG |cut -f 2 -d ' '
但是我收到一条空行...
路由的正常输出是
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
default 10.0.2.2 0.0.0.0 UG 1024 0 0 eth0
10.0.2.0 * 255.255.255.0 U 0 0 0 eth0
link-local * 255.255.0.0 U 1000 0 0 eth0
请帮帮我... 谢谢
route -n | grep '^0.0.0' | awk '{print }'