Summary: | 3G connections not working at all when using knetworkmanager | ||
---|---|---|---|
Product: | [Unmaintained] Network Management | Reporter: | Marc Schiffbauer <mschiff> |
Component: | general | Assignee: | Will Stephenson <wstephenson> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | lamarque, nt1277 |
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | Gentoo Packages | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: | |||
Attachments: | nm-applet dialog (german) |
Description
Marc Schiffbauer
2011-01-23 15:13:18 UTC
PIN unlock is not implemented in Plasma NM yet. It used to work months ago. So it is a regression. What I meant is that Plasma NM will not ask for the PIN on demand, though after running Mobile Connection Wizard you can add the PIN number in the connection's configuration. This is the old way of configuring mobile connections, so it should also work with all knetworkmanager/Plasma NM versions. The information will be sent to NetworkManager which will re-route it to ModemManager and everything should work. In fact, it works with my modem (a Sony MD300), except for one detail: my modem is too slow to startup and the NetworkManager timeout (10 seconds) is too short. I had to increase it to 30s to make it really work here. The timeout is hardcoded in NM source code, so to change it you will have to recompile NetworkManager. NM needs to "enable" the modem before dialing, which includes starting the modem up and asking for the PIN. nm-applet can continues the startup process while the user is typing the PIN, which gives it more time to startup before sending the PIN to the modem. Unfortunately, Plasma NM send the pin right after initiating the startup process, which makes NM's 10 second timeout to... time out. The best solution to this problem is increasing the NM timeout, which in my opinion is a good thing since 10s is really short for most modems I have tested to startup. (In reply to comment #3) Thanks for your comment. What is the problem with asking for a PIN? Is this a planned feature? What is a bit strange here in my setup is: I have a PIN in the connection setting, but it does not seem to be used by either nm-applet nor knm. But nm-applet then asks for the PIN while knm does not. So my only option right now is to always disable/stop NM handling in kde systemsettings and then start nm-applet whenever I need to use my 3G connection. What about the plans to merge nm-applet and knm connection setting store? Yesterday I noticed that Plasma NM already ask for the PIN when needed and records it in a kwallet. So you should not have this problem as long as you increase the NetworkManager timeout as I said. I am not aware of any plan to merge nm-applet and Plasma NM configuration settings. Please send the /var/log/messages file, that file contains the NetworkManager logs. That file tends to be very big (mine is 41 MB large), so please remove the lines before your connection attempt to make it smaller. By the way, are you using the latest Plasma NM git version (knetworkmanager-9999 in Gentoo)? (In reply to comment #5) > Yesterday I noticed that Plasma NM already ask for the PIN when needed and > records it in a kwallet. So you should not have this problem as long as you > increase the NetworkManager timeout as I said. I am not convinced that this is a NM timeout issue because if it was nm-applet must not work too, but it does perfectly! I just tried with the current knetworkmanager (git pulled few minutes ago) If I delete the PIN and PUK from the connection it indeed asks me for the PIN with the same dialog from the settings where I can enter PIN and PUK and so on. But it just tells me "Connection failed" withi some knotify message after I entered the corerct PIN. This is the log: 2011-03-13T22:26:42.015041+01:00 bart NetworkManager[7046]: <info> (ttyUSB0): new GSM device (driver: 'option1' ifindex: -1) 2011-03-13T22:26:42.015078+01:00 bart NetworkManager[7046]: <info> (ttyUSB0): exported as /org/freedesktop/NetworkManager/Devices/10 2011-03-13T22:26:42.015089+01:00 bart NetworkManager[7046]: <info> (ttyUSB0): now managed 2011-03-13T22:26:42.015109+01:00 bart NetworkManager[7046]: <info> (ttyUSB0): device state change: 1 -> 2 (reason 2) 2011-03-13T22:26:42.017281+01:00 bart NetworkManager[7046]: <info> (ttyUSB0): deactivating device (reason: 2). 2011-03-13T22:26:42.019707+01:00 bart NetworkManager[7046]: <info> (ttyUSB0): device state change: 2 -> 3 (reason 0) 2011-03-13T22:26:48.408577+01:00 bart NetworkManager[7046]: <info> Activation (ttyUSB0) starting connection 'T-Mobile (D1)' 2011-03-13T22:26:48.408597+01:00 bart NetworkManager[7046]: <info> (ttyUSB0): device state change: 3 -> 4 (reason 0) 2011-03-13T22:26:48.408604+01:00 bart NetworkManager[7046]: <info> Activation (ttyUSB0) Stage 1 of 5 (Device Prepare) scheduled... 2011-03-13T22:26:48.408611+01:00 bart NetworkManager[7046]: <info> Activation (ttyUSB0) Stage 1 of 5 (Device Prepare) started... 2011-03-13T22:26:48.408618+01:00 bart NetworkManager[7046]: <info> (ttyUSB0): device state change: 4 -> 6 (reason 0) 2011-03-13T22:26:48.408624+01:00 bart NetworkManager[7046]: <info> Activation (ttyUSB0) Stage 1 of 5 (Device Prepare) complete. 2011-03-13T22:26:48.539002+01:00 bart NetworkManager[7046]: <info> Activation (ttyUSB0) Stage 1 of 5 (Device Prepare) scheduled... 2011-03-13T22:26:48.539022+01:00 bart NetworkManager[7046]: <info> Activation (ttyUSB0) Stage 1 of 5 (Device Prepare) started... 2011-03-13T22:26:48.539029+01:00 bart NetworkManager[7046]: <info> (ttyUSB0): device state change: 6 -> 4 (reason 0) 2011-03-13T22:26:48.539035+01:00 bart NetworkManager[7046]: <info> Activation (ttyUSB0) Stage 1 of 5 (Device Prepare) complete. 2011-03-13T22:26:48.540354+01:00 bart NetworkManager[7046]: <warn> GSM modem enable failed: (32) SIM PIN required 2011-03-13T22:26:51.766854+01:00 bart NetworkManager[7046]: <info> WWAN now enabled by radio killswitch 2011-03-13T22:26:53.552553+01:00 bart kernel: option: option_instat_callback: error -84 2011-03-13T22:26:53.936585+01:00 bart kernel: option: option_instat_callback: error -84 2011-03-13T22:26:54.030234+01:00 bart NetworkManager[7046]: <warn> GSM connection failed: (32) Serial port is now closed 2011-03-13T22:26:54.030264+01:00 bart NetworkManager[7046]: <info> (ttyUSB0): device state change: 4 -> 9 (reason 1) 2011-03-13T22:26:54.030274+01:00 bart NetworkManager[7046]: <info> Marking connection 'T-Mobile (D1)' invalid. 2011-03-13T22:26:54.030278+01:00 bart kernel: option: option_instat_callback: error -108 2011-03-13T22:26:54.030284+01:00 bart NetworkManager[7046]: <warn> Activation (ttyUSB0) failed. 2011-03-13T22:26:54.030294+01:00 bart kernel: option1 ttyUSB0: GSM modem (1-port) converter now disconnected from ttyUSB0 2011-03-13T22:26:54.030297+01:00 bart NetworkManager[7046]: <info> (ttyUSB0): device state change: 9 -> 3 (reason 0) 2011-03-13T22:26:54.030301+01:00 bart kernel: option 5-2:1.0: device disconnected 2011-03-13T22:26:54.030307+01:00 bart NetworkManager[7046]: <info> (ttyUSB0): deactivating device (reason: 0). 2011-03-13T22:26:54.030308+01:00 bart kernel: option1 ttyUSB1: GSM modem (1-port) converter now disconnected from ttyUSB1 2011-03-13T22:26:54.030313+01:00 bart kernel: option 5-2:1.1: device disconnected 2011-03-13T22:26:54.039001+01:00 bart NetworkManager[7046]: <info> Policy set 'Ostel' (wlan0) as default for IPv4 routing and DNS. 2011-03-13T22:26:54.039018+01:00 bart NetworkManager[7046]: <info> Policy set 'Ostel' (wlan0) as default for IPv4 routing and DNS. 2011-03-13T22:26:54.039024+01:00 bart NetworkManager[7046]: <info> (ttyUSB0): now unmanaged So currect status: Still not working but still working when using nm-applet. Now the interesting part: I noticed some really different behavior when using nm-applet: Although it has the PIN configured in its settings it will always ask me for the PIN to unlock the *device* and only after that it will start blinking blue (which means it can reach a 3G network). Then when I start the connection, it needs access to the gnome-keyring to get the PIN from there to which is required to initiate the connection. So it seems nm-applet is doing an important and required step that knetworkmanager does not do: Unlocking the device somehow. This is the log when I use nm-applet to unlock the device and successfully connect to the 3G network. 2011-03-13T22:44:41.014403+01:00 bart NetworkManager[7046]: <info> (ttyUSB0): new GSM device (driver: 'option1' ifindex: -1) 2011-03-13T22:44:41.014750+01:00 bart NetworkManager[7046]: <info> (ttyUSB0): exported as /org/freedesktop/NetworkManager/Devices/16 2011-03-13T22:44:41.014771+01:00 bart NetworkManager[7046]: <info> (ttyUSB0): now managed 2011-03-13T22:44:41.014823+01:00 bart NetworkManager[7046]: <info> (ttyUSB0): device state change: 1 -> 2 (reason 2) 2011-03-13T22:44:41.018024+01:00 bart NetworkManager[7046]: <info> (ttyUSB0): deactivating device (reason: 2). 2011-03-13T22:44:41.024779+01:00 bart NetworkManager[7046]: <info> (ttyUSB0): device state change: 2 -> 3 (reason 0) --> NOW the dialog as shown in the attached screenshot appears asking for the PIN to unlock the device. I enter the correct pin. Before hitting enter I write this text, so its longer than the 10 seconds timeout... Enter! 2011-03-13T22:46:21.700393+01:00 bart modem-manager[7085]: <info> (ttyUSB0) opening serial port... 2011-03-13T22:46:21.797813+01:00 bart modem-manager[7085]: <info> Modem /org/freedesktop/ModemManager/Modems/14: unlock no longer required 2011-03-13T22:46:21.797836+01:00 bart modem-manager[7085]: <info> Modem /org/freedesktop/ModemManager/Modems/14: # unlock retries is 0 2011-03-13T22:46:21.797843+01:00 bart modem-manager[7085]: <info> (ttyUSB0) closing serial port... 2011-03-13T22:46:21.802511+01:00 bart modem-manager[7085]: <info> (ttyUSB0) serial port closed Now the device in unlocked and starts blinking blue (green before). Now its possible to connect using nm-applet. I did another test now: Before actualliy starting the connection I killed nm-applet again and started the connection using knetworkmanager which now also workes fine! So its definitly that knetworkmanager is missing something with correct device handling here: It does NOT do the device unlocking. -Marc Created attachment 57940 [details]
nm-applet dialog (german)
Please tell me if you need this translated...
Git commit 835c65da3ac5ee01fa2b5cf2387e2650440a4b89 by Lamarque V. Souza. Committed on 01/05/2011 at 03:01. Pushed by lvsouza into branch 'master'. Try to unlock (PIN/PUK) and enable modem before connecting to Gsm connections. BUG: 264083 M +20 -0 backends/NetworkManager/nmdbussettingsservice.cpp M +2 -0 libs/internals/CMakeLists.txt M +7 -0 libs/service/CMakeLists.txt M +97 -1 libs/service/networkinterfacemonitor.cpp M +11 -0 libs/service/networkinterfacemonitor.h A +110 -0 libs/service/pindialog.cpp [License: GPL] A +58 -0 libs/service/pindialog.h [License: GPL] A +201 -0 libs/service/pinwidget.ui [License: UNKNOWN] * The files marked with a * at the end have a non valid license. Please read: http://techbase.kde.org/Policies/Licensing_Policy and use the headers which are listed at that page. http://commits.kde.org/networkmanagement/835c65da3ac5ee01fa2b5cf2387e2650440a4b89 Git commit c4da8232cb2b635b6b08e88e4a4092d490322cbc by Lamarque V. Souza. Committed on 01/05/2011 at 02:47. Pushed by lvsouza into branch 'nm09'. Do not save PIN in wallet or configuration file. PIN is now one-time only. CCBUG: 264083 M +4 -0 libs/internals/connectionpersistence.cpp M +6 -4 libs/internals/settings/gsmpersistence.cpp http://commits.kde.org/networkmanagement/c4da8232cb2b635b6b08e88e4a4092d490322cbc Git commit aabca85cce31ce40114c62a783fd7480383ae03e by Lamarque V. Souza. Committed on 01/05/2011 at 02:47. Pushed by lvsouza into branch 'master'. Do not save PIN in wallet or configuration file. PIN is now one-time only. CCBUG: 264083 M +4 -0 libs/internals/connectionpersistence.cpp M +4 -2 libs/internals/settings/gsmpersistence.cpp http://commits.kde.org/networkmanagement/aabca85cce31ce40114c62a783fd7480383ae03e Git commit 20034f7c11808c99aeab3c6c48a886f833b0d930 by Lamarque V. Souza. Committed on 01/05/2011 at 03:01. Pushed by lvsouza into branch 'nm09'. Try to unlock (PIN/PUK) and enable modem before connecting to Gsm connections. Also fix compilation against NM-0.9. BUG: 264083 M +2 -3 applet/interfacedetailswidget.cpp M +3 -1 applet/interfacedetailswidget.h M +20 -0 backends/NetworkManager/nmdbussettingsservice.cpp M +2 -0 libs/internals/CMakeLists.txt M +7 -0 libs/service/CMakeLists.txt M +97 -1 libs/service/networkinterfacemonitor.cpp M +11 -0 libs/service/networkinterfacemonitor.h A +110 -0 libs/service/pindialog.cpp [License: GPL] A +58 -0 libs/service/pindialog.h [License: GPL] A +201 -0 libs/service/pinwidget.ui [License: UNKNOWN] * The files marked with a * at the end have a non valid license. Please read: http://techbase.kde.org/Policies/Licensing_Policy and use the headers which are listed at that page. http://commits.kde.org/networkmanagement/20034f7c11808c99aeab3c6c48a886f833b0d930 *** Bug 209777 has been marked as a duplicate of this bug. *** Git commit 2e4aa92e4ae9b6c505c375e520b3fce20a01613a by Lamarque V. Souza. Committed on 01/05/2011 at 03:48. Pushed by lvsouza into branch 'nm09'. Fix typo. CCBUG: 264083 (cherry picked from commit 069db464fddd1e7b1d0187e5a8e03b2d216cc318) M +2 -2 libs/service/networkinterfacemonitor.cpp http://commits.kde.org/networkmanagement/2e4aa92e4ae9b6c505c375e520b3fce20a01613a Git commit 069db464fddd1e7b1d0187e5a8e03b2d216cc318 by Lamarque V. Souza. Committed on 01/05/2011 at 03:48. Pushed by lvsouza into branch 'master'. Fix typo. CCBUG: 264083 M +2 -2 libs/service/networkinterfacemonitor.cpp http://commits.kde.org/networkmanagement/069db464fddd1e7b1d0187e5a8e03b2d216cc318 |