f22: how to change default gateway via line command

Rick Stevens ricks at alldigital.com
Thu Jun 11 20:27:12 UTC 2015


On 06/11/2015 01:18 PM, Dario Lesca wrote:
> Il giorno gio, 11/06/2015 alle 10.00 -0700, Rick Stevens ha scritto:
>> Not sure about this, but you could try the "Automatic (DHCP)" option
>> under the IPV4 settings, then click "Routes..." and add a route with
>> address 0.0.0.0, netmask 0.0.0.0, gateway of your choosing and a
>> metric of 1. Also make sure the "Ignore automatically obtained
>> routes" checkbox is ticked. I believe that now becomes your default
>> gateway.
>
> I have try this approach, but do not work.
> If I put the IP 0.0.0.0 or NM 0.0.0.0 the Apply button is disable.
> Whether if I use gnome config panel or nm-connection-editor.
>
> It seems strange, but both of these panels do not provide the
> possibility of combining DHCP + DNS and a specific GW

Try using the "Automatic (DHCP) Address Only" option. I've never done
it, but it may work. Keep in mind that you're using DHCP, 95% of the
time you WANT an IP, gateway and DNS servers.

You're trying to do something that NM really wasn't designed to do. If
you're doing this sort of experiment, then turn NM off and configure
the stuff manually or use the old-school networking stuff (bugger up
the stuff in /etc/sysconfig/networking and "systemctl stop
NetworkManger;systemctl start networking").
----------------------------------------------------------------------
- Rick Stevens, Systems Engineer, AllDigital    ricks at alldigital.com -
- AIM/Skype: therps2        ICQ: 226437340           Yahoo: origrps2 -
-                                                                    -
-      Do you know how to save five drowning lawyers?  No?  GOOD!    -
----------------------------------------------------------------------


More information about the users mailing list