How To Get Telstra 4G Mobile Broadband Working With Linux

I’m procrastinating finishing an MBA assignment, so here’s how to get your shiny new Telstra 4G dongle working under Linux.

I use Ubuntu, but these instructions should help you on other Linux variants as well. This process worked for Ubuntu 11.04, but I haven’t tested anything else. Let us know in the comments if this works for you too, or if you have any updates for other distros.

What Is It?

First up, let’s discover some information about the device itself:

> lsusb
Bus 008 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 007 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 005 Device 003: ID 08ff:1600 AuthenTec, Inc. AES1600
Bus 005 Device 002: ID 0b05:1751 ASUSTek Computer, Inc. BT-253 Bluetooth Adapter
Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 017: ID 19d2:0166 ONDA Communication S.p.A. 
Bus 002 Device 002: ID 04f2:b033 Chicony Electronics Co., Ltd
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 002: ID 1164:1f08 YUAN High-Tech Development Co., Ltd
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

The device itself is a ZTE product, an MF821 LTE modem, which for some reason shows up in the lsusb output as ONDA Communication. Take note of the ID code there, because we’ll need it in a minute.

USB Mode Change

This device is one of those tricky ones that pretends to be a storage devices before the modem driver is loaded. When it detects that it’s driver is loaded, it switches mode to become a modem. Under Windows and MacOS it does, anyway. Under Linux, we have to force this to happen (of course).

The utility that does this is called usb_modeswitch. Surprise, surprise. Grab it and its data module:

sudo apt-get install usb-modeswitch usb-modeswitch-data

Depending on how recent your distribution is, you might already have the appropriate configuration in the usb_modeswitch files. I didn’t so I had to add it myself.

Create a file in /etc/usb_modeswitch.d called 19d2:0166, the same as the ID from lsusb output above. That’s how usb_modeswitch knows which set of config to use. Put the following content in the file:

# Telstra ZTE LTE 4g modem
#
DefaultVendor=  0x19d2
DefaultProduct= 0x0166

TargetVendor=  0x19d2
TargetProduct= 0x0257

MessageContent="55534243123456782400000080000685000000240000000000000000000000"

CheckSuccess=20

Some brief explanation: The DefaultVendor and DefaultProduct are used by usb_modeswitch to find the USB address for the modem, so it knows which device to talk to. The MessageContent is a string that gets sent to the device to make it switch mode. I have no idea what that string means, I just copied it from a more recent version of usb-modeswitch-data for the MF820 product. It seems to work fine.

The TargetVendor and TargetProduct are used to check that the mode-switch worked, because we set CheckSuccess=20, which means check for 20 seconds to see if it worked. When the device switches mode, it actually changes its USB ID to a different product ID. Not all devices do that, but this one does, so we need to let usb_modeswitch know.

We want this to happen automatically, which we can do using the magic of udev. Add the following lines to /lib/udev/rules.d/40-usb_modeswitch.rules:

# Telstra 4G/LTE ZTE MF821
ATTRS{idVendor}=="19d2", ATTRS{idProduct}=="0166", RUN+="usb_modeswitch '%b/%k'"

Restart udevd and your modem should automatically mode-switch when you insert it.

Driver Support

You now need to make sure you have a kernel driver for the device. The usbserial kernel module already supports it (in 11.04, kernel 2.6.38-8-generic-pae), but it doesn’t detect it automatically, so we give it some help using modprobe configuration.

Add a file into /etc/modprobe.d, such as /etc/modprobe.d/telstra-4g.conf with the following content:

# Set up options for Telsta 4G connectivity under linux
options usbserial vendor=0x19d2 product=0x0257

Now you’ll need to remove the module from the running kernel using:

rmmod usbserial

(and any dependent modules) and then re-insert, it with:

modprobe usbserial

And the modem device should now be automatically detected.

Add to NetworkManager

Click on NetworkManager and Edit Connections, go to the Wireless Broadband tab, and add a connection. You should see a selector in the middle of the window called “ZTE LTE Technologies MSM” or something similar. If not, something hasn’t worked above and you’ll need to muck about with it a bit.

Click forward, forward, etc. until the connection is added. In my setup, the APN was set to “telstra.wap” for some reason, which is wrong. Change it to “telstra.internet”.

