How to fix Huawei E620 USB 3G Modem in Ubuntu 9.10 Karmic Koala

I recently upgraded my laptop to Ubuntu 9.10 (Karmic Koala) and among a few other niggles (mostly related to intel video support, or lack thereof) it completely broke support for my Huawei 3G (E620) modem. Fortunately the fix is fairly straightforward: install a new kernel. I went with the latest (v2.6.32 release candidate available over here at ) and the problem is solved.

If you want the gory details, check the thread over at I’ll distil the useful bits below.

After the upgrade, my huawei 3G modem stopped being detected by NetworkManager. I’d see the fake ‘ZeroCD’ drive try to map itself and occasionally a gnome message box would be thrown up about a failed mount attempt, but no modem.

A look in the logs revealed /var/log/messages filling up with lines like this:

kernel: option 3-1:1.2: GSM modem (1-port) converter detected
kernel: usb 3-1: GSM modem (1-port) converter now attached to ttyUSB0
kernel: option 3-1:1.1: GSM modem (1-port) converter detected
kernel: usb 3-1: GSM modem (1-port) converter now attached to ttyUSB1
kernel: option 3-1:1.0: GSM modem (1-port) converter detected
kernel: usb 3-1: GSM modem (1-port) converter now attached to ttyUSB2
kernel: option1 ttyUSB2: GSM modem (1-port) converter now disconnected from ttyUSB2
kernel: option 3-1:1.0: device disconnected
kernel: option1 ttyUSB1: GSM modem (1-port) converter now disconnected from ttyUSB1
kernel: option 3-1:1.1: device disconnected
kernel: option1 ttyUSB0: GSM modem (1-port) converter now disconnected from ttyUSB0
kernel: option 3-1:1.2: device disconnected

So the modem was being disconnected and reconnected at least a couple of times a second for some reason, and the storage device was not appearing at all.

I tried the usb_modeswitch tool which is supposed to jolt misbehaving HUAWEI (and other brand) devices out of their stupor with some undocumented SCSI/USB commands, but no success this time.

After a bit of googling, it turns out this is (was) a known bug in the way the more recent linux kernel handles the combination USB Modem/Storage device hardware (and was allowed to remain in a major release of Ubuntu which is a bit unfortunate as it seems these types of USB modems are pretty common).

There are a couple of fixes pending an official update: either install a patched version of the kernel, or temporarily disable the USB Storage kernel module which looks pretty easy and apparently worked for a few people:

# rmmod usb-storage

Untested by me: Your mileage may vary.  Be warned that even if this works, by unloading the usb-storage kernel module you will lose support for any USB based storage devices, so this is strictly a temporary workaround. I thought I’d try the more permanent and possibly dangerous (?) kernel solution first, which worked.

Steps to upgrade your kernel to a compatible version:

  1. Check your current version with the uname -a command. My post-9.10-Karmic upgrade version was: 2.6.31-14-generic #48-Ubuntu SMP  x86_64 GNU/Linux
  2. Go to and download the .deb files for the kernel headers (“all”) and the kernel for your architecture (“amd64” or “i386”). If you don’t have any kind of internet on the affected ubuntu box, grab them via another connected machine and copy them via removable media (windows or mac should be fine for just getting the files). You want the “linux-header” and “linux-image” files from within the folder with the latest (hopefully stable) version number. You can ignore the source file for now.
  3. Go to a command prompt, change to the folder where the downloaded .deb files are located, and execute the following, substituting the .deb file names for the versions you have (make sure you install the headers first).
  4. sudo dpkg -i ./linux-headers-2.6.32-020632rc8_2.6.32-020632rc8_all.deb
  5. sudo dpkg -i ./linux-image-2.6.32-020632rc8-generic_2.6.32-020632rc8_amd64.deb

After this, provided everything worked, you’re a reboot away from your modem working again. After the boot, uname -a should reveal the newly installed kernel version. Mine is: 2.6.32-020632rc8-generic #020632rc8 SMP

Once plugged in, the modem worked instantly and my mobile broadband account connected fine. Hooray!

While lsusb output looked the same as before:

Bus 006 Device 004: ID 12d1:1001 Huawei Technologies Co., Ltd. E620 USB Modem

My /var/log/messages also looked a lot healthier:

