I'm moving to a new residence and will sadly need to switch to 4G(LTE) for a bit. I decided after much reading on this forum to go for the Huawei E8372H-320
which is an LTE dongle with built in WiFi and plug it in to my current router.
My setup
-
Linksys WRT3200ACM
runningOpenWrt 19.07.7 r11306-c4a6851c72 / LuCI openwrt-19.07 branch git-21.044.30835-34e0d65
-
Now new
Huawei E8372H-320
My goal
The plan was to use this dongle to get an external IP address from my ISP to my WRT3200ACM
.
My "research"
To get external IP I need to put the dongle in "Stick Mode" or NCM/NDIS mode to get high speeds (LTE). This openwrt wiki shows how to do this, although I'm not sure if the information is outdated as this thread describes a much different way.
My current problem and debugging
I knew this was going to have its challenges and might require asking here on the forum. Unfortunately I got stuck quite fast. Please correct me if I got any of my facts wrong.
Following the mentioned ncm setup wiki I started with installing the packages, rebooting my router and connecting the dongle. Upon running ls -l /dev/cdc-wdm0
I get an error that there is no such file or directory
root@OpenWrt:~# ls -l /dev/cdc-wdm0
ls: /dev/cdc-wdm0: No such file or directory
I then took a look at dmesg
which shows the following output.
[ 5566.163126] usb 2-1: USB disconnect, device number 64
[ 5566.662449] usb 2-1: new high-speed USB device number 65 using xhci-hcd
[ 5569.174921] usb 2-1: USB disconnect, device number 65
[ 5569.673455] usb 2-1: new high-speed USB device number 66 using xhci-hcd
[ 5569.865318] usb-storage 2-1:1.0: USB Mass Storage device detected
[ 5569.871839] scsi host2: usb-storage 2-1:1.0
[ 5569.914336] usb 2-1: USB disconnect, device number 66
[ 5570.413703] usb 2-1: new high-speed USB device number 67 using xhci-hcd
[ 5572.926131] usb 2-1: USB disconnect, device number 67
[ 5573.424704] usb 2-1: new high-speed USB device number 68 using xhci-hcd
[ 5573.606190] usb-storage 2-1:1.0: USB Mass Storage device detected
[ 5573.617287] scsi host2: usb-storage 2-1:1.0
[ 5573.655666] usb 2-1: USB disconnect, device number 68
[ 5574.154946] usb 2-1: new high-speed USB device number 69 using xhci-hcd
This goes on forever in a loop with the device number running up to 127 before going around.
When running usbmode -l
I get different output where the device sometimes shows up, but for the most part is is abcent.
root@OpenWrt:~# usbmode -l
root@OpenWrt:~# usbmode -l
root@OpenWrt:~# usbmode -l
root@OpenWrt:~# usbmode -l
root@OpenWrt:~# usbmode -l
root@OpenWrt:~# usbmode -l
Found device: 12d1:1f01 (Manufacturer: "HUAWEI_MOBILE", Product: "HUAWEI_MOBILE", Serial: "0123456789ABCDEF")
root@OpenWrt:~# usbmode -l
I now thought that USB power may be the problem so I plugged the dongle to a powered USB HUB. This made no difference at all. I tried to use another powered USB HUB with the same result. Worth mentioning is that these two HUB's both work without the external power supply if that can change things in any way. I also tried both hubs connected to a laptop and it worked good.
Worth noticing is that this dongle has its own WiFi
and this works without interruption to connect to from other devices (tested with bandwidth tests and continues ping, it is stable). This is the case for when the dongle is connected directly to any of the routers USB
ports (USB2 and USB3) or via any of the USB HUB's. At this point I'm thinking that this is not a power issue at all. (I also tried turning WiFi off on the dongle if that pulled the extra juice).
I then installed and ran lsusb
which showed something interesting. The result here is also different every time but with the difference that there is always a device present. This I hope can shed some light into what is going on. It would seem that the dongle is switching modes back and forth.
root@OpenWrt:~# lsusb
Bus 002 Device 110: ID 12d1:1f01 Huawei Technologies Co., Ltd. E353/E3131 (Mass storage mode)
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
root@OpenWrt:~# lsusb
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 111: ID 12d1:14db Huawei Technologies Co., Ltd. E353/E3131
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Here is the output from lsusb -v
just in case for the two detected devices.
Bus 002 Device 109: ID 12d1:14db Huawei Technologies Co., Ltd. E353/E3131
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 2.00
bDeviceClass 2 Communications
bDeviceSubClass 0
bDeviceProtocol 0
bMaxPacketSize0 64
idVendor 0x12d1 Huawei Technologies Co., Ltd.
idProduct 0x14db E353/E3131
bcdDevice 1.02
iManufacturer 1 HUAWEI_MOBILE
iProduct 2 HUAWEI_MOBILE
iSerial 0
bNumConfigurations 1
Configuration Descriptor:
bLength 9
bDescriptorType 2
wTotalLength 88
bNumInterfaces 2
bConfigurationValue 1
iConfiguration 0
bmAttributes 0x80
(Bus Powered)
MaxPower 2mA
Interface Association:
bLength 8
bDescriptorType 11
bFirstInterface 0
bInterfaceCount 2
bFunctionClass 2 Communications
bFunctionSubClass 6 Ethernet Networking
bFunctionProtocol 0
iFunction 8 CDC ECM
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 0
bNumEndpoints 1
bInterfaceClass 2 Communications
bInterfaceSubClass 6 Ethernet Networking
bInterfaceProtocol 0
iInterface 5 CDC Ethernet Control Model (ECM)
CDC Header:
bcdCDC 1.10
CDC Union:
bMasterInterface 0
bSlaveInterface 1
CDC Ethernet:
iMacAddress 7 001E101F0000
bmEthernetStatistics 0x00000000
wMaxSegmentSize 1514
wNumberMCFilters 0x0000
bNumberPowerFilters 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x83 EP 3 IN
bmAttributes 3
Transfer Type Interrupt
Synch Type None
Usage Type Data
wMaxPacketSize 0x0010 1x 16 bytes
bInterval 5
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 1
bAlternateSetting 0
bNumEndpoints 0
bInterfaceClass 10 CDC Data
bInterfaceSubClass 0 Unused
bInterfaceProtocol 0
iInterface 0
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 1
bAlternateSetting 1
bNumEndpoints 2
bInterfaceClass 10 CDC Data
bInterfaceSubClass 0 Unused
bInterfaceProtocol 0
iInterface 6 CDC Ethernet Data
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x82 EP 2 IN
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0200 1x 512 bytes
bInterval 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x02 EP 2 OUT
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0200 1x 512 bytes
bInterval 0
Bus 002 Device 072: ID 12d1:1f01 Huawei Technologies Co., Ltd. E353/E3131 (Mass storage mode)
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 2.00
bDeviceClass 0 (Defined at Interface level)
bDeviceSubClass 0
bDeviceProtocol 0
bMaxPacketSize0 64
idVendor 0x12d1 Huawei Technologies Co., Ltd.
idProduct 0x1f01 E353/E3131 (Mass storage mode)
bcdDevice 1.02
iManufacturer 1 HUAWEI_MOBILE
iProduct 2 HUAWEI_MOBILE
iSerial 3 0123456789ABCDEF
bNumConfigurations 1
Configuration Descriptor:
bLength 9
bDescriptorType 2
wTotalLength 32
bNumInterfaces 1
bConfigurationValue 1
iConfiguration 0
bmAttributes 0x80
(Bus Powered)
MaxPower 2mA
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 0
bNumEndpoints 2
bInterfaceClass 8 Mass Storage
bInterfaceSubClass 6 SCSI
bInterfaceProtocol 80 Bulk-Only
iInterface 4 Mass Storage
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x81 EP 1 IN
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0200 1x 512 bytes
bInterval 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x01 EP 1 OUT
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0200 1x 512 bytes
bInterval
One question that remains is if I need to try to switch mode on the device for it to stop doing this. In this also previusly mentioned thread they discuss running either a command or editing a file /etc/usb-mode.json
to flip this dongle to stick mode. The 8372H
from what I've read does not store this setting permanently but it needs to be done every boot.
The discussed command:
usb_modeswitch -v 12d1 -p 1f01 -M 55534243123456780000000000000011063000000000010000000000000000
Although I've had to change usb_modeswitch
for usbmode
to make it run. It did not stop the device from behaving the way it does.
Lastly here is a list of my installed usb
and kmod
packages in case they can cause trouble.
root@OpenWrt:~# opkg list | grep usb
kmod-usb-core - 4.14.221-1
kmod-usb-ehci - 4.14.221-1
kmod-usb-net - 4.14.221-1
kmod-usb-net-cdc-ncm - 4.14.221-1
kmod-usb-net-huawei-cdc-ncm - 4.14.221-1
kmod-usb-net-qmi-wwan - 4.14.221-1
kmod-usb-serial - 4.14.221-1
kmod-usb-serial-option - 4.14.221-1
kmod-usb-serial-wwan - 4.14.221-1
kmod-usb-storage - 4.14.221-1
kmod-usb-uhci - 4.14.221-1
kmod-usb-wdm - 4.14.221-1
kmod-usb2 - 4.14.221-1
libusb-1.0-0 - 1.0.22-2
usb-modeswitch - 2017-12-19-f40f84c2-2
usbutils - 007-10
root@OpenWrt:~# opkg list | grep kmod
kmod-bluetooth - 4.14.221-1
kmod-btmrvl - 4.14.221-1
kmod-cfg80211 - 4.14.221+4.19.161-1-1
kmod-crypto-aead - 4.14.221-1
kmod-crypto-cmac - 4.14.221-1
kmod-crypto-ecb - 4.14.221-1
kmod-crypto-ecdh - 4.14.221-1
kmod-crypto-hash - 4.14.221-1
kmod-crypto-kpp - 4.14.221-1
kmod-crypto-manager - 4.14.221-1
kmod-crypto-null - 4.14.221-1
kmod-crypto-pcompress - 4.14.221-1
kmod-gpio-button-hotplug - 4.14.221-3
kmod-hid - 4.14.221-1
kmod-input-core - 4.14.221-1
kmod-input-evdev - 4.14.221-1
kmod-ip6tables - 4.14.221-1
kmod-ipt-conntrack - 4.14.221-1
kmod-ipt-core - 4.14.221-1
kmod-ipt-nat - 4.14.221-1
kmod-ipt-offload - 4.14.221-1
kmod-lib-crc-ccitt - 4.14.221-1
kmod-lib-crc16 - 4.14.221-1
kmod-mac80211 - 4.14.221+4.19.161-1-1
kmod-mii - 4.14.221-1
kmod-mmc - 4.14.221-1
kmod-mwifiex-sdio - 4.14.221+4.19.161-1-1
kmod-mwlwifi - 4.14.221+2019-03-02-31d93860-1
kmod-nf-conntrack - 4.14.221-1
kmod-nf-conntrack6 - 4.14.221-1
kmod-nf-flow - 4.14.221-1
kmod-nf-ipt - 4.14.221-1
kmod-nf-ipt6 - 4.14.221-1
kmod-nf-nat - 4.14.221-1
kmod-nf-reject - 4.14.221-1
kmod-nf-reject6 - 4.14.221-1
kmod-nls-base - 4.14.221-1
kmod-ppp - 4.14.221-1
kmod-pppoe - 4.14.221-1
kmod-pppox - 4.14.221-1
kmod-regmap-core - 4.14.221-1
kmod-scsi-core - 4.14.221-1
kmod-slhc - 4.14.221-1
kmod-usb-core - 4.14.221-1
kmod-usb-ehci - 4.14.221-1
kmod-usb-net - 4.14.221-1
kmod-usb-net-cdc-ncm - 4.14.221-1
kmod-usb-net-huawei-cdc-ncm - 4.14.221-1
kmod-usb-net-qmi-wwan - 4.14.221-1
kmod-usb-serial - 4.14.221-1
kmod-usb-serial-option - 4.14.221-1
kmod-usb-serial-wwan - 4.14.221-1
kmod-usb-storage - 4.14.221-1
kmod-usb-uhci - 4.14.221-1
kmod-usb-wdm - 4.14.221-1
kmod-usb2 - 4.14.221-1
root@OpenWrt:~# opkg list | grep luci-proto
luci-proto-3g - git-21.189.23240-7b931da-1
luci-proto-ipv6 - git-21.044.30835-34e0d65-1
luci-proto-ncm - git-21.189.23240-7b931da-1
luci-proto-ppp - git-21.044.30835-34e0d65-1
luci-proto-qmi - git-21.189.23240-7b931da-1
EDIT
I just ran into this thread from 13d ago. The router in question is running pfSense but it is the exact same Huawei E8372H-320
dongle and issue. No solution found in that thread so far.