Re: NetworkManager behavior answers not found in docs



On Tue, 2018-11-06 at 12:23 +0100, Thomas HUMMEL wrote:
On 10/26/18 12:55 PM, Thomas HUMMEL wrote:
Generally, there are the device states "unmanaged" ->
"unavailable" ->
and "disconnected". For ethernet devices, a device is usually
"unavailable" because it has no carrier.

As a matter of fact, when no udev rules for NM_UNMANAGED, the
device is 
in the disconnected state.

As for the traces, here's what I've got :

Oct 26 12:44:04 xcat-myriad NetworkManager[606]: <debug> 
[1540550644.5859] ifcfg-rh: loading from file 
"/etc/sysconfig/network-scripts/ifcfg-eth0"...
Oct 26 12:44:04 xcat-myriad NetworkManager[606]: <debug> 
[1540550644.5861] settings-connection[0x7fbffc006890]: constructed 
(NMIfcfgConnection)
Oct 26 12:44:04 xcat-myriad NetworkManager[606]: <trace> 
[1540550644.5870] 
settings-connection[0x7fbffc006890,5fb06bd0-0bb0-7ffb-45f1-
d6edd65f3e03]: update 
settings-connection flags to visible (was none)
Oct 26 12:44:04 xcat-myriad NetworkManager[606]: <debug> 
[1540550644.5875] 
settings-connection[0x7fbffc006890,5fb06bd0-0bb0-7ffb-45f1-
d6edd65f3e03]: disposing 

Oct 26 12:44:04 xcat-myriad NetworkManager[606]: <trace> 
[1540550644.5878] 
settings-connection[0x7fbffc006890,5fb06bd0-0bb0-7ffb-45f1-
d6edd65f3e03]: update 
settings-connection flags to none (was visible)
Oct 26 12:44:04 xcat-myriad NetworkManager[606]: <trace> 
[1540550644.6729] platform-linux: event-notification:
RTM_NEWROUTE, 
flags 0, seq 1540550645: ignore
Oct 26 12:44:04 xcat-myriad NetworkManager[606]: <trace> 
[1540550644.6752] platform-linux: event-notification:
RTM_NEWROUTE, 
flags 0, seq 1540550645: ignore
Oct 26 12:44:04 xcat-myriad NetworkManager[606]: <trace> 
[1540550644.6771] platform-linux: event-notification:
RTM_NEWROUTE, 
flags 0, seq 1540550645: ignore
Oct 26 12:44:04 xcat-myriad NetworkManager[606]: <trace> 
[1540550644.6790] platform-linux: event-notification:
RTM_NEWROUTE, 
flags 0, seq 1540550645: ignore
Oct 26 12:44:04 xcat-myriad NetworkManager[606]: <trace> 
[1540550644.6809] platform-linux: event-notification:
RTM_NEWROUTE, 
flags 0, seq 1540550645: ignore
Oct 26 12:44:04 xcat-myriad NetworkManager[606]: <trace> 
[1540550644.6827] platform-linux: event-notification:
RTM_NEWROUTE, 
flags 0, seq 1540550645: ignore
Oct 26 12:44:04 xcat-myriad NetworkManager[606]: <trace> 
[1540550644.6845] platform-linux: event-notification:
RTM_NEWROUTE, 
flags 0, seq 1540550645: ignore
Oct 26 12:44:04 xcat-myriad NetworkManager[606]: <trace> 
[1540550644.6865] platform-linux: event-notification:
RTM_NEWROUTE, 
flags 0, seq 1540550645: ignore
Oct 26 12:44:04 xcat-myriad NetworkManager[606]: <trace> 
[1540550644.6883] platform-linux: event-notification:
RTM_NEWROUTE, 
flags 0, seq 1540550645: ignore
Oct 26 12:47:03 xcat-myriad NetworkManager[606]: <trace> 
[1540550823.0031] device[0x55a73f560c80] (eth1): sys-iface-state: 
external -> assume
Oct 26 12:47:03 xcat-myriad NetworkManager[606]: <debug> 
[1540550823.0033] device[0x55a73f560c80] (eth1): unmanaged: flags
set to 
[user-udev,!sleeping,!loopback,!platform-init,!user-explicit,!user-
settings=0x400/0x479/managed], 

