Re: usb0 unmanaged (g_ether)



Hi Thomas,


As you said, there is an udev rule setting USB gadget devices as
unmanaged (85-nm-unmanaged.rules):

# USB gadget device. Unmanage by default, since whatever created it
# might want to set it up itself (e.g. activate an ipv4.method=shared
# connection).
ENV{DEVTYPE}=="gadget", ENV{NM_UNMANAGED}="1"


`$ nmcli device set usb0 managed yes` works, the device is then shown as
unavailable (connection-assumed):

DEVICE  TYPE      STATE        CONNECTION
eth0    ethernet  connected    Ethernet  
usb0    ethernet  unavailable  --        
sit0    iptunnel  unmanaged    --        
lo      loopback  unmanaged    --     

Jan 18 08:48:13 D130102 NetworkManager[2237]: <debug> [1516265293.1481]
device[0x736758] (usb0): unmanaged: flags set to
[user-udev,!sleeping,!loopback,!platform-init,!user-explicit,!user-settings=0x400/0x479/managed,
set-managed [user-explicit=0x20], reason connection-assumed,
transition-state)
Jan 18 08:48:13 D130102 NetworkManager[2237]: <info>  [1516265293.1485]
device (usb0): state change: unmanaged -> unavailable (reason
'connection-assumed') [10 20 41]
Jan 18 08:48:13 D130102 NetworkManager[2237]: <debug> [1516265293.1575]
platform-linux: sysctl: reading
'/proc/sys/net/ipv6/conf/usb0/accept_ra': '1'
Jan 18 08:48:13 D130102 NetworkManager[2237]: <debug> [1516265293.1583]
platform-linux: sysctl: reading
'/proc/sys/net/ipv6/conf/usb0/accept_ra_defrtr': '1'
Jan 18 08:48:13 D130102 NetworkManager[2237]: <debug> [1516265293.1589]
platform-linux: sysctl: reading
'/proc/sys/net/ipv6/conf/usb0/accept_ra_pinfo': '1'
Jan 18 08:48:13 D130102 NetworkManager[2237]: <debug> [1516265293.1595]
platform-linux: error reading
/proc/sys/net/ipv6/conf/usb0/accept_ra_rtr_pref: Failed to open file
"/proc/sys/net/ipv6/conf/usb0/accept_ra_rtr_pref": No such file or directory
Jan 18 08:48:13 D130102 NetworkManager[2237]: <debug> [1516265293.1601]
platform-linux: sysctl: reading
'/proc/sys/net/ipv6/conf/usb0/forwarding': '0'
Jan 18 08:48:13 D130102 NetworkManager[2237]: <debug> [1516265293.1608]
platform-linux: sysctl: reading
'/proc/sys/net/ipv6/conf/usb0/disable_ipv6': '0'
Jan 18 08:48:13 D130102 NetworkManager[2237]: <debug> [1516265293.1615]
platform-linux: sysctl: reading
'/proc/sys/net/ipv6/conf/usb0/hop_limit': '64'
Jan 18 08:48:13 D130102 NetworkManager[2237]: <debug> [1516265293.1621]
platform-linux: sysctl: reading
'/proc/sys/net/ipv6/conf/usb0/use_tempaddr': '0'
Jan 18 08:48:13 D130102 NetworkManager[2237]: <debug> [1516265293.1892]
device[0x736758] (usb0): device not yet available for transition to
DISCONNECTED


But I still cannot connect my profile UsbHost over usb0:

$ nmcli c up UsbHost ifname usb0
Error: Connection activation failed: Connection 'UsbHost' is not
available on the device usb0 at this time.


The NM output is:

Jan 18 08:52:23 D130102 NetworkManager[2237]: <debug> [1516265543.2281]
active-connection[0x6f5470]: set device "usb0" [0x736758]
Jan 18 08:52:23 D130102 NetworkManager[2237]: <debug> [1516265543.2286]
device[0x736758] (usb0): add_pending_action (1): 'activation-0x6f5470'
Jan 18 08:52:23 D130102 NetworkManager[2237]: <info>  [1516265543.2851]
audit: op="connection-activate"
uuid="66d1285e-9905-4991-99c8-25fa3b3aa08a" name="UsbHost" pid=2392
uid=0 result="fail" reason="Connection 'UsbHost' is not available on the
device usb0 at this time."
Jan 18 08:52:23 D130102 NetworkManager[2237]: <debug> [1516265543.2863]
manager: Failed to activate 'UsbHost': Connection 'UsbHost' is not
available on the device usb0 at this time.
Jan 18 08:52:23 D130102 NetworkManager[2237]: <debug> [1516265543.2875]
device[0x736758] (usb0): remove_pending_action (0): 'activation-0x6f5470'


