[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: How to delete second default route

On 10/4/19, Johann Spies <johann.spies@gmail.com> wrote:
> This problem arised recently after an upgrade (running sid)
> How do I remove the first default route in this list?

I'd leave both in - that way things should Just Work if either of the
interfaces goes down.

The question then becomes which interface do I want to use when both are up?

ip -d route list
shows the routes, along with their metric (lower = more preferred)

If the interface that you want to use doesn't have the lowest metric
for the default route, change the metric on that interface to be lower
than the other metric.  Sorry - I don't know how to change the metric


> $ sudo ip route list
> default dev enp0s25 scope link
> default via dev wlo1 proto dhcp metric 600
> dev wlo1 scope link metric 1000
> dev enp0s25 proto kernel scope link src
> dev wlo1 proto kernel scope link src metric
> 600
> dev enp0s25 scope link
> dev enp0s25 scope link
> 08:39:45 js@kiekie2:~$ sudo ifconfig enp0s25 down
> Regards
> Johann

Reply to: