FFE: usb-modeswitch should be included by default on Maverick

Bug #521578 reported by Angel Guzman Maeso on 2010-02-14
This bug affects 18 people
Affects Status Importance Assigned to Milestone
modemmanager (Ubuntu)
Declined for Lucid by Martin Pitt
usb-modeswitch (Ubuntu)
Declined for Lucid by Martin Pitt

Bug Description

Using the lastest and update lucid:

$ uname -a
Linux magmus 2.6.32-13-generic #18-Ubuntu SMP Wed Feb 10 21:24:20 UTC 2010 i686 GNU/Linux

$ lsusb | grep Huawei
Bus 001 Device 006: ID 12d1:1446 Huawei Technologies Co., Ltd.

I have the Modem USB Huawei E1612, but the device init ONLY as a storage device and it dont as modem.

I read this web for try to change with usb-modeswitch, but it dont work:

I install usb-modeswitch:
$ sudo apt-get install usb-modeswitch
Then I add this lines to /etc/usb_modeswitch.conf:
[code]# Huawei E1692
DefaultVendor= 0x12d1
DefaultProduct= 0x1446

TargetVendor= 0x12d1
TargetProduct= 0x140c



And I run the usb-modemswitch:
$ sudo usb_modeswitch

Looking for target devices ...
 No devices in target mode or class found
Looking for default devices ...
 Found default devices (1)
Accessing device 006 on bus 001 ...
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: HUAWEI
   Model String: Mass Storage
Revision String: 2.31

USB description data (for identification)
Manufacturer: HUAWEI Technology
     Product: HUAWEI Mobile
  Serial No.: not provided
Setting up communication with interface 0 ...
Trying to send the message to endpoint 0x01 ...
 OK, message successfully sent

Checking for mode switch (max. 5 times, once per second) ...
 Waiting for original device to vanish ...
 Original device can't be accessed anymore. Good.
 Searching for target devices ...
 Searching for target devices ...
 Searching for target devices ...
 Searching for target devices ...
 Searching for target devices ...
 No new devices in target mode or class found

Mode switch has failed. Bye.


But it fail. I dont understand the problem, because I have support for the driver:
$ modinfo option | grep "v12D1p140Cd"
alias: usb:v12D1p140Cd*dc*dsc*dp*icFFiscFFipFF*

But the device dont init as modem.

madbiologist (me-again) wrote :

A new version (1.1.0-2) of usb-modeswitch was added to the Lucid repositories 5 days ago (approximately 2 days after you reported this bug).

Can you update to the new version and test?

Changed in linux (Ubuntu):
status: New → Incomplete
tags: added: kernel-series-unknown
Paul van Genderen (paulvg) wrote :

I think this has to do with usb-modeswitch, this program is responsible for ensuring USB devices don't end up showing up as CD-ROM drives with Windows drivers.

affects: linux (Ubuntu) → usb-modeswitch (Ubuntu)
Changed in usb-modeswitch (Ubuntu):
status: Incomplete → Confirmed
Paul van Genderen (paulvg) wrote :

I have 2 USB modems, Huawei E180 and Huawei E1820. The former worked fine in Ubuntu 9.04 and 9.10, but not in 10.04 as of 21-03-2010. The E1820 was detected as a 3G device in Ubuntu 9.10 but it could not connect.

Both devices now show up as CD-ROM drives. I've nominated this for Lucid because people generally don't expect to lose their Internet connection after an upgrade (going on a limb here ;)).

Didier Raboud (odyx) on 2010-03-21
Changed in usb-modeswitch (Ubuntu):
assignee: nobody → Didier Raboud (odyx)
Paul van Genderen (paulvg) wrote :

Also known as "T-Mobile Internet Stick II" (probably among others).

summary: - Huawei E1612 modem unable to connect under Lucid
+ Huawei 3G modem unable to connect under Lucid

Hi Angel Guzman Maeso,

From your bugreport:

> I install usb-modeswitch:
> $ sudo apt-get install usb-modeswitch

That's good.

> Then I add this lines to /etc/usb_modeswitch.conf:
> (...)
> And I run the usb-modemswitch:
> $ sudo usb_modeswitch