You should now be able to click on the newly added connection in NetworkManager and connect to 4G.

You can active your device by browsing to www.telstra.com.au and following the instructions in the little booklet that comes with the device. Or, if you’re me, the website will be broken and you’ll have to ring them and talk to a helpdesk person somewhere in Asia.

Forcing 4G Mode

For some reason, my dongle kept connecting in 3G mode, so I wasn’t getting the added speed and other benefits of 4G/LTE mode.

It looks like the version of modemmanager I’m using (0.4+git.20110124t203624.00b6cce-2ubuntu1) doesn’t know how to switch ZTE modems into 4G mode. I’m not sure, because my C is rusty.

Never fear! You can force the modem into 4G mode, and it appears to remember this from that point on, even if you unplug it and plug it back in the next day (as I just did).

Here’s how.

First, click on NetworkManager and unselect “Enable Mobile Broadband”. This will disconnect NetworkManager from the modem so we can talk to it directly.

Fire up minicom (sudo apt-get install minicom if you don’t have it) and hit CTRL-Z followed by O. Select “Serial port setup” and hit Enter. Now hit A to choose edit the serial device to use, and make it /dev/ttyUSB2. Hit Enter to save the setting, then Enter again to get back to the menu. Select Exit and hit Enter to get back to the minicom session.

Enable “local echo” so you can see what you type by hitting CTRL-Z followed by E.

Now we talk to the modem using Hayes AT commands. The first command is to make sure you’re connected to the modem:

AT

The modem should respond:

OK

Now we force the modem into 4G mode:

AT+ZSNT=6,0,0

Again, the modem should respond OK, and we’re done! Exit minicom.

Re-enable mobile broadband in NetworkManager, and connect. The little light on the modem should be green instead of blue, indicating you’re connected to the 4G network.

Update: You can also use the following code setting to put the modem into auto-negotiate mode:

AT+ZSNT=0,0,0

This should detect 4G if it’s available, and fall back to 3G if you’re outside a 4G zone.

That’s It!

Happy internetting.

Thanks to FreeGeek for the instructions on how to set up usb_modeswitch and udev.

Thanks to the Linux kernel documentation crew for how to pass options to the usbserial device driver.

And thanks to everyone who builds this software for free.

Bookmark the permalink.

