네트워크 관리자 대신 모뎀 관리자를 사용하여 인터넷에 액세스하는 방법

네트워크 관리자 대신 모뎀 관리자를 사용하여 인터넷에 액세스하는 방법

최근에 타타 도코모 동글을 구입했습니다.

삽입한 후 다음과 같은 세부 정보를 얻었습니다.

Aug 05 17:30:46 think-debian kernel: usb 1-2: new high-speed USB device number 5 using xhci_hcd
Aug 05 17:30:46 think-debian kernel: usb 1-2: New USB device found, idVendor=12d1, idProduct=1f01
Aug 05 17:30:46 think-debian kernel: usb 1-2: New USB device strings: Mfr=3, Product=2, SerialN
Aug 05 17:30:46 think-debian kernel: usb 1-2: Product: HUAWEI Mobile
Aug 05 17:30:46 think-debian kernel: usb 1-2: Manufacturer: Huawei Technologies
Aug 05 17:30:47 think-debian mtp-probe[2824]: checking bus 1, device 5: "/sys/devices/pci0000:00/0000:00:14.0/usb1/1-2"
Aug 05 17:30:47 think-debian mtp-probe[2824]: bus: 1, device: 5 was not an MTP device
Aug 05 17:30:47 think-debian systemd[1]: Created slice system-usb_modeswitch.slice.
Aug 05 17:30:47 think-debian systemd[1]: Starting USB_ModeSwitch__1-2:1.0...
Aug 05 17:30:47 think-debian laptop-mode[2880]: Laptop mode
Aug 05 17:30:47 think-debian laptop-mode[2881]: enabled, active
Aug 05 17:30:48 think-debian kernel: usb-storage 1-2:1.0: USB Mass Storage device detected
Aug 05 17:30:48 think-debian kernel: scsi host3: usb-storage 1-2:1.0
Aug 05 17:30:48 think-debian kernel: usbcore: registered new interface driver usb-storage
Aug 05 17:30:48 think-debian kernel: usbcore: registered new interface driver uas
Aug 05 17:30:48 think-debian usb_modeswitch[2910]: switch device 12d1:1f01 on 001/005
Aug 05 17:30:49 think-debian kernel: usb 1-2: USB disconnect, device number 5
Aug 05 17:30:58 think-debian kernel: usb 1-2: new high-speed USB device number 6 using xhci_hcd
Aug 05 17:30:58 think-debian kernel: usb 1-2: New USB device found, idVendor=12d1, idProduct=14db
Aug 05 17:30:58 think-debian kernel: usb 1-2: New USB device strings: Mfr=4, Product=3, SerialNumber=0
Aug 05 17:30:58 think-debian kernel: usb 1-2: Product: HUAWEI Mobile
Aug 05 17:30:58 think-debian kernel: usb 1-2: Manufacturer: Huawei Technologies
Aug 05 17:30:58 think-debian mtp-probe[2921]: checking bus 1, device 6: "/sys/devices/pci0000:00/0000:00:14.0/usb1/1-2"
Aug 05 17:30:58 think-debian mtp-probe[2921]: bus: 1, device: 6 was not an MTP device
Aug 05 17:30:58 think-debian laptop-mode[2997]: Laptop mode
Aug 05 17:30:58 think-debian laptop-mode[2998]: enabled, active
Aug 05 17:30:58 think-debian laptop-mode[3036]: Laptop mode
Aug 05 17:30:58 think-debian laptop-mode[3037]: enabled, active
Aug 05 17:30:58 think-debian kernel: cdc_ether 1-2:1.0 eth1: register 'cdc_ether' at usb-0000:00:14.0-2, CDC Ethernet Device, 00:a0:c6:09:5c:40
Aug 05 17:30:58 think-debian kernel: usbcore: registered new interface driver cdc_ether
Aug 05 17:30:58 think-debian kernel: cdc_ether 1-2:1.0 enx00a0c6095c40: renamed from eth1
Aug 05 17:30:58 think-debian root[3105]: usb_modeswitch: switched to 12d1:14db on 001/006
Aug 05 17:30:58 think-debian systemd[1]: Started USB_ModeSwitch__1-2:1.0.
Aug 05 17:31:01 think-debian ModemManager[1276]: <info>  Couldn't find support for device at '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-2': not supported by any plugin
Aug 05 17:32:24 think-debian kernel: usb 1-1: new low-speed USB device number 7 using xhci_hcd
Aug 05 17:32:24 think-debian kernel: usb 1-1: New USB device found, idVendor=192f, idProduct=0916
Aug 05 17:32:24 think-debian kernel: usb 1-1: New USB device strings: Mfr=0, Product=2, SerialNumber=0
Aug 05 17:32:24 think-debian kernel: usb 1-1: Product: USB Optical Mouse
Aug 05 17:32:24 think-debian kernel: usb 1-1: ep 0x81 - rounding interval to 64 microframes, ep desc says 80 microframes
Aug 05 17:32:24 think-debian mtp-probe[3112]: checking bus 1, device 7: "/sys/devices/pci0000:00/0000:00:14.0/usb1/1-1"
Aug 05 17:32:24 think-debian mtp-probe[3112]: bus: 1, device: 7 was not an MTP device
Aug 05 17:32:24 think-debian laptop-mode[3162]: Laptop mode
Aug 05 17:32:24 think-debian laptop-mode[3163]: enabled, active

