After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 665630 - Can't hot swap mobile broadband modem
Can't hot swap mobile broadband modem
Status: RESOLVED FIXED
Product: NetworkManager
Classification: Platform
Component: ModemManager
0.9.x
Other Linux
: Normal major
: ---
Assigned To: Dan Williams
NetworkManager maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2011-12-05 22:31 UTC by gianted
Modified: 2013-02-02 10:06 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
The dmesg output, as requested. (658 bytes, application/octet-stream)
2011-12-16 23:14 UTC, gianted
Details
Grabbed the NetworkManager debug logs (70.34 KB, text/x-log)
2011-12-16 23:16 UTC, gianted
Details
Troubleshooting detailed here (9.00 KB, text/plain)
2011-12-16 23:19 UTC, gianted
Details
The modem-manager.log as required. (63.10 KB, text/x-log)
2011-12-26 20:11 UTC, gianted
Details
Grabbed a new NetworkManager debug log (13.05 KB, text/x-log)
2011-12-26 20:14 UTC, gianted
Details
What happens when the modem could work (31.40 KB, text/plain)
2013-01-31 23:25 UTC, gianted
Details
What happens when the modem could't work (25.71 KB, text/plain)
2013-01-31 23:26 UTC, gianted
Details
The logging when all works good (48.41 KB, text/plain)
2013-02-02 10:00 UTC, gianted
Details

Description gianted 2011-12-05 22:31:56 UTC
As suggested to me here 

https://bugs.kde.org/show_bug.cgi?id=288203

I'm going to create this bug report.

As I explain here:

https://bugs.kde.org/show_bug.cgi?id=288121

I can't connect my Huawei USB Modem – model E156G.

$ lsusb | grep 'Huawei'
Bus 001 Device 010: ID 12d1:1003 Huawei Technologies Co., Ltd. E220 HSDPA Modem
/ E230/E270 HSDPA/HSUPA Modem

after a hot swapping. I can manage mobile broadband connection only if I start
the
system with the dongle plugged-in before power-on.

Reproducible: Always

Steps to Reproduce:
Plug-in the modem.
System power-on.
Fill the requester with PIN, root password (now you can work with the modem).
Unplug the modem.
Plug again the modem.

Actual Results:  
The only way to work with the modem is to restart the system with the device
plugged-in.

Expected Results:  
I can unplug the modem, plug it again and work with it without problem (as I
can with previous KDE version / Network Management - e.g. Kubuntu 10.04).

Can someone help me, please?

Thanks in advance...
Comment 1 Dan Williams 2011-12-16 00:43:15 UTC
Can you provide 'dmesg' output when you plug the dongle in?  It may not be switched correctly.  After that, grab ModemManager debugging output as described here:

http://live.gnome.org/NetworkManager/Debugging

and we'll see if ModemManager is finding the device correctly after it's being inserted.
Comment 2 gianted 2011-12-16 23:14:27 UTC
Created attachment 203706 [details]
The dmesg output, as requested.
Comment 3 gianted 2011-12-16 23:16:02 UTC
Created attachment 203707 [details]
Grabbed the NetworkManager debug logs
Comment 4 gianted 2011-12-16 23:19:57 UTC
Created attachment 203708 [details]
Troubleshooting detailed here

$ NetworkManager --version
Failed to read classid file: Object not found
0.9.1.90

> why the error message above? I've seen that often...

Maybe you're not properly in charge for this issue, but just FYI: during a 
NetworkManager restart, often I noticed some KDE Plasma crashes.
Unfortunately the network wasn't available in these moments, so I can't 
provide any debug info - post-mortem. 

> I should redirect this issue to Plasma Developers?
Comment 5 Jiri Klimes 2011-12-20 09:40:44 UTC
Please include also logs from modem-manager as described in 
http://live.gnome.org/NetworkManager/Debugging#NM_3G_08_09

