Keith C. Perry on 31 May 2017 22:47:48 -0700


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

Re: [PLUG] Mint-18.1 NetworkManager issues


I just turn off NetworkManager (disable it).  In Ubuntu 16.04 you can still configure things via /etc/network/interfaces but I think you can also do it the systemd way (I haven't tried it in Ubuntu- only Arch... I prefer the Ubuntu way since it's cleaner).

NetworkManager tends to be a pain for anything other than a system where you are going to just grap your network configuration from a DHCP server.

Determining resolver...

I would use Wireshark to see what the network is really doing if I though the resolver was having some sort of performance issue.

Also, try turning off IPv6 unless you are actually using it :D

~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ 
Keith C. Perry, MS E.E. 
Owner, DAO Technologies LLC 
(O) +1.215.525.4165 x2033 
(M) +1.215.432.5167 
www.daotechnologies.com

----- Original Message -----
From: "JP Vossen" <jp@jpsdomain.org>
To: "Philadelphia Linux User's Group Discussion List" <plug@lists.phillylinux.org>
Sent: Thursday, June 1, 2017 12:07:17 AM
Subject: [PLUG] Mint-18.1 NetworkManager issues

I've built a brand new install Mint-18.1 (Ubuntu 16.04 LTS/systemd) VM 
under VBox for work.  I have 2 NICS, enp0s3 is the NAT to $WORK VPN via 
$WORK Windows laptop.  enp0s8 is bridged to my LAN, so I can do backups 
and LAN stuff.

NetworkManager *insists* on adding 2 default routes!!!  WTF!  I assume 
that's because both DHCP servers (VBox and real on LAN) pass out default 
routes, but it's just hugely stupid that it blindly puts in both.  Not 
only that, but it periodically puts them BACK after I fix it, presumably 
when DHCP leases renew.

I've added the following to both 
'/etc/NetworkManager/system-connections/enp0s?' but nothing has changed. 
  I did it via the GUI and I did not `sudo service network-manager 
reload` until just now, because assumed doing things via the GUI would 
work right.
     ignore-auto-routes=true
     never-default=true

I've Googled (well, StartPaged) and found nothing useful.  Can anyone 
tell me how to get NM to stop being so stupid?  I can hack it with a 
cron job or something, but that's just ugly and wrong.


Related, how the bleeping hell do you figure out what DNS servers it's 
using?  '/etc/resolv.conf' has the useless "nameserver 127.0.1.1" 
garbage, and since both DHCP servers serve up DNS, half the time the 
machine can't resolve stuff on the $WORK VPN since it's arbitrarily and 
unilaterally using LAN DNS servers at the moment. I think.  I have no 
real idea--because I can't figure out what the hell DNS it's using...

Wow, OK, I found that one but 98% of the answers I found were completely 
wrong either because they just are or because they answered totally 
different questions.  The actual answer was:
     nmcli dev show | grep 'DNS'

Which I might refine to:
     nmcli dev show | awk '/DNS/ {print $2}'
     nmcli dev show | awk '/DNS/ {print $2}' | sort -u -n -t. -k1,1 
-k2,2 -k3,3 -k4,4

I've hacked around THAT issue by putting hard-coded $WORK DNS into `sudo 
vi /etc/resolvconf/resolv.conf.d/head`, but that's ugly.  I tried adding 
them to the '/etc/NetworkManager/system-connections/enp0s?' files but 
that just ADDED more servers and didn't remove the ones I didn't want.


I'm getting ready to just nuke both resolveconf and NM and just do 
things the old fashioned way that is transparent and you know--actually 
works.  But I figured one last time to get the newfangled (opaque, 
overly complicated, overly monolithic crap that doesn't actually work 
right) to...work.

Hmmmm, (2015) Why you shouldn't hate and disable NetworkManager anymore
	https://www.hogarthuk.com/?q=node/8


As a side note, it had also somehow decided out thin air that having 
"autoconnect-priority=-999" for the critical and mandatory enp0s3 was a 
Good Idea.  It was not and I have deleted that.

Thanks in advance,
JP
--  -------------------------------------------------------------------
JP Vossen, CISSP | http://www.jpsdomain.org/ | http://bashcookbook.com/
___________________________________________________________________________
Philadelphia Linux Users Group         --        http://www.phillylinux.org
Announcements - http://lists.phillylinux.org/mailman/listinfo/plug-announce
General Discussion  --   http://lists.phillylinux.org/mailman/listinfo/plug
___________________________________________________________________________
Philadelphia Linux Users Group         --        http://www.phillylinux.org
Announcements - http://lists.phillylinux.org/mailman/listinfo/plug-announce
General Discussion  --   http://lists.phillylinux.org/mailman/listinfo/plug