<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">2015-06-06 21:03 GMT+03:00 Dario Lesca <span dir="ltr">&lt;<a href="mailto:d.lesca@solinos.it" target="_blank">d.lesca@solinos.it</a>&gt;</span>:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Il giorno sab, 06/06/2015 alle 07.01 -0400, Paul Cartwright ha scritto:<br>
&gt; On 06/06/2015 05:32 AM, Dario Lesca wrote:<br>
&gt; &gt; Into Fedora 22 workstation, it&#39;s possible to change temporarily via<br>
&gt; &gt; command line the default gateway, to test another gateway, when I<br>
&gt; &gt; have<br>
&gt; &gt; setup the network via DHCP?<br>
&gt; &gt;<br>
&gt; &gt; What is the best command line to use?<br>
&gt; &gt;<br>
&gt; &gt; Many thanks<br>
&gt; try :<br>
&gt; $ man route<br>
&gt;<br>
&gt; *DESCRIPTION<br>
&gt;        Route manipulates the kernel&#39;s IP routing tables.<br>
<br>
Thanks Paul, but in f22 the command &quot;ip r del default&quot; (or ip r rep)<br>
not work anymore if the NetworkManager is set to DHCP (see my previous message, Thu, 04 Jun 2015<br>
14:15:59)<br>
<br>
Some other suggest?<br>
<span><font color="#888888"><br></font></span></blockquote><div><br></div><div>Couple of possible solutions <br></div><div><br></div><div>1) Put ignore-auto-routes=true into connection file in /etc/NetworkManager/system-connections and restart connection/NM service. This should reject DHCP routes, and you can add routes manually as tmp solution. <br><br>2) nmcli con mod --temporary {interface} ipv4.never-default true<br></div><div>After that NM will not add default route to that int.<br><br></div><div>3) In good old days NM honored /etc/sysconfig/network-scripts/ifcfg-interface config, and &quot;DEFROUTE=no&quot; in right place meant no def route for that interface. But I am not sure if it works nowadays, I dont use NM. More no than yes with -NM enabled.<br></div><div><br></div><div>Be careful, don&#39;t mess your network by having fun with NetworkManager and D-Bus.<br></div><div><br></div></div></div></div>