I'm trying to get USB tethering to work between a Nexus 5 phone (running CM11) and my desktop running Debian 8. I connected the phone to the computer via USB and got these messages:
[14972.580738] usb 3-2: new high-speed USB device number 6 using xhci_hcd [14972.709236] usb 3-2: New USB device found, idVendor=18d1, idProduct=4ee3 [14972.709239] usb 3-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3 [14972.709240] usb 3-2: Product: Nexus 5 [14972.709242] usb 3-2: Manufacturer: LGE [14972.709243] usb 3-2: SerialNumber: 04a0ba5813aff0d4
After enabling USB tethering on the phone, I additionally get:
[14972.710663] rndis_host 3-2:1.0 usb0: register 'rndis_host' at usb-0000:00:14.0-2, RNDIS device, 02:04:67:3f:31:35
The device is also listed by
lsusb, albeit as a Nexus 4:
Bus 003 Device 006: ID 18d1:4ee3 Google Inc. Nexus 4 (tether)
(Is that a problem?)
I do not, however, get a usb0 network interface or anything else that could be it.
ifconfig lists only the previously present interfaces, which are
lo, as well as two
tun devices provided by OpenVPN.
I searched for possible reasons this doesn't work, but they revolve around a too-old kernel (from the 2.6 days). My kernel is 3.16.0, which I would assume supports USB tethering. I also remember that I got USB tethering to work with a Sony Ericsson phone by just connecting it, and that was years ago.
As far as I can tell, all the relevant kernel modules are loaded:
rndis_host 12698 0 cdc_ether 12564 1 rndis_host usbnet 30844 2 rndis_host,cdc_ether usbcore 195340 8 xpad,rndis_host,ehci_hcd,ehci_pci,usbhid,usbnet,xhci_hcd,cdc_ether usb_common 12440 1 usbcore
What do I have to do to get the usb0 network interface?
Update: I tried this on another computer running Debian 8, and it worked. As far as I can tell, the difference is that two other modules are loaded:
mii. However, though loading these modules manually via
modprobe seems to work without errors,
usb0 is still missing.
After some googling I found that I should get information about network interfaces using
ip link. The output is:
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT group default link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP mode DEFAULT group default qlen 1000 link/ether 30:85:a9:f6:24:cd brd ff:ff:ff:ff:ff:ff 31: tun1: <POINTOPOINT,MULTICAST,NOARP,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UNKNOWN mode DEFAULT group default qlen 100 link/none 32: tun0: <POINTOPOINT,MULTICAST,NOARP,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UNKNOWN mode DEFAULT group default qlen 100 link/none 37: usb0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT group default qlen 1000 link/ether 0e:21:59:43:d3:ca brd ff:ff:ff:ff:ff:ff
So it appears that
usb0 does exist after all. I then tried
ifup usb0, but it says
Ignoring unknown interface usb0=usb0.
I did the whole thing also with a Nexus 7 (1st gen), with the same results.