56 Comments

  1. Thanks for your informative post :)
    Got the same modem, now trying Mikrotik to add support for it to their RouterOS product, and IMHO you already provided all required information.
    Well done :)

    P.S. One funny thing: my modem is always detected as PID=0x0257 now, it seems Telstra windows application or drivers are permanently switching device to USB modem mode after first installation. At least I had such problems before with vodafone modems, and had to switch it back using terminal commands (http://brainsuckerna.blogspot.com.au/2011/01/zte-usb-modem-zerocd-activation.html) when I needed to install it on another computer.

  2. You rock. Thank you.

  3. Thanks mate It works for me Great help

  4. HI, I’ve try your instruction on ubuntu 10.4 but it didn’t detect it. Any suggestion why it doesn’t work for me?

  5. Does your device show up in lsusb?

    Try running usb-modeswitch manually, with the --verbose flag and check the logging output to see what’s happening.

    Without more information, I can’t tell why it’s not working for you, sorry.

  6. The instructions worked perfectly under Linux Mint 11. After 10 seconds the Network manager identified the usb as a modem instead of a memory stick.
    Beauty!

  7. That’s great, Michael!

    Enjoy.

  8. Hi, this parameter:
    TargetProduct= 0x0257
    ——————————————- How should I find the corresponding value? 0257 is default?

    I am using ubuntu 12.04

    Thx

  9. Run usb-modeswitch manually, and select 0257 as the source product ID. After the modeswitch happens, run lsusb again and see what that product ID gets changed to. You can then put in that value instead of 0257 as the TargetProduct.

    The TargetProduct and TargetVendor codes are what usb-modeswitch uses when you tell it to CheckSuccess. That’s how it figures out that the modeswitch happened successfully. If you run it manually, you can figure out what the successful modeswitch code is for your device, and put that in the config file.

  10. Thx for your reply, but I still in confusion. I did the same thing as you replied, but what’s the target product ID? Can you be more specific?

    # usb_modeswitch -v 0f3d -p 68aa

    Looking for default devices …
    found matching product ID
    adding device
    Found device in default mode, class or configuration (1)
    Accessing device 005 on bus 001 …
    Getting the current device configuration …
    OK, got current device configuration (1)
    Using first interface: 0x00
    Using endpoints 0x01 (out) and 0x81 (in)
    Not a storage device, skipping SCSI inquiry

    USB description data (for identification)
    ————————-
    Manufacturer: Sierra Wireless, Incorporated
    Product: AirCard 320U
    Serial No.: 357272042394811
    ————————-
    Warning: no switching method given.
    -> Run lsusb to note any changes. Bye.

    # lsusb
    Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
    Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
    Bus 001 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
    Bus 002 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
    Bus 001 Device 003: ID 04f2:b217 Chicony Electronics Co., Ltd
    Bus 002 Device 003: ID 17ef:6016 Lenovo
    Bus 001 Device 005: ID 0f3d:68aa Airprime, Incorporated

  11. Nope, sorry.

    You’ve got a Sierra Wireless AirCard, not a ZTE.

    You’ll need to check with the usb-modeswitch folks to see if they support your card yet. Google for your vendor and product ID, and see what shows up.

    Sorry I can’t be more help.

  12. Any tricks to work this in 12.04? I can get up to the NetworkManager bit, albeit I needed to create many of the directories along the way, but it isn’t listed in the NetworkManager selector despite being listed in lsusb with 0257 ID?

    (Also detected as ZTE rather than ONDA)

  13. I don’t have 12.04 to check, but can you see entries in /var/log/syslog like this:

    Jul 5 09:04:51 daggit usb_modeswitch: switching 19d2:0166 (ZTE,Incorporated: ZTE LTE Technologies MSM)
    Jul 5 09:04:57 daggit kernel: [ 53.459699] USB Serial support registered for GSM modem (1-port)
    Jul 5 09:04:57 daggit kernel: [ 53.460827] option: v0.7.2:USB Driver for GSM modems
    Jul 5 09:04:58 daggit usb_modeswitch: switched to 19d2:0257 (ZTE,Incorporated: ZTE LTE Technologies MSM)

    You need to see both the modeswitch, and the loading of a driver so that NetworkManager can detect that there’s a wireless modem it can use.

  14. I’ve recently installed Ubuntu 12.04, and I can report that the dongle is now detected for the modeswitch automatically. Also, NetworkManager now has the correct Telstra APN listed under NextG.

    I have to modprobe usbserial manually, so there’s something not quite auto-detecting correctly. I’ll let you know when I figure out what it is.

  15. Works like a charm in RHEL6 as well. You still have to follow the instructions above and there were some other quirks and a reboot required, but it works through NetworkManager as expected.

    I’m going to write up a supplementary blog post (with credits and link backs of course) on what I did.

    Thanks again for sharing the love!

  16. Hi Justin,
    Thanks for your instructions. I have 12.04 and have been unable to get my 4G modem to work. Any further information on this would be great. It appears to be modeswitching- the name changed from 0166 to 0257 when I type lsusb.

    I have followed your instructions, the “rmmod usbserial” returns an error. “modprobe usbserial” retursn a bunch of warnings “ignoring bad line … in modprobe.d”

    I cant detect the modem in network connections, under the “mobile broadband” tab and have just about given up! New to ubuntu so dont know how to do very much! Would be nice if this worked out of the box…

  17. What error do you get from rmmod usbserial? It is just complaining that usbserial isn’t there to remove?

    Errors in modprobe.d doesn’t sound great. What errors?

    After you type modprobe usbserial, type “lsmod” and see if usbserial is in the list. If so, it’s loaded ok. If not, it’s not loading, probably because of errors somewhere in the files in /etc/modprobe.d/. The error messages will help you there.

    If you’re still stuck, try posting something over at launchpad in the forums, and the real Ubuntu knowledgable folks can help you out.

  18. Update on getting things running on 12.04: usbserial doesn’t appear to automatically get loaded for some reason, so I’ve forced it to get loaded at boot time by adding it to the end of /etc/modules:

    echo “usbserial” >> /etc/modules

    Now my 4G USB dongle gets detected and shows up automatically in NetworkManager when I plug it in.

  19. Justin, thanks for your reply. I have tried your additional comments, without success unfortunately.

    I have usb-modeswitch installed, ubuntu 12.04 and a telstra 4g modem.
    I have added to /etc/modules on the last line:
    echo “usbserial”

    When you say “shows up automatically in network manager”. Do I still need to follow all of the steps you have listed above for 11.04 (or just add the line to /etc/modules), ie what is the complete process for 12.04?

    As lsusb returns 0257 as product name do I use this in all the file additions/modifications and file names you describe, instead of 0166?

    When I plug the modem in, the light on the dongle turns red, then goes green, which is the only confirmation (along with lsusb) that something is happening.

    Whats the way forward!?
    Thanks heaps.

    claudio@claudio-AO725:~$ lsusb
    Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
    Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
    Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
    Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
    Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
    Bus 006 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
    Bus 007 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
    Bus 003 Device 002: ID 045e:0039 Microsoft Corp. IntelliMouse Optical
    Bus 002 Device 002: ID 04f2:b336 Chicony Electronics Co., Ltd
    Bus 006 Device 002: ID 19d2:0166 ZTE WCDMA Technologies MSM

    claudio@claudio-AO725:~$ rmmod usbserial
    ERROR: Module usbserial does not exist in /proc/modules

    claudio@claudio-AO725:~$ modprobe usbserial
    FATAL: Error inserting usbserial (/lib/modules/3.2.0-23-generic/kernel/drivers/usb/serial/usbserial.ko): Operation not permitted

  20. Aha! 2 things here.

    Firstly, the last line in /etc/modules should just be the bare word:

    usbserial

    Secondly, if you want to manually insert the module into the kernel, you need to be root. Either become root, or use sudo, e.g.:

    sudo modprobe usbserial

    It can take a little while before NetworkManager notices the modem is there. Watch /var/log/syslog to see it happen.

  21. Yep it worked. Thanks for all your help Justin.

  22. Justin – what’s the answer to Claudio’s question: “As lsusb returns 0257 as product name do I use this in all the file additions/modifications and file names you describe, instead of 0166?”

    It’s maddening that this doesn’t simply work. I bought two today with my friend and his mac air had it going in a matter of seconds.

  23. Justin,

    I’d like to thank you for the comprehensive description.

    usb-modechange worked, followed by
    rm option
    rm usb_wwan
    rm usbserial
    modprobe usbserial
    modprobe usb_wwan
    modprobe option

    Unfortunately I can’t get it work.

    Final state is as per below dmesg exerpt:
    USB Serial deregistering driver GSM modem (1-port)

    [ 2755.103163] option1 ttyUSB3: GSM modem (1-port) converter now disconnected from ttyUSB3

    [ 2755.104224] option1 ttyUSB2: GSM modem (1-port) converter now disconnected from ttyUSB2

    [ 2755.104348] option1 ttyUSB1: GSM modem (1-port) converter now disconnected from ttyUSB1

    [ 2755.104432] option1 ttyUSB0: GSM modem (1-port) converter now disconnected from ttyUSB0

    [ 2755.104461] usbcore: deregistering interface driver option

    [ 2755.104557] option: option_instat_callback: error -108

    [ 2755.104623] option 1-1:1.3: device disconnected

    [ 2755.104706] option: option_instat_callback: error -108

    [ 2755.104756] option 1-1:1.2: device disconnected

    [ 2755.104814] option 1-1:1.1: device disconnected

    [ 2755.104872] option 1-1:1.0: device disconnected

    [ 2786.300780] USB Serial deregistering driver generic

    [ 2786.300875] usbcore: deregistering interface driver usbserial_generic

    [ 2786.300902] usbcore: deregistering interface driver usbserial

    [ 3092.845792] usbcore: registered new interface driver usbserial

    [ 3092.845810] usbcore: registered new interface driver usbserial_generic

    [ 3092.845826] USB Serial support registered for generic

    [ 3092.845848] usbserial_generic 1-1:1.0: generic converter detected

    [ 3092.846057] usb 1-1: generic converter now attached to ttyUSB0
    [ 3092.846084] usbserial_generic 1-1:1.1: generic converter detected

    [ 3092.846148] usb 1-1: generic converter now attached to ttyUSB1

    [ 3092.846167] usbserial_generic 1-1:1.2: generic converter detected

    [ 3092.846222] usb 1-1: generic converter now attached to ttyUSB2

    [ 3092.846236] usbserial_generic 1-1:1.3: generic converter detected

    [ 3092.846298] usb 1-1: generic converter now attached to ttyUSB3

    [ 3092.846312] usbserial: USB Serial Driver core

    [ 3116.824970] usbcore: registered new interface driver option

    [ 3116.824995] USB Serial support registered for GSM modem (1-port)

    What am I missing ?

    Thanks for your help in advance, Peter

  24. Hi John,

    No, Claudio used 0x0166 correctly. That’s the USB id of the device before the modeswitch happens. After modeswitch, it has the ID of 0x0257. That’s how usb_modeswitch knows that the modeswitch completed successfully.

    Sadly, Linux isn’t as popular as Windows or Mac for desktop/laptop, so we don’t get the same support from software vendors. It’s a lot better now than it used to be, though.

  25. Hi Peter,

    Hmm. That dmesg output all looks as it should. Is it just not showing up in NetworkManager? In what way is it not working?

  26. Hi Justin,
    Thanks for the quick response.
    The problem is solved, but in an unconventional way.
    The ZTE MF821 did a lso not work with my company windows laptop. I just returned the stick and changed to the w-lan model.
    That works with both laptops and the blackberry.
    Thanks agrin, Peter

  27. Ah, dodgy dongle then.

    Glad the problem was sorted in the end.

    Happy internetting!

  28. I have a 4G USB Quanta Computer Stick.. here is what i get,,, i hope there is a way to make it work, i can see it is a driver issue but i dont kno how to fix it…

    Looking for default devices …
    searching devices, found USB ID 1d6b:0003
    searching devices, found USB ID 1d6b:0002
    searching devices, found USB ID 0408:ea25
    found matching vendor ID
    found matching product ID
    adding device
    searching devices, found USB ID 8087:0024
    searching devices, found USB ID 1d6b:0002
    searching devices, found USB ID 0489:e00f
    searching devices, found USB ID 05ca:18c0
    searching devices, found USB ID 8087:0024
    searching devices, found USB ID 1d6b:0002
    Found device in default mode, class or configuration (1)
    Accessing device 000 on bus 002 …
    Getting the current device configuration …
    USB error: error sending control message: Operation not permitted
    Error getting the current configuration (error -1). Assuming configuration 1.
    Using first interface: 0x00
    Using endpoints 0x01 (out) and 0x81 (in)
    Inquiring device details; driver will be detached …
    Looking for active driver …
    USB error: could not get bound driver: Operation not permitted
    No driver found. Either detached before or never attached
    USB error: could not claim interface 0: Operation not permitted
    Could not claim interface (error -1). Skipping device inquiry
    USB error: could not clear/halt ep 1: Operation not permitted
    USB error: could not release intf 0: Operation not permitted
    USB error: error sending control message: Operation not permitted
    Error: could not get description string “manufacturer”
    USB error: error sending control message: Operation not permitted
    Error: could not get description string “product”
    USB error: error sending control message: Operation not permitted
    Error: could not get description string “serial number”

    USB description data (for identification)
    ————————-
    Manufacturer:
    Product:
    Serial No.:
    ————————-
    Warning: no switching method given.
    -> Run lsusb to note any changes. Bye.

  29. sorry .. realized that i was adding my device id all the way through the instructions, i have corrected the mistakes and now it is responding …

    what i get it that the device has bean recognized as a “storage device”, take a look below…

    Looking for default devices …
    searching devices, found USB ID 1d6b:0003
    searching devices, found USB ID 1d6b:0002
    searching devices, found USB ID 0408:ea25
    found matching vendor ID
    found matching product ID
    adding device
    searching devices, found USB ID 8087:0024
    searching devices, found USB ID 1d6b:0002
    searching devices, found USB ID 0489:e00f
    searching devices, found USB ID 05ca:18c0
    searching devices, found USB ID 8087:0024
    searching devices, found USB ID 1d6b:0002
    Found device in default mode, class or configuration (1)
    Accessing device 004 on bus 002 …
    Getting the current device configuration …
    OK, got current device configuration (1)
    Using first interface: 0x00
    Using endpoints 0x01 (out) and 0x81 (in)
    Inquiring device details; driver will be detached …
    Looking for active driver …
    OK, driver found (“usb-storage”)
    OK, driver “usb-storage” detached

    SCSI inquiry data (for identification)
    ————————-
    Vendor String: Qualcomm
    Model String: MMC Storage
    Revision String: 2.31
    ————————-

    USB description data (for identification)
    ————————-
    Manufacturer: Qualcomm, Incorporated
    Product: Qualcomm CDMA Technologies MSM
    Serial No.: 352593050841590
    ————————-
    Warning: no switching method given.
    -> Run lsusb to note any changes. Bye.

    thanks…

  30. Your device isn’t a ZTE 4G modem, so these instructions are only partly useful.

    It looks like the vendorId and productId for your device may not be in the usb_modeswitch database. You’ll need to check /etc/usb_modeswitch.d for your device’s id, and if it’s missing, follow similar instructions as above, but replace the ZTE’s vendorId and productId with the ones from this device.

    I have no idea if the MessageContent for the ZTE will work to switch your device’s mode. Maybe check the files in /etc/usb_modeswitch.d for another Qualcomm device, and see if that one works?

  31. Thanks for your fast response, you given me a great deal of knowledge on where to look from here…

    Thanks and all the best,

  32. Awesome instructions man, I’m doing some reasearch into buying a ZTE mf821, and I’m wondering if you could tell me if it would theoretically work on a raspberry pi running either raspbian (wheezy) or arch linux arm. The most likely thing to cause an issue is the fact that it runs ARMV6. Cheers.

  33. Cheers! I’m a bit surprised at the number of Linuxy folk using this thing. But yay! My peeps!

    I can’t see a theoretical reason for it not to work, so long as the kernel for raspbian or arch linux includes the right hooks for the usbserial stack, and it’s recent enough to include LTE supporting code for the usbmodem stack so you can authenticate to the network.

    If you do give it a go, let me know. I’m sure the Moore’s Cloud people would be interested in adding mobile roaming capability to the Light.

    In fact, let me ping them and ask if they’ve looked at it at all…

  34. Thanks, I did it and Posted a Solution for Qualcomm CDMA Modems That Our Local Telecom Company “Mobily” Use as “Mobily 4G LTE”
    I did the same steps, and did a small research to find the switch message and did it (:
    here is a post i made about it .. (:
    http://saleh360.blogspot.com/2013/04/mobily-4g-lte-usb-modem-workaround.html

  35. I use MF821 under Debian Wheezy from few months. It works works out of the box now. Network manager detects the modem after pluging it to USB port.
    Unfortunately the modem likes to freeze probably after loosing the connection. When it looses the signal (red diode) and drop the connection it sometimes became unresponsive (red diode stays on for ever, if i try to connect it fails). Some times the diode changes color back to blue or green. Then I try to connect with network manager without success (connection failed). After some time the modem disappear from network manager. Restarting network manager sometimes help some times I have to unplug and plugin the modem.
    Is there some way to force modem restart without unplugging. Maybe somebody had a similar problem with this modem?

    When the modem disappear I have this in syslog:
    NetworkManager[8160]: Activation (ttyUSB3) failed.
    modem-manager[3704]: Modem /org/freedesktop/ModemManager/Modems/23: state changed (connected -> disconnecting)
    NetworkManager[8160]: SCPlugin-Ifupdown: devices removed (path: /sys/devices/virtual/net/ppp0, iface: ppp0)
    NetworkManager[8160]: (ttyUSB3): now unmanaged
    NetworkManager[8160]: (ttyUSB3): device state change: failed -> unmanaged (reason ‘removed’) [120 10 36]
    NetworkManager[8160]: (ttyUSB3): deactivating device (reason ‘removed’) [36]

  36. Excuse me , I have some questions .

    My system is Ubuntu .
    As plugging the dongle , I can’t see any message on the screen , but I can see the ID through typing the instruction of lsusb .

    My usb ID is 0408:3400 , so the parameters I set are :

    DefaultVendor= 0x0408
    DefaultProduct= 0x3400

    TargetVendor= 0x0408
    TargetProduct= 0x3400

    But , when I use rmmod usbserial , it shows:
    Module usbserial is not currently loaded

    Do you know what’s wrong with it ?

  37. Pingback: Reflections on 2013 | eigenmagic

  38. usbserial isn’t loaded, so I suspect that your dongle isn’t being recognised by udev, so the module isn’t getting automatically loaded.

    Try running:
    modprobe usbserial

    to manually load the module, and see if the dongle is detected. Then you just need to set up the udev detection as per the instructions in the post.

    You may need to manually do the usb_modeswitch as well, to test out the required settings that you’ll need to put into configuration files.

    Best of luck!

  39. I have read so many posts on the topic of the blogger lovers but this article is really a
    good post, keep it up.

  40. I have lodged a complaint… They gave me a new modem saying that they replaced “mainboard”:)
    Now the modem works fine without freezing.
    For the information:
    My modem is ZTE MF821 LTE sold in Plus GSM (Poland). Now it works out of the box under Debian Jessie. No additional software or configuration is needed. You need just network manager and packages from the repository.

  41. Pingback: My Mobile Tools of Trade | eigenmagic

  42. Thanks for the post. My modem was detected and I was able to make connection using Network Manager. But only the very first time, ie, just after completing steps in your post.

    Now it is not getting detected by Network Manager. I can’t either connect it using wvdial.

    What will be the problem? Can you help?

  43. Hard to tell without more information.

    Check that the driver modules are loaded (with lsmod), and watch for log entries in the /var/log/syslog to see what’s happening.

    You may need to manually trigger commands if the udev configuration isn’t quite right.

  44. Hi. I’m a relative newbie to Linux, but am very happy you have gone to the trouble to make this article.

    Does what you suggest only get the ZTE MF821 to operate on linux while locked to Telstra, or would it also work with an unlocked MF821?

    Many thanks, Paul

  45. I can’t think of why it wouldn’t, provided you have the SIM configured by Telstra as valid on their network.

    Try it and see, and let us know!

  46. Hi Justin

    Thanks for responding so quickly. I’m sorry – my question was too vague. What I wonder is can your instructions be adapted to use a once Telstra only ZTE MF821, now unlocked, with an iinet sim provided by westnet who use the Optus network?

    Many thanks and best regards

    Paul

  47. Ah right. Very little should need to change for it to work.

    You’ll need to change the APN setting in Network Manager from ‘telstra.internet’ to whatever the Optus network APN is, that’s it. Everything else should be fine as it is.

  48. Wonderful. Many thanks !

  49. Oooh ahh Telstra 4G ZTE MF821 works out of the box on Linux Mint 15 Olivia. Happy days !

  50. And that is unlocked, using a iinet (optus network) sim. I’m only getting 3G with it (which I anticipated).

  51. Has anyone been able to find a way to use a sierra wireless aircard 320u

  52. Has anyone been able to connect a Sierra wireless aircard 320u?
    If so could you please comment what you had to do to achieve this.

  53. Silly me – I got stuck at “Create a file”.

    Though this page’s information is very helpful, it would be better if it was written for Newbies to be able to follow it step by step without having to go off and do a 12 month course on the basics before reading this page.

    Back to Googling “How to Create a file”.

  54. I can report that the Telstra 4G USB modem works perfectly under Ubuntu 14.04 without any modifications or “geek” tweaking needed. It is reported as a “Wired Connection”.

  55. Anybody have a clue where the 0x0257 for target product came from? I’m trying to do this with a Huawei E5372T. Thanks…

  56. I just grabbed it from the output in syslog after doing the modeswitch manually.

    When the device switches mode, the product ID changes. You tell modeswitch what the TargetProduct is going to be so that it knows what to look for when checking that the modeswitch worked correctly.

    If yours works differently, run the modeswitch command manually and watch the logs for what your device changes to. Then use that in your config file instead of 0x0257.

Comments are closed