kernel: USB Serial support registered for GSM modem (1-port)
kernel: option 6-2:1.0: GSM modem (1-port) converter detected
kernel: usb 6-2: GSM modem (1-port) converter now attached to ttyUSB0
kernel: option 6-2:1.1: GSM modem (1-port) converter detected
kernel: usb 6-2: GSM modem (1-port) converter now attached to ttyUSB1
kernel: option 6-2:1.2: GSM modem (1-port) converter detected
kernel: usb 6-2: GSM modem (1-port) converter now attached to ttyUSB2
kernel: usbcore: registered new interface driver option
kernel: option: v0.7.2:USB Driver for GSM modems
kernel: scsi 8:0:0:0: CD-ROM            HUAWEI   Mass Storage     2.31 PQ: 0 ANSI: 2
kernel: scsi 8:0:0:1: Direct-Access     HUAWEI   SD Storage       2.31 PQ: 0 ANSI: 2
kernel: sr0: scsi-1 drive
kernel: Uniform CD-ROM driver Revision: 3.20
kernel: sr 8:0:0:0: Attached scsi generic sg1 type 5
kernel: sd 8:0:0:1: Attached scsi generic sg2 type 0
kernel: sd 8:0:0:1: [sdb] Attached SCSI removable disk

Additionally, with the new kernel, both the pseudo cdrom, the 3G modem, and presumably the SD storage (though I don’t use it) are working at the same time. So, problem solved.

(Another improvement I noticed with the new version of ubuntu/kernel is I can disconnect the wireless broadband account via networkmanager without nasty gnome freeze-ups. Not sure what the culprit was for this: I worked around by disconnecting the hardware to avoid freezes, but looks like this too is now solved).


  • Avatar
    January 10, 2010 - 11:07 pm | Permalink

    thanks for your info, however i have a different sets of problem. the gsm modem i have indicated it is huawei e1550, but when i run lsusb, the terminal showed it is huawei e620. i tried the methods posted by u but the connection still could not be established. I am using ubuntu karmic. any help?

    • January 10, 2010 - 11:53 pm | Permalink

      Hi Vincent

      If you have upgraded the kernel perhaps you have a different issue? As I have not had the same problem I can’t tell you how to fix it, but I can suggest looking at the following log files for clues while you try to connect and/or plug/unplug the USB device:


      (Ubuntu has a good tool for this under System –> Administration –> Log File Viewer)

      Also: run the ‘dmesg’ command and check the output.

      Anything interesting in the log files or dmesg output, google and see what comes up – others might have a solution.

  • Avatar
    January 15, 2010 - 6:07 am | Permalink

    My output of lsusb is, you can see it is E620, but the label on the device is E1550:-

    Bus 001 Device 003: ID 12d1:1001 Huawei Technologies Co., Ltd. E620 USB Modem
    Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
    Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

    my /var/log/messages is the same as what you posted, but there is still no internet connection after I unplugged and plugged in, reboot etc.
    Well, I just leave this info here to see if anybody has any solution.

  • Avatar
    chris snow
    February 5, 2010 - 3:46 pm | Permalink

    I have the same problem with a K3565 Revision 2 – it\\\’s detected as E620. Still no internet!

  • Avatar
    Rudolfo Schulze
    February 7, 2010 - 2:15 am | Permalink

    Thanks for your info. I had quite the same kind of trouble using a ZTE MF626 from VIVO (Brazil). The connection didn´t last for long and the device indication LED was simple extinguishing. The device was disappearing from the box. I follow your instructions to upgrade kernel (I picked 2.6.33-020633rc6) and after that it is running smooth.

  • Avatar
    February 9, 2010 - 5:04 am | Permalink

    Thanks so much for this. My modem is a Huawei E156G and it works fine with kernel 2.6.31-11. I’m fairly new to Linux so really appreciate your step-by-step instructions. Many thanks.

  • February 10, 2010 - 12:26 am | Permalink

    Hi Tracey, Rudolfo, glad it helped!

  • February 13, 2010 - 9:09 pm | Permalink

    I did, with modem connected:

    sudo modprobe -r option
    sudo modprobe -r usbserial
    sudo modprobe usbserial vendor=0x12d1 product=0x1003

    and then “safely remove drive” on the mobile connect drive. works, but you have to do it every time, and the usbserial, option and vendor/prod id may change if other usb-peripherals are connected.


  • Leave a Reply

    Your email address will not be published. Required fields are marked *