Oct 26 12:47:03 xcat-myriad NetworkManager[606]: <info> 
[1540550823.0033] device (eth1): state change: unmanaged ->
unavailable 
(reason 'connection-assumed', sys-iface-state: 'assume')
Oct 26 12:47:03 xcat-myriad NetworkManager[606]: <debug> 
[1540550823.0034] platform-linux: sysctl: reading 
'/proc/sys/net/ipv6/conf/eth1/accept_ra': '1'
Oct 26 12:47:03 xcat-myriad NetworkManager[606]: <debug> 
[1540550823.0035] platform-linux: sysctl: reading 
'/proc/sys/net/ipv6/conf/eth1/accept_ra_defrtr': '1'
Oct 26 12:47:03 xcat-myriad NetworkManager[606]: <debug> 
[1540550823.0035] platform-linux: sysctl: reading 
'/proc/sys/net/ipv6/conf/eth1/accept_ra_pinfo': '1'
Oct 26 12:47:03 xcat-myriad NetworkManager[606]: <debug> 
[1540550823.0035] platform-linux: sysctl: reading 
'/proc/sys/net/ipv6/conf/eth1/accept_ra_rtr_pref': '1'
Oct 26 12:47:03 xcat-myriad NetworkManager[606]: <debug> 
[1540550823.0036] platform-linux: sysctl: reading 
'/proc/sys/net/ipv6/conf/eth1/forwarding': '0'
Oct 26 12:47:03 xcat-myriad NetworkManager[606]: <debug> 
[1540550823.0036] platform-linux: sysctl: reading 
'/proc/sys/net/ipv6/conf/eth1/disable_ipv6': '1'
Oct 26 12:47:03 xcat-myriad NetworkManager[606]: <debug> 
[1540550823.0036] platform-linux: sysctl: reading 
'/proc/sys/net/ipv6/conf/eth1/hop_limit': '64'
Oct 26 12:47:03 xcat-myriad NetworkManager[606]: <debug> 
[1540550823.0037] platform-linux: sysctl: reading 
'/proc/sys/net/ipv6/conf/eth1/use_tempaddr': '0'
Oct 26 12:47:03 xcat-myriad NetworkManager[606]: <debug> 
[1540550823.0039] device[0x55a73f560c80] (eth1): device not yet 
available for transition to DISCONNECTED
Oct 26 12:47:03 xcat-myriad NetworkManager[606]: <debug> 
[1540550823.0041] create NMAuditManager singleton (0x7fbffc00d0f0)
Oct 26 12:47:03 xcat-myriad NetworkManager[606]: <info> 
[1540550823.0042] audit: op="device-managed" arg="managed:1"
pid=1360 
uid=0 result="success"

corresponding to those actions :

# ip link show eth1
3: eth1: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode 
DEFAULT group default qlen 1000
     link/ether 00:50:56:8a:42:bf brd ff:ff:ff:ff:ff:ff
# nmcli -f GENERAL.NM-MANAGED device show eth1
GENERAL.NM-MANAGED:                     no
# nmcli -f GENERAL.STATE device show eth1
GENERAL.STATE:                          10 (unmanaged)
# nmcli device set eth1 managed yes
# nmcli -f GENERAL.NM-MANAGED device show eth1
GENERAL.NM-MANAGED:                     yes
# nmcli -f GENERAL.STATE device show eth1
GENERAL.STATE:                          20 (unavailable)

Hello,

thanks again for all the other info in this thread which permitted a 
quite better understanding of NetworkManager !

Regarding the last mystery above : I guess the trace is no
sufficient 
for you to explain anything ?
Again, what's weird is that the host is a VMWare VM with eth1 device 
'connected', so I don't see any reason why it would have no
carrier...


Hi,


sorry for the late reply.


You say "udev rules for NM_UNMANAGED" but there is:

   (eth1): unmanaged: flags set to [user-udev,!sleeping,!l

the "user-udev" tells you there is a udev rule for that.
The confusing part here is the double negative with "UNmanaged".

  "!sleeping" here means that it's not unmanage due to sleeping
  "user-udev" here means, it's unmanaged due to user-udev.



See also, /usr/lib/udev/rules.d/85-nm-unmanaged.rules which has:

# VMWare host networking. Out-of-tree driver that looks like an ordinary
# Ethernet. No parent device (lives in /virtual/), no support for
# ethtool to identify the driver. They have their own MAC prefix that
# can not be changed.
ATTR{address}=="00:50:56:*", ENV{INTERFACE}=="vmnet[0-9]*", ENV{NM_UNMANAGED}="1"


(note the MAC address). Hm, I am a bit suprised, because the interface name doesn't seem
to be ENV{INTERFACE}=="vmnet[0-9]*". Dunno what's going on there.

What gives

  udevadm test /sys/class/net/eth1

?


It would be interesting to see the entire logfile.


Best,
Thomas

Attachment: signature.asc
Description: This is a digitally signed message part



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