(In reply to comment #4)
> $ NetworkManager --version
> Failed to read classid file: Object not found
> 0.9.1.90
> 
It's from libnl3: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=632790

> > why the error message above? I've seen that often...
> 
> Maybe you're not properly in charge for this issue, but just FYI: during a 
> NetworkManager restart, often I noticed some KDE Plasma crashes.
> Unfortunately the network wasn't available in these moments, so I can't 
> provide any debug info - post-mortem. 
> 
> > I should redirect this issue to Plasma Developers?

Of course, get the backtrace (e.g. from KDE crash assistant) and file a bug at bugs.kde.org
Comment 6 gianted 2011-12-26 20:11:29 UTC
Created attachment 204231 [details]
The modem-manager.log as required.
Comment 7 gianted 2011-12-26 20:14:29 UTC
Created attachment 204232 [details]
Grabbed a new NetworkManager debug log

Substitutes the old log. Grabbed only when experiencing the bug (hot-plugging the modem). The dmesg output is unchanged.
Comment 8 gianted 2011-12-26 20:31:47 UTC
(In reply to comment #5)
> Please include also logs from modem-manager as described in 
> http://live.gnome.org/NetworkManager/Debugging#NM_3G_08_09
> 
> (In reply to comment #4)
> > $ NetworkManager --version
> > Failed to read classid file: Object not found
> > 0.9.1.90
> > 
> It's from libnl3: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=632790
> 

I installed also libnl3-dbg libnl3-dev through apt-get, but classid file seems not installed yet. Can you suggest me how to report this issue, since the bug is Debian related but I'm using Kubuntu? I must open a Kubuntu bug then refer to above Debian bug?
Comment 9 Jiri Klimes 2012-01-09 13:32:07 UTC
(In reply to comment #6)
> Created an attachment (id=204231) [details]
> The modem-manager.log as required.

The problem could be caused by commit
http://cgit.freedesktop.org/ModemManager/ModemManager/commit/?id=dc89c0a42d826fc3302b3d790d5161945ff7078f
which reworks Huawei modem ports probing.

See this for more debugging of the bug:
https://bugs.launchpad.net/ubuntu/+source/modemmanager/+bug/868034

According to the log, there's unexpected hangout on command 'AT^CURC=0' (switching off unsolicited messages). Would you try connect to the modem via minicom and send that command to see how the modem behave?

(In reply to comment #8)
> (In reply to comment #5)
> > Please include also logs from modem-manager as described in 
> > http://live.gnome.org/NetworkManager/Debugging#NM_3G_08_09
> > 
> > (In reply to comment #4)
> > > $ NetworkManager --version
> > > Failed to read classid file: Object not found
> > > 0.9.1.90
> > > 
> > It's from libnl3: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=632790
> > 
> 
> I installed also libnl3-dbg libnl3-dev through apt-get, but classid file seems
> not installed yet. Can you suggest me how to report this issue, since the bug
> is Debian related but I'm using Kubuntu? I must open a Kubuntu bug then refer
> to above Debian bug?

Yes, open the Ubuntu bug with reference to the Debian bug. It appears that the fix has already been done for Debian.
Comment 10 Akhil Laddha 2012-02-22 09:53:04 UTC
gianted, were you able to collect more information as requested in comment#9 ?
Comment 11 Dan Williams 2012-02-26 03:01:26 UTC
Note that we've reverted the commit Jiri mentions for 0.5.2, so testing with this version when it's released would be greatly appreciated.
Comment 12 gianted 2012-02-26 22:23:56 UTC
(In reply to comment #11)
> Note that we've reverted the commit Jiri mentions for 0.5.2, so testing with
> this version when it's released would be greatly appreciated.

Honestly, I don't understand, sorry... what I have to do? Repeat the 
tests with

3.0.0-16-generic #28-Ubuntu SMP Fri Jan 27 17:50:54 UTC 2012

is best? Time has passed and now I can not remember well...

Nowadays, I'm using my modem as explained before: I have to restart 
the system if I plug-in it when the system is running, otherwhise... 
nothing to do!

Please help me to help... 

Thank you
Comment 13 Akhil Laddha 2012-06-18 16:13:22 UTC
gainted, you need to test ModemManager version 0.5.2
Comment 14 Tobias Mueller 2013-01-14 22:00:45 UTC
gainted, ping.
Comment 15 gianted 2013-01-20 15:10:12 UTC
sorry for my huge delay... now I'm using another distro (Fedora 17 - KDE spin), but I have issues again. I've contacted the maintainer of Plasma NM and now I'm trying to solve problems with the Mobile Broadband connection. So I reply to you soon. I have now ModemManager-0.6.0.0-1.fc17.i686.
Comment 16 gianted 2013-01-30 10:42:36 UTC
Now I'm back with Kubuntu 12.04 (KDE 4.9.5)

Again, the things seems to work only if I start the system with the modem plugged-in.

After a cold plug, I can unplug and plug again the modem and Plasma NM (and thus, NetworkManager | ModemManager) recognise and give me the chance to connect to internet again.

But if start the system without the modem, the only way to get it connected is to use the Sakis3g script.

Now I'm going to troubleshoot and file again some logs, hoping that will help.
Comment 17 gianted 2013-01-31 23:25:11 UTC
Created attachment 234941 [details]
What happens when the modem could work
Comment 18 gianted 2013-01-31 23:26:59 UTC
Created attachment 234942 [details]
What happens when the modem could't work
Comment 19 gianted 2013-01-31 23:30:43 UTC
The issue is not always reproducible now.

So I tried to make the things clearer attaching the report above.

Let me know if and how I have to use minicom as suggested by Jiri here:

https://bugzilla.gnome.org/show_bug.cgi?id=665630#c9

Hope this help you (and me) soon...

All the best.
Comment 20 Aleksander Morgado 2013-02-01 09:26:23 UTC
There were quite some improvements for Huawei modems in the latest stable ModemManager versions (0.6.x); and I believe the E156G handling is improved quite a lot. AFAIK Ubuntu/Kubuntu 12.10 already has 0.6, and you probably can just grab the .deb from 12.10 and install it in 12.04 for testing. Could you do that?

Anyway, looking at your logs, the weirdest thing is that in the error case you get that:
 (ttyUSB0): --> 'AT+GCAP<CR>'
 (ttyUSB0) unexpected port hangup!

Kind of the port disappearing before we get the reply and then we end up looping all the other port probings. Testing with 0.6.x would be really appreciated...
Comment 21 gianted 2013-02-02 10:00:27 UTC
Created attachment 235055 [details]
The logging when all works good
Comment 22 gianted 2013-02-02 10:06:42 UTC
(In reply to comment #20)
> There were quite some improvements for Huawei modems in the latest stable
> ModemManager versions (0.6.x); and I believe the E156G handling is improved
> quite a lot. AFAIK Ubuntu/Kubuntu 12.10 already has 0.6, and you probably can
> just grab the .deb from 12.10 and install it in 12.04 for testing. Could you do
> that?
> 
> Anyway, looking at your logs, the weirdest thing is that in the error case you
> get that:
>  (ttyUSB0): --> 'AT+GCAP<CR>'
>  (ttyUSB0) unexpected port hangup!
> 
> Kind of the port disappearing before we get the reply and then we end up
> looping all the other port probings. Testing with 0.6.x would be really
> appreciated...

Hi Aleksander, thanks for your quick reply.

Now with modemmanager v.0.6 it seems very good.

I tried a lot of times and now the modem works in different ways.

If useful, I've filed a report again.

I think was crucial the modemmanager upgrade, even if not painful at all.

Installing modemmanager v.0.6 in Kubuntu 12.04, I had to reconfigure the X server (since are required some dependencies of 12.10 distribution, the screen appeared dark after the reboot).

A workaround for me was:

- ensure an internet connection (e.g. a working eth0 with DSL).
- reboot (forced if necessary)
- choose to start Linux with a "recovery session"
- at recovery tool prompt choose "enable network" and "repair packet" or similar
- reboot again

And now I have my Plasma NM working like a charm.

All the best and thanks again.

--
gianted

PS. Hope it's right for me to put "Resolved | Fixed"...