That's not good.

Please upgrade usb-modeswitch to the latest version in Lucid and make sure you have "usb-modeswitch-data" installed.

Then unplug and re-plug your USB dongle. It should be detected correctly (thanks to the /etc/usb_modeswitch.d/12d1\:1446 file).



Paul van Genderen (paulvg) wrote :

With the old karmic kernel (2.6.31-19-generic), the Huawei E180 does get detected as a 3G modem (and CD-ROM drive at the same time), and I can connect to XS4ALL (not T-Mobile). On the first attempt it always fails, then I have to unplug the modem, enter login credentials and PIN code in the settings, and plug it in again.

This could be a kernel issue related to #520372 .

Paul van Genderen (paulvg) wrote :

OTOH, I'm not seeing the "Receive serial link..." error in the logs for either USB modem. Sorry for mentioning it.

Didier Raboud (odyx) wrote :

Re-assigning to -data as rules are in that package.

affects: usb-modeswitch (Ubuntu) → usb-modeswitch-data (Ubuntu)


Installing usb-modeswitch with
$ sudo apt-get install usb-modeswitch

solve the problem for me in Lucid (as of 03/25/2010).
I'm using Huawei e1553 3g modem and now I'm able to connect from it just like they did in Karmic.


Didier Raboud (odyx) wrote :

Angel Guzman> Please answer. Without answer from you in 2 weeks, I'll close this bug as invalid.

Paul van Genderen (paulvg) wrote :

As this bug affects several different types of Huawei modems, I consider it entirely possible that other models that are currently untested are affected as well. Furthermore, given that this bug spans several different models (as per my own test results for instance), there could be a common root cause. Alleviating the problem here could very well fix connectivity problems in Lucid with Huawei 3G modems all across their product line.

Therefore I, for one and with all due respect, reject the idea that an answer from Angel Guzman is necessary in order to further triage the bug at this point. At least until it has been made certain that different models have to be fixed individually. Also, invalid status typically means a new bug could not be confirmed which is patently false in this case.

A newer kernel (-18) has been published in the mean time, and I will provide test results using the latest packages. Failing that, I will attempt the workaround provided by Rainer Oliveira.

At the moment, I can merely confirm that usb-modeswitch does not seem to be included by default in a desktop installation of Lucid. However, it appears that this also goes for Ubuntu 9.10.

Didier Raboud (odyx) wrote :

Paul: IMHO, this bug is just a result of the move of the switching functionality from udev (modem-modeswitch) to usb-modeswitch.

Installing lucid's usb-modeswitch seems to solve all the reported issues (without hand-tweaking needed) and the only remaining issue that you seem to mention is that usb-modeswitch is not included by default on Lucid. This is NOT a bug in usb-modeswitch. [In Debian, network-manager recommends modemmanager, which recommends usb-modeswitch, so usb-modeswitch gets installed with network-manager.]

Therefor, if Angel can confirm that installing lucid's usb-modeswitch solves his issue, this bug can be closed (with whatever resolution).

Paul van Genderen (paulvg) wrote :

Instead of closing this bug, it could perhaps be best to change the package it affects to network-manager.

Anyway, I tested the E180 and it works perfectly now, without having to install usb-modeswitch. The E1820 only works after installing usb-modeswitch so that seems to be a separate issue entirely, since it failed to work in my tests using current and older Ubuntu versions.

Didier Raboud (odyx) wrote :

Not a bug of usb-modeswitch. If it must be set default, so be it.

affects: usb-modeswitch-data (Ubuntu) → modemmanager (Ubuntu)
Changed in modemmanager (Ubuntu):
assignee: Didier Raboud (odyx) → nobody
summary: - Huawei 3G modem unable to connect under Lucid
+ usb-modeswitch should be included by default on Lucid

Sorry for delay, I am busy with work.

I have the lastest updates with lucid and it still dont work:

$ usb_modeswitch --version

 * usb-modeswitch: handle USB devices with multiple modes
 * Version 1.1.0 (C) Josua Dietze 2010
 * Based on libusb 0.1.12


