OPNsense Forum

Archive => 19.1 Legacy Series => Topic started by: GiantJack on November 01, 2019, 06:41:34 pm

Title: [Solved] e3372h Hilink LTE modem as 2nd gateway ?
Post by: GiantJack on November 01, 2019, 06:41:34 pm
Hi there!

I have a running 19.1 OPNsense, connected to my DSL modem. It works fine.

I have an LTE modem e3372h with Hilink firmware.  I used it with a TPlink TL MR3020 travel router and it works fine too.

I intend to connect it to my OPNsense firewall to use it as backup gateway or increase my bitrate (my DSL is not so fast).

So far, I was not able to make it work together (the e3372h connected on USB port of my OPNsense).

I'm confused because if the travel router can do it...I assume it should be possible.

I read a few howto's explaining it may require custom firmware to change how my e3372h works (to turn it in 'stick' mode).

I wish to avoid this: so the LTE modem can still be disconnected and used on PC like before when needed (travels etc...)

Is there any solutions ?



as a first step...I would be happy to know how to install usbutils (to run lsusb).
Code: [Select]
root@OPNsense:~ # pkg install usbutils
Updating OPNsense repository catalogue...
OPNsense repository is up to date.
All repositories are up to date.
pkg: No packages available to install matching 'usbutils' have been found in the repositories
root@OPNsense:~ #


Title: Re: e3372h Hilink LTE modem as 2nd gateway ?
Post by: GiantJack on November 01, 2019, 09:57:08 pm
Ok, I found out how to install lsusb.

now I try to setup the modem with usb_modeswitch.

I found nothing in opnsense doc, so I followed pfsense little information here:
https://docs.netgate.com/pfsense/en/latest/cellular/known-working-3g-4g-modems.html#modems-reported-to-work-as-ethernet-devices

I tried this command which seem not ending.
Code: [Select]
# usb_modeswitch -v 12d1 -p 1f01 -c /usr/local/share/usb_modeswitch/12d1:1f01
Look for target devices ...
 No devices in target mode or class found
Look for default devices ...
 Found devices in default mode (1)
Access device 002 on bus 001
Get the current device configuration ...
Current configuration number is 1
Use interface number 0
 with class 8
Use endpoints 0x01 (out) and 0x81 (in)
Using standard Huawei switching message
Looking for active drivers ...
 OK, driver detached
Set up interface 0
Use endpoint 0x01 for message sending ...
Trying to send message 1 to endpoint 0x01 ...

it does not come back to prompt unless I do ctrl+c

but it seems to work:
before:
# lsusb
Code: [Select]
Bus /dev/usb Device /dev/ugen1.2: ID 12d1:1f01 Huawei Technologies Co., Ltd. E353/E3131 (Mass storage mode)
after:
 # lsusb
Code: [Select]
Bus /dev/usb Device /dev/ugen1.2: ID 12d1:14dc Huawei Technologies Co., Ltd. E33372 LTE/UMTS/GSM HiLink Modem/Networkcard

also in ifconfig, I have a new interface:
Code: [Select]
ue0: flags=8802<BROADCAST,SIMPLEX,MULTICAST> metric 0 mtu 1500
ether 0c:5b:8f:27:9a:64
hwaddr 0c:5b:8f:27:9a:64
nd6 options=23<PERFORMNUD,ACCEPT_RTADV,AUTO_LINKLOCAL>

something seems missing.
Also I can find ue0 in webui, create interface and gateway, but it is still not connected, no IP assigned.
Title: [Solved] e3372h Hilink LTE modem as 2nd gateway ?
Post by: GiantJack on November 01, 2019, 10:53:41 pm
Hi again,
I found the issue.

I have done the interface assignement but forget to enable the new created interface.
Once enable, it works!
I have now a new gateway "online" with IP 192.168.8.1 which is the modem IP.

If I set this gateway as default and go to a "what is my ip" website, I can now see 37.xx.xx.xx which is my LTE IP.
:-)

Good to know it is possible to use e3372h HiLink mode without any modification of any kind !!



next step:
pfsense page I share before said the usb_modeswitch command must be done each time I reconnect the modem.  Maybe this can be automated at connexion or just cron-ed...

But that's an other story!