같은 상황 lsusb도 확인됐다:-

Bus 003 Device 002: ID 8087:8000 Intel Corp. 
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 004: ID 04f2:b39a Chicony Electronics Co., Ltd
Bus 001 Device 003: ID 8087:07dc Intel Corp.
Bus 001 Device 002: ID 138a:0017 Validity Sensors, Inc.
Bus 001 Device 006: ID 12d1:1f01 Huawei Technologies Co., Ltd.
Bus 001 Device 005: ID 0781:5567 SanDisk Corp. Cruzer Blade
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

그런 다음이 두 명령을 사용해 보았습니다.https://askubuntu.com/questions/78164/configuring-tata-photon-usb-modem-huawei-ec156기본으로. 저는 데비안을 사용하고 있습니다.

sudo modprobe usbserial vendor=0x12d1 product=0x14db
sudo usb_modeswitch -v 0x12d1 -p 0x14db -H -W

다음은 출력입니다:-

 Take all parameters from the command line
 * usb_modeswitch: handle USB devices with multiple modes
 * Version 2.2.5 (C) Josua Dietze 2015
 * Based on libusb1/libusbx

 ! PLEASE REPORT NEW CONFIGURATIONS !

DefaultVendor=  0x12d1
DefaultProduct= 0x14db
HuaweiMode=1
NeedResponse=0

ifconfig -a제공:-

xxxxxxxxxx Link encap:Ethernet  HWaddr xx:xx:xx:xx:xx
          BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

eth0      Link encap:Ethernet  HWaddr xx:xx:xx:xx:xx
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
          Interrupt:20 Memory:e0600000-e0620000

eth0:avahi Link encap:Ethernet  HWaddr xx:xx:xx:xx:xx
          inet addr:169.254.7.244  Bcast:169.254.255.255  Mask:255.255.0.0
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          Interrupt:20 Memory:e0600000-e0620000

lo        Link encap:Local Loopback 
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:468 errors:0 dropped:0 overruns:0 frame:0
          TX packets:468 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:44602 (43.5 KiB)  TX bytes:44602 (43.5 KiB)

wlan0     Link encap:Ethernet  HWaddr xx:xx:xx:xx:xx
          BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

첫 번째는 ifconfig -a제가 공유해드린 USB 동글입니다.xxxxxx.

제가 얻을 수 있는 최신 정보는 다음과 같습니다.sudo journalctl -f