The UsbHost connection:

connection.id:                          UsbHost
connection.uuid:                        66d1285e-9905-4991-99c8-25fa3b3aa08a
connection.stable-id:                   --
connection.interface-name:              --
connection.type:                        802-3-ethernet
connection.autoconnect:                 yes
connection.autoconnect-priority:        0
connection.autoconnect-retries:         -1 (default)
connection.timestamp:                   1516190131
connection.read-only:                   no
connection.permissions:                
connection.zone:                        --
connection.master:                      --
connection.slave-type:                  --
connection.autoconnect-slaves:          -1 (default)
connection.secondaries:                
connection.gateway-ping-timeout:        0
connection.metered:                     unknown
connection.lldp:                        -1 (default)
802-3-ethernet.port:                    --
802-3-ethernet.speed:                   0
802-3-ethernet.duplex:                  --
802-3-ethernet.auto-negotiate:          no
802-3-ethernet.mac-address:             8E:8E:76:28:44:AB
802-3-ethernet.cloned-mac-address:      --
802-3-ethernet.generate-mac-address-mask:--
802-3-ethernet.mac-address-blacklist:  
802-3-ethernet.mtu:                     auto
802-3-ethernet.s390-subchannels:       
802-3-ethernet.s390-nettype:            --
802-3-ethernet.s390-options:           
802-3-ethernet.wake-on-lan:             1 (default)
802-3-ethernet.wake-on-lan-password:    --
ipv4.method:                            link-local
ipv4.dns:                              
ipv4.dns-search:                       
ipv4.dns-options:                       (default)
ipv4.dns-priority:                      0
ipv4.addresses:                        
ipv4.gateway:                           --
ipv4.routes:                           
ipv4.route-metric:                      -1
ipv4.ignore-auto-routes:                no
ipv4.ignore-auto-dns:                   no
ipv4.dhcp-client-id:                    --
ipv4.dhcp-timeout:                      0
ipv4.dhcp-send-hostname:                yes
ipv4.dhcp-hostname:                     --
ipv4.dhcp-fqdn:                         --
ipv4.never-default:                     no
ipv4.may-fail:                          yes
ipv4.dad-timeout:                       -1 (default)
ipv6.method:                            ignore
ipv6.dns:                              
ipv6.dns-search:                       
ipv6.dns-options:                       (default)
ipv6.dns-priority:                      0
ipv6.addresses:                        
ipv6.gateway:                           --
ipv6.routes:                           
ipv6.route-metric:                      -1
ipv6.ignore-auto-routes:                no
ipv6.ignore-auto-dns:                   no
ipv6.never-default:                     no
ipv6.may-fail:                          yes
ipv6.ip6-privacy:                       -1 (unknown)
ipv6.addr-gen-mode:                     eui64
ipv6.dhcp-send-hostname:                yes
ipv6.dhcp-hostname:                     --
ipv6.token:                             --
proxy.method:                           none
proxy.browser-only:                     no
proxy.pac-url:                          --
proxy.pac-script:                       --


And the usb0 device:

GENERAL.DEVICE:                         usb0
GENERAL.TYPE:                           ethernet
GENERAL.NM-TYPE:                        NMDeviceEthernet
GENERAL.VENDOR:                        
GENERAL.PRODUCT:                       
GENERAL.DRIVER:                         at91_udc
GENERAL.DRIVER-VERSION:                 29-May-2008
GENERAL.FIRMWARE-VERSION:               at91_udc
GENERAL.HWADDR:                         8E:8E:76:28:44:AB
GENERAL.MTU:                            1500
GENERAL.STATE:                          20 (unavailable)
GENERAL.REASON:                         41 (The device's existing
connection was assumed)
GENERAL.UDI:                            /virtual/device/placeholder/3
GENERAL.IP-IFACE:                       --
GENERAL.IS-SOFTWARE:                    no
GENERAL.NM-MANAGED:                     yes
GENERAL.AUTOCONNECT:                    yes
GENERAL.FIRMWARE-MISSING:               no
GENERAL.NM-PLUGIN-MISSING:              no
GENERAL.PHYS-PORT-ID:                   --
GENERAL.CONNECTION:                     --
GENERAL.CON-UUID:                       --
GENERAL.CON-PATH:                       --
GENERAL.METERED:                        unknown
CAPABILITIES.CARRIER-DETECT:            yes
CAPABILITIES.SPEED:                     unknown
CAPABILITIES.IS-SOFTWARE:               no
WIRED-PROPERTIES.CARRIER:               off
CONNECTIONS.AVAILABLE-CONNECTION-PATHS:

Do you have an idea, what could be the problem?

Thanks,
Ana


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