$ dpkg -l usb-modeswitch
| Status=Not/Inst/Cfg-files/Unpacked/Failed-cfg/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name Version Description
ii usb-modeswitch 1.1.0-2 mode switching tool for controlling "flip flop" USB devices

$ dpkg -l usb-modeswitch-data
| Status=Not/Inst/Cfg-files/Unpacked/Failed-cfg/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name Version Description
ii usb-modeswitch-data 20100127-1 mode switching data for usb-modeswitch

$ uname -a
Linux magmus 2.6.32-18-generic-pae #27-Ubuntu SMP Fri Mar 26 21:21:16 UTC 2010 i686 GNU/Linux

Angel Guzman Maeso (shakaran) wrote :
Download full text (5.9 KiB)

Testing with another linux box. Without previous configurations or packages:

First, I plug the stick. Then appear two icons new "Unidad de CD: movistar" (movistar is the mobile company, and in english says "CD unit: movistar", and the second icon "HUAWEI MMC Storage". This device have a internal rom memory that stores the programs and drivers for windows and some manuals, that it have low capacity, about 20.8 MB occupied (I dont see fit it have free space on nautilus). The MMC Storage is a card reader on the stick. I can attach a memory for the stick on it.

But only that, no GSM modem.

Then I install the packages:

sudo apt-get install usb-modeswitch
[sudo] password for shakaran:
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
Suggested packages:
  comgt wvdial
The following NEW packages will be installed:
  usb-modeswitch usb-modeswitch-data
0 upgraded, 2 newly installed, 0 to remove and 47 not upgraded.
Need to get 43.7kB of archives.
After this operation, 606kB of additional disk space will be used.
Do you want to continue [Y/n]? y
Get:1 http://es.archive.ubuntu.com/ubuntu/ lucid/universe usb-modeswitch-data 20100127-1 [10.2kB]
Get:2 http://es.archive.ubuntu.com/ubuntu/ lucid/universe usb-modeswitch 1.1.0-2 [33.4kB]
Fetched 43.7kB in 0s (77.9kB/s)
Selecting previously deselected package usb-modeswitch-data.
(Reading database ... 307350 files and directories currently installed.)
Unpacking usb-modeswitch-data (from .../usb-modeswitch-data_20100127-1_all.deb) ...
Selecting previously deselected package usb-modeswitch.
Unpacking usb-modeswitch (from .../usb-modeswitch_1.1.0-2_i386.deb) ...
Processing triggers for man-db ...
Setting up usb-modeswitch-data (20100127-1) ...
Setting up usb-modeswitch (1.1.0-2) ...
localepurge: Disk space freed in /usr/share/locale: 0 KiB
localepurge: Disk space freed in /usr/share/man: 0 KiB
localepurge: Disk space freed in /usr/share/gnome/help: 0 KiB
localepurge: Disk space freed in /usr/share/omf: 0 KiB
localepurge: Disk space freed in /usr/share/doc/kde/HTML: 0 KiB

Total disk space freed by localepurge: 0 KiB

$ uname -a
Linux otorion 2.6.32-2-generic #2-Ubuntu SMP Sat Oct 31 17:07:12 UTC 2009 i686 GNU/Linux

From dmesg:
[ 8641.819229] usb 1-3: configuration #1 chosen from 1 choice
[ 8641.992533] Initializing USB Mass Storage driver...
[ 8641.993864] scsi2 : SCSI emulation for USB Mass Storage devices
[ 8641.999109] usb-storage: device found at 3
[ 8641.999112] usb-storage: waiting for device to settle before scanning
[ 8642.002968] scsi3 : SCSI emulation for USB Mass Storage devices
[ 8642.003215] usbcore: registered new interface driver usb-storage
[ 8642.003219] USB Mass Storage support registered.
[ 8642.019210] usb-storage: device found at 3
[ 8642.019214] usb-storage: waiting for device to settle before scanning
[ 8647.000451] usb-storage: device scan complete
[ 8647.001181] scsi 2:0:0:0: CD-ROM HUAWEI Mass Storage 2.31 PQ: 0 ANSI: 2
[ 8647.018042] sr1: scsi-1 drive
[ 8647.019032] sr 2:0:0:0: Attached scsi CD-ROM sr1
[ 8647.019115] sr 2:0:0:0: Attached ...


iav (iav) wrote :

Angel, do you see a card reader content when modem is connected?

Angel Guzman Maeso (shakaran) wrote :

Yes, if I insert a MicroSD card of 8 GB on the slot, and it appears and the broadband moble too and I can connect (I post now with the modem ;) ), but the internal memory (of Movistar) doesn't appear.