Aug 07 12:17:06 think-debian kernel: usb 1-1: new high-speed USB device number 11 using xhci_hcd
Aug 07 12:17:06 think-debian kernel: usb 1-1: New USB device found, idVendor=12d1, idProduct=1f01
Aug 07 12:17:06 think-debian kernel: usb 1-1: New USB device strings: Mfr=3, Product=2, SerialNumber=0
Aug 07 12:17:06 think-debian kernel: usb 1-1: Product: HUAWEI Mobile
Aug 07 12:17:06 think-debian kernel: usb 1-1: Manufacturer: Huawei Technologies
Aug 07 12:17:06 think-debian kernel: usb-storage 1-1:1.0: USB Mass Storage device detected
Aug 07 12:17:06 think-debian kernel: scsi host6: usb-storage 1-1:1.0
Aug 07 12:17:06 think-debian mtp-probe[3600]: checking bus 1, device 11: "/sys/devices/pci0000:00/0000:00:14.0/usb1/1-1"
Aug 07 12:17:06 think-debian mtp-probe[3600]: bus: 1, device: 11 was not an MTP device
Aug 07 12:17:06 think-debian systemd[1]: Starting USB_ModeSwitch__1-1:1.0...
Aug 07 12:17:07 think-debian usb_modeswitch[3656]: switch device 12d1:1f01 on 001/011
Aug 07 12:17:08 think-debian kernel: usb 1-1: USB disconnect, device number 11
Aug 07 12:17:16 think-debian kernel: usb 1-1: new high-speed USB device number 12 using xhci_hcd
Aug 07 12:17:16 think-debian kernel: usb 1-1: New USB device found, idVendor=12d1, idProduct=14db
Aug 07 12:17:16 think-debian kernel: usb 1-1: New USB device strings: Mfr=4, Product=3, SerialNumber=0
Aug 07 12:17:16 think-debian kernel: usb 1-1: Product: HUAWEI Mobile
Aug 07 12:17:16 think-debian kernel: usb 1-1: Manufacturer: Huawei Technologies
Aug 07 12:17:16 think-debian kernel: cdc_ether 1-1:1.0 eth1: register 'cdc_ether' at usb-0000:00:14.0-1, CDC Ethernet Device, xx:xx:xx:xx:xx
Aug 07 12:17:16 think-debian mtp-probe[3684]: checking bus 1, device 12: "/sys/devices/pci0000:00/0000:00:14.0/usb1/1-1"
Aug 07 12:17:16 think-debian mtp-probe[3684]: bus: 1, device: 12 was not an MTP device
Aug 07 12:17:16 think-debian kernel: cdc_ether 1-1:1.0 xxxxxxxxx: renamed from eth1
Aug 07 12:17:17 think-debian root[3788]: usb_modeswitch: switched to 12d1:14db on 001/012
Aug 07 12:17:17 think-debian systemd[1]: Started USB_ModeSwitch__1-1:1.0.
Aug 07 12:17:19 think-debian ModemManager[1372]: <info>  Couldn't find support for device at '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-1': not supported by any plugin

모뎀 관리자가 필요한 것 같습니다. 도움이 필요하세요?

이것은 내 /etc/network/interfaces결과입니다 :-

$ cat /etc/network/interfaces
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).

source /etc/network/interfaces.d/*

# The loopback network interface
auto lo
iface lo inet loopback

auto eth0
allow-hotplug eth0
iface eth0 inet dhcp

따라서 eth0은 이미 유선 인터페이스에 할당/점유되었습니다.

route이것을 감안할 때 :-

$ sudo route
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
default         *               0.0.0.0         U     1002   0        0 eth0
link-local      *               255.255.0.0     U     0      0        0 eth0

업데이트 - usbids를 업데이트했는데 이제 목록이 이전보다 훨씬 좋아졌습니다.

$ lsusb
Bus 001 Device 002: ID 8087:8000 Intel Corp. 
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
Bus 002 Device 004: ID 04f2:b39a Chicony Electronics Co., Ltd 
Bus 002 Device 003: ID 8087:07dc Intel Corp. 
Bus 002 Device 002: ID 138a:0017 Validity Sensors, Inc. Fingerprint Reader
Bus 002 Device 009: ID 192f:0916 Avago Technologies, Pte. 
Bus 002 Device 007: ID 12d1:14db Huawei Technologies Co., Ltd. E353/E3131
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

지금은 네트워크 관리자를 사용하고 있지만 모뎀 관리자가 필요한 변경을 수행하도록 하고 싶습니다.

답변1

ModemManager(현재)는 최소한 노출된 모뎀 장치에서만 작동합니다.제어 포트 1개. 귀하의 Huawei 장치는 HiLink 기반 장치인 것으로 보이며 다음을 통해서만 이더넷 네트워크 인터페이스를 노출합니다 cdc_ether. 이 모드에서 장치에 연결하는 유일한 방법은 장치에서 DHCP 클라이언트를 실행하는 것입니다(예를 들어 NetworkManager를 동적 IP 주소 지정으로 구성하는 것은 다음과 같습니다). 인터페이스에서 시도됨). 완료되면 해당 네트워크 인터페이스에 설정된 IP 주소와 192.168.8.2기본 경로(모뎀의 가상 게이트웨이)를 얻을 수 있습니다.192.168.8.1

앞서 "현재"라고 말한 이유는 HiLink 장치에 제어 인터페이스가 있기 때문입니다. 네트워크 인터페이스에 연결하면 192.168.8.1모뎀 자체가 신호 품질 등을 모니터링할 수 있는 웹 서비스 API가 포함된 웹사이트를 표시합니다. 이 관리를 지원하기 위해 ModemManager에서 일부 작업이 진행 중이지만 아직 준비되지 않았습니다.

답변2

내 생각엔 이게 공식적인 것 같아Linux에서 Tata Indicom 모바일/USB 모뎀 사용가이드(5페이지 PDF)가 도움이 될 것입니다.

관련 정보