[Bug 1193815] [NEW] Huawei E3131 gives error when plugged in

Juha Jeronen 1193815 at bugs.launchpad.net
Sun Jun 23 11:18:16 UTC 2013


Public bug reported:

In Ubuntu 13.04, the Huawei E3131 (correctly) switches to modem mode
upon insertion (and works), but while the device is still in storage
mode, Ubuntu tries to automatically mount the storage device, which then
disappears upon modeswitching. The result is an error dialog with
content similar to [1], which the user must ok each time the device is
plugged in.

[1] https://answers.launchpad.net/ubuntu/+question/219742

The device is branded "DNA" (Finland), device IDs are 12d1:151a (storage
mode), 12d1:151d (modem mode).

I was able to get rid of the error by editing the udev rules. To prevent
Ubuntu from automounting the storage, it can be ejected by udev before
running the modeswitch command.

I did this by copying /lib/udev/40-usb_modeswitch.rules to
/etc/udev/rules.d/usb_modeswitch_customized.rules (to create an
override) and then changing

---8<---8<---8<---

# Huawei E392u-12
ATTRS{idVendor}=="12d1", ATTRS{idProduct}=="151a", RUN+="usb_modeswitch '%b/%k'"

---8<---8<---8<---

to

---8<---8<---8<---

# Huawei E392u-12, DNA (FI) Huawei E3131
ATTRS{idVendor}=="12d1", ATTRS{idProduct}=="151a", RUN+="eject -s '%b/%k'"
ATTRS{idVendor}=="12d1", ATTRS{idProduct}=="151a", RUN+="usb_modeswitch '%b/%k'"

---8<---8<---8<---

i.e. by adding the eject command (the SCSI mode "-s" is important). This
gets rid of the error dialog.

It would be nice if this was fixed in the official package.

Finally, note that the storage device still reappears after the
modeswitch, but this is a problem in the E3131 itself (apparently rather
common in USB mobile modems). After the switch, it appears as both a
modem and a storage device (where the storage contains the Windows
drivers). I haven't found a workaround for this part.

** Affects: udev (Ubuntu)
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to udev in Ubuntu.
https://bugs.launchpad.net/bugs/1193815

Title:
  Huawei E3131 gives error when plugged in

Status in “udev” package in Ubuntu:
  New

Bug description:
  In Ubuntu 13.04, the Huawei E3131 (correctly) switches to modem mode
  upon insertion (and works), but while the device is still in storage
  mode, Ubuntu tries to automatically mount the storage device, which
  then disappears upon modeswitching. The result is an error dialog with
  content similar to [1], which the user must ok each time the device is
  plugged in.

  [1] https://answers.launchpad.net/ubuntu/+question/219742

  The device is branded "DNA" (Finland), device IDs are 12d1:151a
  (storage mode), 12d1:151d (modem mode).

  I was able to get rid of the error by editing the udev rules. To
  prevent Ubuntu from automounting the storage, it can be ejected by
  udev before running the modeswitch command.

  I did this by copying /lib/udev/40-usb_modeswitch.rules to
  /etc/udev/rules.d/usb_modeswitch_customized.rules (to create an
  override) and then changing

  ---8<---8<---8<---

  # Huawei E392u-12
  ATTRS{idVendor}=="12d1", ATTRS{idProduct}=="151a", RUN+="usb_modeswitch '%b/%k'"

  ---8<---8<---8<---

  to

  ---8<---8<---8<---

  # Huawei E392u-12, DNA (FI) Huawei E3131
  ATTRS{idVendor}=="12d1", ATTRS{idProduct}=="151a", RUN+="eject -s '%b/%k'"
  ATTRS{idVendor}=="12d1", ATTRS{idProduct}=="151a", RUN+="usb_modeswitch '%b/%k'"

  ---8<---8<---8<---

  i.e. by adding the eject command (the SCSI mode "-s" is important).
  This gets rid of the error dialog.

  It would be nice if this was fixed in the official package.

  Finally, note that the storage device still reappears after the
  modeswitch, but this is a problem in the E3131 itself (apparently
  rather common in USB mobile modems). After the switch, it appears as
  both a modem and a storage device (where the storage contains the
  Windows drivers). I haven't found a workaround for this part.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/udev/+bug/1193815/+subscriptions




More information about the foundations-bugs mailing list