Karunadheera (karunadheera) wrote :

E1750 also shows as a usb mass storage. No modems are detected in Lucid beta2.

novatillasku (novatillasku) wrote :

Hello everyone ..
Yesterday I installed Ubuntu 10.04 and Huawei E1612 not working. It was detected as USB and CD.
Today I have installed usb_modeswich from this page, two packages.


I have already restarted and in " Equipment" 'appears in connection modem.. network connection too in network-manager and I connected to internet!

Now i can stay in Lucid ;-)

Got Huawei E1820 working on Ubuntu 10.04 after installing usb-modeswitch.

Huawei E1550 3G modem was unable to connect under Ylmf OS 3.0, which is based on Ubuntu 10.04. But Huawei E1550 3G modem was able to connect after installing usb-modeswitch.

I just installed 9.10 and then performed a distribution upgrade to 10.04 my only internet access being an E620 modem.

The Modem is recognised in Karmic allowing the packages for the upgrade to be installed.
However at some point in the upgrade the modem is only recognised as a mass storage device.
meaning when I reboot I have no internet connection.

However having been through this before I have


both stored on the mini sd card in the modem.

using gdebi I install them ignoring the warning about both packages being available in a software channel as I plainly can't connect to the afore mentioned channel due to both of these packages not being installed as part of the upgrade.

reinserting the device the mode change is performed and the connection which was configured in karmic connects allowing me to make this comment.

Obviously the upgrade script needs modifying to include the download and installation of these 2 files.
something which I thought had been established prior to the release of Lucid in early April it is rather disappointing that in mid August this still hasn't happened.

Martin Pitt (pitti) wrote :

modem-modeswitch is deprecated and got removed from udev upstream (See http://git.kernel.org/?p=linux/hotplug/udev.git;a=commitdiff;h=4dd9b291354e76f34b0d6d7b5c3b28d03a624418). Upstream recommends using usb-modeswitch now, so we really should switch that in maverick still. Unfortunately we missed FF for this. Can this please get a feature freeze exception?

This also blocks updating udev to a newer version.

summary: - usb-modeswitch should be included by default on Lucid
+ usb-modeswitch should be included by default on Maverick
summary: - usb-modeswitch should be included by default on Maverick
+ FFE: usb-modeswitch should be included by default on Maverick
StefanPotyra (sistpoty) wrote :

as discussed in the meeting, FFe granted for usb-modeswitch

Changed in usb-modeswitch (Ubuntu Maverick):
status: New → Confirmed
Martin Pitt (pitti) wrote :

modemmanager already recommends usb-modeswitch, so we just need to promote it.

I reviewed usb-modeswitch under a MIR perspective, and it's basically doing the same than modem-modeswitch, except that it is maintained (and modem-modeswitch will go away, see bug 620977). Packaging looks fine, and is well maintained upstream and in Debian. MIR approved.

Changed in modemmanager (Ubuntu Maverick):
status: Confirmed → Fix Released
Changed in modemmanager:
status: New → Invalid
Martin Pitt (pitti) wrote :

Promoted usb-modeswitch and -data.

Changed in usb-modeswitch (Ubuntu Maverick):
status: Confirmed → Fix Released
Paul van Genderen (paulvg) wrote :

Wow, this is so great I don't even know how to begin to thank you.

Just... Thank you SO MUCH!

Alexander Sack (asac) wrote :

unsubscribing ubuntu MIR team as the baltix task keeps this from disappearing from MIR team list.

Scott Kitterman (kitterman) wrote :

Same for ubuntu-release (unsubscribing).

Giovanni Bajo (giovannibajo) wrote :

So basically there is no way to fix this for Lucid users, short of telling them one by one to install the package?

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers