3

Setup:

Raspberry Pi, type B, running with Arch Linux 3.18.5-3-ARCH #1 PREEMT, connected to a local ethernet switch by the standard ethernet port, no wifi set up or used. A static configuration according to /etc/netctl/examples/ethernet-static is set up for eth0 and dhcpcd not running. After reboot eth0 is coming up just fine and connection to LAN is established. Other than that a flash drive and a FTDI RS-485 converter are attached to the USB ports.

Problems:

Every now and then USB disconnects (which could be contributed to power glitches - according to the forum at raspberrypi.org - but that is not certain). All USB devices come back after re-enumeration but eth0 does not. Journals tell us:

kernel: usb 1-1.1: USB disconnect, device number 3
kernel: smsc95xx 1-1.1:1.0 eth0: unregister 'smsc95xx' usb-bcm2708_usb-1.1, smsc95xx USB 2.0 Ethernet
kernel: smsc95xx 1-1.1:1.0 eth0: hardware isn't capable of remote wakeup
kernel: usb 1-1.2: USB disconnect, device number 4
kernel: ftdi_sio ttyUSB0: usb_serial_generic_submit_read_urb - usb_submit_urb failed: -19
kernel: ftdi_sio ttyUSB0: usb_serial_generic_submit_read_urb - usb_submit_urb failed: -19
kernel: ftdi_sio ttyUSB0: error from flowcontrol urb
kernel: ftdi_sio ttyUSB0: FTDI USB Serial Device converter now disconnected from ttyUSB0
kernel: ftdi_sio 1-1.2:1.0: device disconnected
kernel: usb 1-1.3: USB disconnect, device number 5
kernel: Indeed it is in host mode hprt0 = 00001101
avahi-daemon[183]: Interface eth0.IPv4 no longer relevant for mDNS.
avahi-daemon[183]: Leaving mDNS multicast group on interface eth0.IPv4 with address 192.168.1.3.
avahi-daemon[183]: IP_DROP_MEMBERSHIP failed: No such device
avahi-daemon[183]: Withdrawing address record for 192.168.1.3 on eth0.
avahi-daemon[183]: Withdrawing workstation service for eth0.
systemd[1]: Stopping A basic static ethernet connection...
systemd-udevd[118]: error opening USB device 'descriptors' file
systemd-udevd[118]: error opening USB device 'descriptors' file
kernel: usb 1-1: reset high-speed USB device number 2 using dwc_otg
kernel: Indeed it is in host mode hprt0 = 00001101
systemd-udevd[118]: error opening USB device 'descriptors' file
network[3794]: Stopping network profile 'eth0'...
kernel: usb 1-1.1: new high-speed USB device number 6 using dwc_otg
kernel: usb 1-1.1: New USB device found, idVendor=0424, idProduct=ec00
kernel: usb 1-1.1: new high-speed USB device number 6 using dwc_otg
kernel: usb 1-1.1: New USB device found, idVendor=0424, idProduct=ec00
kernel: usb 1-1.1: New USB device strings: Mfr=0, Product=0, SerialNumber=0
kernel: smsc95xx v1.0.4
kernel: smsc95xx 1-1.1:1.0 eth0: register 'smsc95xx' at usb-bcm2708_usb-1.1, smsc95xx USB 2.0 Ethernet, b8:27:eb:5e:b4:db
kernel: usb 1-1.2: new full-speed USB device number 7 using dwc_otg
kernel: usb 1-1.2: New USB device found, idVendor=0403, idProduct=6001
kernel: usb 1-1.2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
kernel: usb 1-1.2: Product: FT232R USB UART
kernel: usb 1-1.2: Manufacturer: FTDI
kernel: usb 1-1.2: SerialNumber: A901IUQV
kernel: ftdi_sio 1-1.2:1.0: FTDI USB Serial Device converter detected
kernel: usb 1-1.2: Detected FT232RL
kernel: usb 1-1.2: FTDI USB Serial Device converter now attached to ttyUSB0
kernel: usb 1-1.3: new high-speed USB device number 8 using dwc_otg
kernel: usb 1-1.3: New USB device found, idVendor=058f, idProduct=6387
kernel: usb 1-1.3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
network[3794]: Stopped network profile 'eth0'
kernel: usb 1-1.3: Product: Mass Storage
systemd[1]: Stopped A basic static ethernet connection.
kernel: usb 1-1.3: Manufacturer: Generic
kernel: usb 1-1.3: SerialNumber: D349116D
kernel: usb-storage 1-1.3:1.0: USB Mass Storage device detected
kernel: scsi host1: usb-storage 1-1.3:1.0
kernel: scsi 1:0:0:0: Direct-Access     Generic  Flash Disk       8.07 PQ: 0 ANSI: 4
kernel: sd 1:0:0:0: [sda] 1966080 512-byte logical blocks: (1.00 GB/960 MiB)
kernel: sd 1:0:0:0: [sda] Write Protect is off
kernel: sd 1:0:0:0: [sda] Mode Sense: 23 00 00 00
kernel: sd 1:0:0:0: [sda] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA
kernel:  sda: sda1
kernel: sd 1:0:0:0: [sda] Attached SCSI removable disk

Questions:

  1. What's the root cause of the USB disconnect and how to circumvent or prevent it?
  2. Why is eth0 not coming up again and what to do about it?
  • 1
    Are you sure eth0 doesn't come back, or just that the interface is down afterward? It won't show up with, e.g., ifconfig then, unless you use -a. ip link also should show it. Problems with the ethernet due to power fluctuations on the USB seem common: elinux.org/… – goldilocks Mar 2 '15 at 9:44
  • 1
    It's a little hard to tell as I cannot connect to the Pi once connection is lost (remote location, no local access)... Will have to setup some script to check this on-site automatically. – Ghanima Mar 2 '15 at 10:29
  • 1
    I'm not a NetworkManager user but I'd guess once the interface is down, it presumes this was done on purpose -- it may or may not respond to putting it back up again (ip link set eth0 up), but there's nothing/no one to do that. I think generally this is a state that's considered intentional, the hardware glitch is a complication. – goldilocks Mar 2 '15 at 10:42
1

Netctl profiles are not hot pluggable by default, they are started at boot for any interface that is connected, but if one is connected (or disconnects and reconnects) it does not bring up the profile (or restart it).

To make them hot pluggable you need to install ifplugd and start/enable the netctl-ifplugd@eth0.service service and disable the existing profile from starting at boot. Ifplugd should restart the profile when the usb device comes back up. More info here.

  • I have started netctl-ifplugd@eth0.service but when I disconnect/reconnect my usb interface, the service dies. – Babken Vardanyan Aug 11 '17 at 5:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.