[RFC] Make scan mode configurable
This adds support for continuously scanning. Also it alows to specify the scan inteval and the pruning time at runtime. Signed-off-by: Daniel Wagner --- The idea behind this patch is to be able to recognize AP a bit faster then the standard algorithm in NM. I'm not completely sure where this continuously scaning code should go. Propably all that should be handled by wpa_supplicant? If you don't like this patch, no problem with me. In case you like it I guess some more work is needed. For example I really don't know how you get those interesting tab-space indentions. :) include/NetworkManager.h |8 ++ introspection/nm-device-wifi.xml | 16 +++ libnm-glib/nm-device-wifi.c | 203 ++ libnm-glib/nm-device-wifi.h | 12 +++ src/nm-device-wifi.c | 164 ++- src/nm-device-wifi.h |3 + 6 files changed, 380 insertions(+), 26 deletions(-) diff --git a/include/NetworkManager.h b/include/NetworkManager.h index d61a89c..380d896 100644 --- a/include/NetworkManager.h +++ b/include/NetworkManager.h @@ -141,6 +141,14 @@ typedef enum { NM_802_11_MODE_INFRA } NM80211Mode; +/* + * 802.11 Scan mode behaviour + * + */ +typedef enum { + NM_802_11_SCAN_MODE_DEFAULT = 0, + NM_802_11_SCAN_MODE_CONTINUOUSLY, +} NM80211ScanMode; /* * Device states diff --git a/introspection/nm-device-wifi.xml b/introspection/nm-device-wifi.xml index 21ace0a..55d4135 100644 --- a/introspection/nm-device-wifi.xml +++ b/introspection/nm-device-wifi.xml @@ -41,6 +41,22 @@ + + + Scan mode. + + + + + Scan interval value in seconds. + + + + + Scan prune value in seconds. + + + diff --git a/libnm-glib/nm-device-wifi.c b/libnm-glib/nm-device-wifi.c index 1729c8a..dde76d1 100644 --- a/libnm-glib/nm-device-wifi.c +++ b/libnm-glib/nm-device-wifi.c @@ -51,6 +51,9 @@ typedef struct { gboolean null_active_ap; guint32 wireless_caps; GPtrArray *aps; + guint scan_mode; + guint scan_interval; /* seconds */ + guint scan_prune; /* seconds */ gboolean wireless_enabled; } NMDeviceWifiPrivate; @@ -62,6 +65,9 @@ enum { PROP_BITRATE, PROP_ACTIVE_ACCESS_POINT, PROP_WIRELESS_CAPABILITIES, + PROP_WIRELESS_SCAN_MODE, + PROP_WIRELESS_SCAN_INTERVAL, + PROP_WIRELESS_SCAN_PRUNE, LAST_PROP }; @@ -71,6 +77,9 @@ enum { #define DBUS_PROP_BITRATE "Bitrate" #define DBUS_PROP_ACTIVE_ACCESS_POINT "ActiveAccessPoint" #define DBUS_PROP_WIRELESS_CAPABILITIES "WirelessCapabilities" +#define DBUS_PROP_WIRELESS_SCAN_MODE "WirelessScanMode" +#define DBUS_PROP_WIRELESS_SCAN_INTERVAL "WirelessScanInterval" +#define DBUS_PROP_WIRELESS_SCAN_PRUNE "WirelessScanPrune" enum { ACCESS_POINT_ADDED, @@ -218,6 +227,138 @@ nm_device_wifi_get_capabilities (NMDeviceWifi *device) } /** + * nm_device_wifi_get_scan_mode: + * @device: a #NMDeviceWifi + * + * Gets the wireless scan mode of the #NMDeviceWifi. + * + * Returns: the wireless scan mode + **/ +guint32 +nm_device_wifi_get_scan_mode (NMDeviceWifi *device) +{ + NMDeviceWifiPrivate *priv; + + g_return_val_if_fail (NM_IS_DEVICE_WIFI (device), 0); + + priv = NM_DEVICE_WIFI_GET_PRIVATE (device); + priv->scan_mode = _nm_object_get_uint_property (NM_OBJECT (device), + NM_DBUS_INTERFACE_DEVICE_WIRELESS, + DBUS_PROP_WIRELESS_SCAN_MODE); + return priv->scan_mode; +} + +/** + * nm_device_wifi_get_scan_interval: + * @device: a #NMDeviceWifi + * + * Gets the wireless scan interval of the #NMDeviceWifi. + * + * Returns: the wireless scan interval + **/ +guint32 +nm_device_wifi_get_scan_interval (NMDeviceWifi *device) +{ + NMDeviceWifiPrivate *priv; + + g_return_val_if_fail (NM_IS_DEVICE_WIFI (device), 0); + + priv = NM_DEVICE_WIFI_GET_PRIVATE (device); + priv->scan_interval = _nm_object_get_uint_property (NM_OBJECT (device), + NM_DBUS_INTERFACE_DEVICE_WIRELESS, + DBUS_PROP_WIRELESS_SCAN_INTERVAL); + return priv->scan_interval; +} + +/** + * nm_device_wifi_get_scan_prune: + * @device: a #NMDeviceWifi + * + * Gets the wireless scan prune of the #NMDeviceWifi. + * + * Returns: the wireless scan prune + **/ +guint32 +nm_device_wifi_get_scan_prune (NMDeviceWifi *device) +{ + NMDeviceWifiPrivate *priv; + + g_return_val_if_fail (NM_IS_DEVICE_WIFI (device), 0); + + priv = NM_DEV
Re: Where and how to install D02HW in ConnectionManager?
I've collected a lot of additional information, but still having trouble getting a grasp on what is going on here, though I increasingly feel like it is something that should be obvious and easy to handle if I understood the proper relationship between the 10-modem.fdi file and the /system/networking/connections/ information. Below is the daemon.log for the connection attempt from ConnectionManager. This is a clean attempt immediately after a reboot, and only includes that part of the log. In earlier attempts the log actually included an explicit reference to Launchpad bug #191889, but I've read a lot of that bug report, and don't yet see any connection to what I'm seeing. The bug #306552 seems more insightful. Feb 10 09:21:05 X30-804 NetworkManager: Activation (ttyUSB0) starting connection 'eMobile' Feb 10 09:21:05 X30-804 NetworkManager: (ttyUSB0): device state change: 3 -> 4 Feb 10 09:21:05 X30-804 NetworkManager: Activation (ttyUSB0) Stage 1 of 5 (Device Prepare) scheduled... Feb 10 09:21:05 X30-804 NetworkManager: Activation (ttyUSB0) Stage 1 of 5 (Device Prepare) started... Feb 10 09:21:05 X30-804 NetworkManager: [1234225265.335908] nm_serial_device_open(): (ttyUSB0) opening device... Feb 10 09:21:05 X30-804 NetworkManager: Activation (ttyUSB0) Stage 1 of 5 (Device Prepare) complete. Feb 10 09:21:05 X30-804 NetworkManager: (ttyUSB0): powering up... Feb 10 09:21:13 X30-804 NetworkManager: automatic_registration_response(): Automatic registration failed: not registered and not searching. Feb 10 09:21:13 X30-804 NetworkManager: (ttyUSB0): device state change: 4 -> 9 Feb 10 09:21:13 X30-804 NetworkManager: [1234225273.232795] nm_serial_device_close(): Closing device 'ttyUSB0' Feb 10 09:21:13 X30-804 NetworkManager: Marking connection 'eMobile' invalid. Feb 10 09:21:13 X30-804 NetworkManager: Activation (ttyUSB0) failed. Feb 10 09:21:13 X30-804 NetworkManager: (ttyUSB0): device state change: 9 -> 3 Feb 10 09:21:13 X30-804 NetworkManager: (ttyUSB0): deactivating device (reason: 0). Feb 10 09:21:13 X30-804 NetworkManager: nm_system_device_flush_ip4_routes_with_iface: assertion `iface_idx >= 0' failed Feb 10 09:21:13 X30-804 NetworkManager: nm_system_device_flush_ip4_addresses_with_iface: assertion `iface_idx >= 0' failed -- Power up the Internet with Yahoo! Toolbar. http://pr.mail.yahoo.co.jp/toolbar/ ___ NetworkManager-list mailing list NetworkManager-list@gnome.org http://mail.gnome.org/mailman/listinfo/networkmanager-list
Re: Why whenever I enable the WiFi interface NM sends a DHCPDISCOVER if still not associate with any AP?
2009/2/9 Dan Williams : > On Sat, 2009-02-07 at 16:24 +, Stolz wrote: >> Whenever I switch from wired to wireless interface, it takes more than >> 45 seconds to get the wireless interface enabled. Looking at the logs, >> seems the problem is (k)Networkmanager sends a DHCPDISCOVER before >> been associated with any AP: > > Can you post some logs from when you enable the wireless interface? The > logs you've got start too late to be able to see exactly what's > happening. > > NM *should* be associating with the AP first (including all security > setup), and only when the wifi card says it's successfully associated > with the AP, will NetworkManager begin DHCP. > > Dan Hello Dan. Here is the full log. I activated the WiFI interface exactly at 01:04:03 The log also can be read at http://rafb.net/p/K4H7x991.html Thanks for your help. Feb 10 01:03:33 dhcdbd: Started up. Feb 10 01:03:34 acpid: client connected from 30947[102:443] Feb 10 01:03:34 acpid: 1 client rule loaded Feb 10 01:03:35 NetworkManager: starting... Feb 10 01:03:35 NetworkManager: [1234224215.249008] GentooReadConfig(): Found config_eth0 in /etc/conf.d/net. Feb 10 01:03:35 NetworkManager: [1234224215.249240] GentooReadConfig(): Found routes_eth0 in config. Feb 10 01:03:35 NetworkManager: [1234224215.249367] GentooReadConfig(): Found DNS nameservers in config. Feb 10 01:03:35 NetworkManager: [1234224215.249495] nm_system_device_get_system_config(): Using DNS nameservers "62.42.230.24 62.42.63.52" from config for device eth0. Feb 10 01:03:35 NetworkManager: eth0: Device is fully-supported using driver '(null)'. Feb 10 01:03:35 NetworkManager: nm_device_init(): waiting for device's worker thread to start Feb 10 01:03:35 NetworkManager: nm_device_init(): device's worker thread started, continuing. Feb 10 01:03:35 NetworkManager: Now managing wired Ethernet (802.3) device 'eth0'. Feb 10 01:03:35 NetworkManager: Deactivating device eth0. Feb 10 01:03:35 NetworkManager: Will activate wired connection 'eth0' because it now has a link. Feb 10 01:03:35 iwl3945 :0c:00.0: PCI INT A -> GSI 17 (level, low) -> IRQ 17 Feb 10 01:03:35 iwl3945 :0c:00.0: restoring config space at offset 0x1 (was 0x100102, writing 0x100106) Feb 10 01:03:35 firmware: requesting iwlwifi-3945-1.ucode Feb 10 01:03:35 NetworkManager: [1234224215.325136] GentooReadConfig(): Enabling DHCP for device wlan0. Feb 10 01:03:35 NetworkManager: wlan0: Driver '(null)' does not support carrier detection. Feb 10 01:03:35 You must switch to it manually. Feb 10 01:03:35 NetworkManager: nm_device_init(): waiting for device's worker thread to start Feb 10 01:03:35 NetworkManager: nm_device_init(): device's worker thread started, continuing. Feb 10 01:03:35 NetworkManager: Now managing wired Ethernet (802.3) device 'wlan0'. Feb 10 01:03:35 NetworkManager: Deactivating device wlan0. Feb 10 01:03:35 /etc/init.d/net.lo[30991]: WARNING: net.lo has already been started Feb 10 01:03:35 NetworkManager: SWITCH: no current connection, found better connection 'eth0'. Feb 10 01:03:36 dhcdbd: message_handler: message handler not found under /com/redhat/dhcp/eth0 for sub-path eth0.dbus.get.reason Feb 10 01:03:36 NetworkManager: Will activate connection 'eth0'. Feb 10 01:03:36 NetworkManager: Device eth0 activation scheduled... Feb 10 01:03:36 NetworkManager: Activation (eth0) started... Feb 10 01:03:36 NetworkManager: Activation (eth0) Stage 1 of 5 (Device Prepare) scheduled... Feb 10 01:03:36 NetworkManager: Activation (eth0) Stage 1 of 5 (Device Prepare) started... Feb 10 01:03:36 NetworkManager: Activation (eth0) Stage 2 of 5 (Device Configure) scheduled... Feb 10 01:03:36 NetworkManager: Activation (eth0) Stage 1 of 5 (Device Prepare) complete. Feb 10 01:03:36 NetworkManager: Activation (eth0) Stage 2 of 5 (Device Configure) starting... Feb 10 01:03:36 NetworkManager: Activation (eth0) Stage 2 of 5 (Device Configure) successful. Feb 10 01:03:36 NetworkManager: Activation (eth0) Stage 3 of 5 (IP Configure Start) scheduled. Feb 10 01:03:36 NetworkManager: Activation (eth0) Stage 2 of 5 (Device Configure) complete. Feb 10 01:03:36 NetworkManager: Activation (eth0) Stage 3 of 5 (IP Configure Start) started... Feb 10 01:03:36 NetworkManager: Activation (eth0) Stage 4 of 5 (IP Configure Get) scheduled... Feb 10 01:03:36 NetworkManager: Activation (eth0) Stage 3 of 5 (IP Configure Start) complete. Feb 10 01:03:36 NetworkManager: Activation (eth0) Stage 4 of 5 (IP Configure Get) started... Feb 10 01:03:36 NetworkManager: Activation (eth0) Stage 5 of 5 (IP Configure Commit) scheduled... Feb 10 01:03:36 NetworkManager: Activation (eth0) Stage 4 of 5 (IP Configure Get) complete. Feb 10 01:03:36 NetworkManager: Activation (eth0) Stage 5 of 5 (IP Configure Commit) started... Feb 10 01:03:37 NetworkManager: Setting hostname to 'vostro' Feb 10 01:03:37 NetworkManager: Activation (eth0) successful, device activated. Feb 10 01:03:37 NetworkM
Re: Catalan translation of NetworkManager
On Sat, 2009-02-07 at 13:28 +0100, David Planella wrote: > Hi all, > > please find attached a patch with the completed Catalan translation > after having been reviewed by the Catalan GNOME Translation Team. > > I'd be grateful if you could commit it to git and send me some > feedback when you've done it. Please note that I am subscribed to the > list but I have disabled mail delivery, so please add me on CC when > replying to this message. Thanks. 0bc29fe9d3de0ade58e12a45c9f15fc7ddd81e74 Thanks! Dan ___ NetworkManager-list mailing list NetworkManager-list@gnome.org http://mail.gnome.org/mailman/listinfo/networkmanager-list
Re: How to setup NM VPN ?
On Sat, 2009-02-07 at 17:12 -0300, Miguel Rozsas wrote: > Hi, > I am using Fedora 10, Network manager openvpn plugin > (NetworkManager-openvpn-0.7.0-18.svn11.fc10.i386) and > openvpn-2.1-0.29.rc15.fc10.i386. > > I can connect to the remote openvpn server using the openvpn command line: > [code] > # openvpn --config myvpn.ovpn --script-security 2 > > Enter Private Key Password: > ... > Initialization Sequence Completed > [/code] > > > ..and I access all hosts on VPN side. No problems at all. > > The question is: How to setup a similar connection using NM ? > > > > The command above uses 2 files: myvpn.ovpn and mypkcs-file.p12 > > > > myvpn.ovpn: > [code] > > #OpenVPN Server conf > tls-client > client > dev tun > proto udp > tun-mtu 1400 > remote 12.13.14.15 1194 > #obfuscated OVPN IP gateway > pkcs12 mypkcs-file.p12 > cipher BF-CBC > comp-lzo > verb 3 > ns-cert-type server > [/code] > > mypkcs-file.p12 is in the same directory is myvpn.ovpn and it is a > data/binary file. I got both files from my OVPN server (a smoothwall > with the zerina mod) > > On windows, I am using openVPNGUI from http://openvpn.se. On windows, I need > just > to drop both files on a config file and I am ready to go. > > Any ideas about how to configure NM-openvpn ? It has several options and > types > and it request several files I don't have I think you want the "Certificates (TLS)" option. However, the NM OpenVPN client doesn't handle PKCS12 files yet. For the moment, you could try converting the PKCS#12 file to openssl-style PEM files, which break the private key and client certificate up into two files. You'll also want to extract the CA certificate from the pkcs12 file and use that as well. In the near future, we can support PKCS12 files too. Dan ___ NetworkManager-list mailing list NetworkManager-list@gnome.org http://mail.gnome.org/mailman/listinfo/networkmanager-list
Re: Why whenever I enable the WiFi interface NM sends a DHCPDISCOVER if still not associate with any AP?
On Sat, 2009-02-07 at 16:24 +, Stolz wrote: > Whenever I switch from wired to wireless interface, it takes more than > 45 seconds to get the wireless interface enabled. Looking at the logs, > seems the problem is (k)Networkmanager sends a DHCPDISCOVER before > been associated with any AP: Can you post some logs from when you enable the wireless interface? The logs you've got start too late to be able to see exactly what's happening. NM *should* be associating with the AP first (including all security setup), and only when the wifi card says it's successfully associated with the AP, will NetworkManager begin DHCP. Dan > Feb 7 18:03:58 vostro NetworkManager: DHCP daemon state is > now 1 (starting) for interface wlan0 > Feb 7 18:03:59 vostro dhclient: DHCPDISCOVER on wlan0 to > 255.255.255.255 port 67 interval 3 > Feb 7 18:04:02 vostro dhclient: DHCPDISCOVER on wlan0 to > 255.255.255.255 port 67 interval 7 > Feb 7 18:04:09 vostro dhclient: DHCPDISCOVER on wlan0 to > 255.255.255.255 port 67 interval 8 > Feb 7 18:04:17 vostro dhclient: DHCPDISCOVER on wlan0 to > 255.255.255.255 port 67 interval 10 > Feb 7 18:04:27 vostro dhclient: DHCPDISCOVER on wlan0 to > 255.255.255.255 port 67 interval 10 > Feb 7 18:04:37 vostro dhclient: DHCPDISCOVER on wlan0 to > 255.255.255.255 port 67 interval 9 > Feb 7 18:04:42 vostro NetworkManager: Device 'wlan0' DHCP > transaction took too long (>45s), stopping it. > > I'm not a network expert but, AFAIK, if you are not associated with > any AP, there is no link so sending a DHCP petition makes no sense for > me. Can someone explain me this behaviour? It's annoying having to > wait almost a minute every time I want to use WiFi. > > Thanks. > ___ > NetworkManager-list mailing list > NetworkManager-list@gnome.org > http://mail.gnome.org/mailman/listinfo/networkmanager-list ___ NetworkManager-list mailing list NetworkManager-list@gnome.org http://mail.gnome.org/mailman/listinfo/networkmanager-list
Re: USB Modem
On Fri, 2009-02-06 at 21:45 -0800, Harold Hallikainen wrote: > I'm running Fedora 10 and have been using KPPP to talk to my cellphone, > which emulates an AT command set modem over RS-232, which is then adapted > to USB. I'm interested in using Network Manager instead of KPPP. Looking > around the web, I found a suggestion that a file > /etc/hal/fdi/information/3gmodem.fdi be created. I named it cellphone.fdi > . The file contains the following: > > > > > > > modem > IS-707-A > > > > > When the phone is plugged in, it shows up in Network Manager as CDMA > Connection 1 (I created the connection in Network Manager). > > The cellphone modem uses the Hayes AT command set, and I suspect that is > not the command set listed in the above XML. > > Looking at /var/log/messages, I see the following when I tell NM to > connect to CDMA Connection 1: > > Feb 6 21:29:19 localhost NetworkManager: Activation (ttyUSB0) > starting connection 'CDMA connection 1' > Feb 6 21:29:19 localhost NetworkManager: (ttyUSB0): device state > change: 3 -> 4 > Feb 6 21:29:19 localhost NetworkManager: Activation (ttyUSB0) > Stage 1 of 5 (Device Prepare) scheduled... > Feb 6 21:29:19 localhost NetworkManager: Activation (ttyUSB0) > Stage 1 of 5 (Device Prepare) started... > Feb 6 21:29:19 localhost NetworkManager: Activation (ttyUSB0) > Stage 1 of 5 (Device Prepare) complete. > Feb 6 21:29:29 localhost NetworkManager: init_done(): Modem > initialization timed out > Feb 6 21:29:29 localhost NetworkManager: (ttyUSB0): device state > change: 4 -> 9 > Feb 6 21:29:30 localhost NetworkManager: Marking connection 'CDMA > connection 1' invalid. > Feb 6 21:29:30 localhost NetworkManager: Activation (ttyUSB0) > failed. > Feb 6 21:29:30 localhost NetworkManager: (ttyUSB0): device state > change: 9 -> 3 > Feb 6 21:29:30 localhost NetworkManager: (ttyUSB0): deactivating > device (reason: 0). > F > > Also, on the cellphone display, I see no evidence of the phone attempting > to dial. So... is the modem command set the problem? What is the modem > command set for an AT modem? Is your phone really a CDMA/EVDO device? Or is it GSM/UMTS/HSPA device? The keys will be different depending on what type. Once we've figured that out, could you do the following, all as root? a) service NetworkManager stop b) NM_SERIAL_DEBUG=1 /usr/sbin/NetworkManager --no-daemon c) (as your user) select the connection from the menu of the applet Then grab that debug output from the terminal and post it as a reply to this mail. We're not generally supporting cellphones until we start using ModemManager, which allows us to be much more flexible about different devices, but it may just be a quick fix for your phone. Dan ___ NetworkManager-list mailing list NetworkManager-list@gnome.org http://mail.gnome.org/mailman/listinfo/networkmanager-list
Re: nm 0.6 compatibiity
On Sun, 2009-02-08 at 10:29 +0100, Guillaume Quintard wrote: > and it's me again, with a question about this page: > http://projects.gnome.org/NetworkManager/developers/spec.html > > using state() of org.freedesktop.NetworkManager is said deprecated in > 0.7, but it works fine, and I haven't seen any other (easy) way to > check the connections? > > could someone shed some light on that point please? The NetworkManager D-Bus interface changed drastically between 0.6 and 0.7 to become more flexible and support more types of devices. Certain legacy methods were preserved to maintain compatibility with programs that used 0.6 for network state discovery, ie "Am I connected to something?" questions. That's why there are so many ways to get the overall NM state. But as you've discovered, those methods are marked "deprecated", because they are only provided as a compatibility mechanism, and are likely to be removed in NetworkManager 0.8 or later. They will exist for the lifetime of NetworkManager 0.7 though. Dan ___ NetworkManager-list mailing list NetworkManager-list@gnome.org http://mail.gnome.org/mailman/listinfo/networkmanager-list
Re: NetworkManager integrated with ModemManager
On Mon, 2009-02-09 at 15:32 +0200, Tambet Ingo wrote: > On Mon, Feb 9, 2009 at 15:14, Darren Albers wrote: > >> With ModemManager will the workarounds have to be done in the code or > >> is there some method that an end-user can drop chat script in to > >> ModemManager? For example I have a Blackberry that I tether using > >> Barry and it has a non-standard method of creating a serial port. I > >> would like to help get this working but I am not much of a developer. > > The workarounds are implemented in ModemManager as plugins in C. I > find it hilarious how people miss having to know AT commands by heart > and to be required to enter them to get their modem connected. I > understand it could be the only way to get your modem connected, but > that problem should be fixed by developers, not by users. Sort of the > point of whole NM, to make things just work. > > All that said... I've been planning to write a ModemManager plugin > that does exactly that, but not to torture people, but to make it > easier for them to contribute back - if we can see which commands are > required for certain modem, we can do that in ModemManager. Ugh; as long as we make it clear it's for debugging and not actually supported for general use or anything. > > Ahh I think I see now, so we would need to write an interface to > > something like wvdial or even direct to Barry for this to work? > > While it's possible to use anything (like wvdial, barry), it usually > doesn't make much sense (other than for testing). There can be exactly > one DBus service that provides ModemManager API so the distro can not > ship the hack which only works with your modem (so you'll never have > an works-out-of-box solution). For the blackberry stuff specifically, I'd recommend that a ModemManager plugin be written using libbarry that basically does what the barry ppp stuff does internally. PIN unlocking and such has to be handled through libbarry, and much of the communication with the device is handled through libbarry too, not necessarily through the serial port. This would be the right way to do it, not a hack like using wvdial or barry utils themselves. Dan ___ NetworkManager-list mailing list NetworkManager-list@gnome.org http://mail.gnome.org/mailman/listinfo/networkmanager-list
Re: Where and how to install D02HW in ConnectionManager?
On Mon, 2009-02-09 at 12:09 +0900, Jacobs Shannon wrote: > Date: Fri, 06 Feb 2009 12:03:11 -0500 > > > Could you grab the bits of /var/log/messages or > > /var/log/daemon.log that > > show a connection attempt by NM when you choose the modem in > > the menu? > > > > Dan > > Sorry about my slow responses, and this is mostly a thank-you for > pointing me in the right direction. Unfortunately, this is a > part-time and low-priority project for me. I hope I'm gradually > moving onto the proper track, after the original detour into reams > of debugging information. I suspected the problem was much closer to > home. I can send large snippets, but I'm fairly sure the key bit > appears in the daemon.log as: > > Feb 9 10:10:42 X30-804 nm-system-settings:SCPlugin-Ifupdown: > device added (udi: > /org/freedesktop/Hal/devices/usb_device_12d1_1003_noserial_if0_serial_usb_0, > iface: (null)): iface not found > Feb 9 10:10:42 X30-804 NetworkManager: ttyUSB0: driver is > 'option'. > Feb 9 10:10:42 X30-804 NetworkManager: [1234141842.908212] > setup_monitor_device(): No monitoring udi provided > Feb 9 10:10:42 X30-804 NetworkManager: Found new Modem > device 'ttyUSB0'. > Feb 9 10:10:42 X30-804 NetworkManager: (ttyUSB0): exported > as > /org/freedesktop/Hal/devices/usb_device_12d1_1003_noserial_if0_serial_usb_0 > > Feb 9 10:10:46 X30-804 NetworkManager: (ttyUSB0): device > state change: 1 -> 2 > Feb 9 10:10:47 X30-804 NetworkManager: (ttyUSB0): > deactivating device (reason: 2). > Feb 9 10:10:47 X30-804 NetworkManager: > nm_system_device_flush_ip4_routes_with_iface: assertion `iface_idx > >= 0' failed > Feb 9 10:10:47 X30-804 NetworkManager: > nm_system_device_flush_ip4_addresses_with_iface: assertion > `iface_idx >= 0' failed > Feb 9 10:10:47 X30-804 NetworkManager: (ttyUSB0): device > state change: 2 -> 3 Ok, this is the initial discovery of the device. What I need is the bits of that same log file that show when you attempt to make a connection using the menu, which will later in the logs. Dan ___ NetworkManager-list mailing list NetworkManager-list@gnome.org http://mail.gnome.org/mailman/listinfo/networkmanager-list
Re: Where and how to install D02HW in ConnectionManager?
On Mon, 2009-02-09 at 13:19 +0900, Jacobs Shannon wrote: > This might or might not represent progress... I think the critical > trick now is to use this information about the D02HW extracted from > the lsusb results: > > Bus 002 Device 003: ID 12d1:1003 Huawei Technologies Co., Ltd. E220 > HSDPA Modem / E270 HSDPA/HSUPA Modem > > My yet newest theory is that the ID information of 12d1:1003 needs > to be included in an fdi file. For some reason, pon does not care, > but ConnectionManager must have this information to proceed. I > suspect that it belongs in the > /usr/share/hal/fdi/information/10freedesktop/ directory in the file > 10-modem.fdi. I think it should appear rather like this arbitrarily > selected example: If you're using Ubuntu, I think they have a custom patch that autodetects modem type without using the fdi files. But in any case, if NM already sees the modem, you're past this step. Dan > > > > >type="strlist">GSM-07.07 >type="strlist">GSM-07.05 > > > > > I have found some apparently relevant information on Huawei, but so > far it is in Japanese, which I read slowly and with some pain... I'm > not sure quite what I'm looking for or where to find it. I did find > some information that the D02HW is supposed to work 'out of the box' > with ISPs in several European countries... Or is the secret in the > reams of information from lshal? Perhaps the required information > can be mapped from a Windows machine? And can anyone confirm whether > or not I am making progress? > > > -- > Yahoo! JAPAN - Internet safety for children and parents. > http://pr.mail.yahoo.co.jp/security/ > ___ > NetworkManager-list mailing list > NetworkManager-list@gnome.org > http://mail.gnome.org/mailman/listinfo/networkmanager-list ___ NetworkManager-list mailing list NetworkManager-list@gnome.org http://mail.gnome.org/mailman/listinfo/networkmanager-list
Re: dbus and OpenVPN Autostart
On Mon, 2009-02-09 at 11:37 +1100, David Guest wrote: > I am attempting to create a dispatcher script to autostart an OpenVPN > connection, I am stuck on how to get the vpn to connect through dbus. > Would anyone have a working example, preferably in python but any > language will do? > > I am running Ubuntu 8.10 (NetworkManager 0.7), I have found at least one > example on the web but it appears to be for an earlier dbus Network > Manager API version as I get errors when running them. > > I have looked at the 0.7 dbus API but can't figure out what to send to > the org.freedesktop.NetworkManager.VPN.Plugin.Connect method or even if > this is the right approach? That's actually the wrong approach here; what you want to do is tell _NetworkManager_ to connect the VPN connection. So you'll be using the org.freedesktop.NetworkManager.ActivateConnection method, and pass it the service name of the settings service (either user or system) that provides the connection, the object path of the connection as exported by that settings service, and the device you'd like to activate the VPN on (which would be the object path of the interface your script got called with, probably). Dan ___ NetworkManager-list mailing list NetworkManager-list@gnome.org http://mail.gnome.org/mailman/listinfo/networkmanager-list
Re: PPTP Change
On Sat, 2009-02-07 at 13:44 -0700, Russell Suter wrote: > All, > > I have my NetworkManager-pptp working now but I had to make one change > in the source get it to authenticate. We use mschapv2 at my workplace > and when the credentials were being passed to the server, it was > failing. The problem was that it was passing the username as > DOMAIN\\USERNAME which doesn't work. After a bit of playing with > wireshark, I was able to deduce the username should be sent > DOMAIN\USERNAME. When I changed it, it worked. SVN revisions 23 and 24, thanks! I have no idea why I initially made it DOMAIN\\USERNAME; but it's pretty clear that's wrong. Dan > Now, I know almost nothing about this stuff so I suspect this isn't the > best solution since I'm sure other people are using it this way. But, > I'm providing the patch for what I did to make it work for me in hopes > that someone more knowledgeable can come up with a better solution. > > > > Index: nm-pptp-service.c > === > --- nm-pptp-service.c(revision 22) > +++ nm-pptp-service.c(working copy) > @@ -313,7 +313,7 @@ > > /* Success */ > if (strlen (priv->domain)) > -*out_username = g_strdup_printf ("%s%s", priv->domain, > priv->username); > +*out_username = g_strdup_printf ("%s\\%s", priv->domain, > priv->username); > else > *out_username = g_strdup (priv->username); > *out_password = g_strdup (priv->password); > > Thanks > > -- > Russ > > ___ > NetworkManager-list mailing list > NetworkManager-list@gnome.org > http://mail.gnome.org/mailman/listinfo/networkmanager-list ___ NetworkManager-list mailing list NetworkManager-list@gnome.org http://mail.gnome.org/mailman/listinfo/networkmanager-list
Re: nm 0.6 compatibiity
and it's me again, with a question about this page: http://projects.gnome.org/NetworkManager/developers/spec.html using state() of org.freedesktop.NetworkManager is said deprecated in 0.7, but it works fine, and I haven't seen any other (easy) way to check the connections? could someone shed some light on that point please? -- Guillaume ___ NetworkManager-list mailing list NetworkManager-list@gnome.org http://mail.gnome.org/mailman/listinfo/networkmanager-list
nm 0.6 compatibiity
Hi there, I working on gajim right now, upgrading the nm support to 0.7, and so I have a little question: what's your policy about 0.6? long version: should I support both 0.6 and 0.7, or only 0.7? I have no idea about the adoption rate, speed or if it's a good/bad thing to handle 0.6 (more users supported, but you may want to get rid of the old version ASAP, I don't know) any thought on that one? -- Guillaume ___ NetworkManager-list mailing list NetworkManager-list@gnome.org http://mail.gnome.org/mailman/listinfo/networkmanager-list
Re: NetworkManager integrated with ModemManager
On Mon, Feb 9, 2009 at 15:14, Darren Albers wrote: >> With ModemManager will the workarounds have to be done in the code or >> is there some method that an end-user can drop chat script in to >> ModemManager? For example I have a Blackberry that I tether using >> Barry and it has a non-standard method of creating a serial port. I >> would like to help get this working but I am not much of a developer. The workarounds are implemented in ModemManager as plugins in C. I find it hilarious how people miss having to know AT commands by heart and to be required to enter them to get their modem connected. I understand it could be the only way to get your modem connected, but that problem should be fixed by developers, not by users. Sort of the point of whole NM, to make things just work. All that said... I've been planning to write a ModemManager plugin that does exactly that, but not to torture people, but to make it easier for them to contribute back - if we can see which commands are required for certain modem, we can do that in ModemManager. > Ahh I think I see now, so we would need to write an interface to > something like wvdial or even direct to Barry for this to work? While it's possible to use anything (like wvdial, barry), it usually doesn't make much sense (other than for testing). There can be exactly one DBus service that provides ModemManager API so the distro can not ship the hack which only works with your modem (so you'll never have an works-out-of-box solution). I guess what you're really asking for, is Bluetooth support and that's still missing. Tambet ___ NetworkManager-list mailing list NetworkManager-list@gnome.org http://mail.gnome.org/mailman/listinfo/networkmanager-list
Re: NetworkManager integrated with ModemManager
On Mon, Feb 9, 2009 at 8:12 AM, Darren Albers wrote: > On Mon, Feb 9, 2009 at 5:07 AM, Tambet Ingo wrote: >> Hi, >> >> I'm pleased to announce the git master branch of NetworkManager now >> uses ModemManager for all operations with modems (discovery, >> connecting, disconnecting, ...). Get the latest ModemManager from >> >> http://people.freedesktop.org/~tambet/ModemManager-0.2.tar.gz >> >> or clone it from >> >> git://anongit.freedesktop.org/ModemManager/ModemManager >> >> ModemManager is used only if available using DBus, so it's not a build >> time dependency (reduces ~1000 lines of 'bloat' when you don't need >> modems). If this change broke modem connections for you, please enable >> ModemManager debugging (either by sending SIGUSR1 to 'modem-manger' >> process or by running it with --debug), try to activate the modem and >> when it fails, send the ModemManager debug output to the list. One of >> the main reasons for ModemManager is to make it easy to add modem >> specific workarounds for specific modems but if you don't share your >> failures, they never make it to the releases. >> >> It also means you can write your own ModemManager implementation by >> having just two DBus methods (see >> 'org.freedesktop.ModemManager.Modem.Simple' from ModemManager for more >> information). An interface to 'umtsmon' anyone? wvdial? comgt? Your >> favorite tool can now be integrated with stock NetworkManager! >> >> Tambet > > Tambet, > > With ModemManager will the workarounds have to be done in the code or > is there some method that an end-user can drop chat script in to > ModemManager? For example I have a Blackberry that I tether using > Barry and it has a non-standard method of creating a serial port. I > would like to help get this working but I am not much of a developer. > > Thanks! > Darren > Ahh I think I see now, so we would need to write an interface to something like wvdial or even direct to Barry for this to work? ___ NetworkManager-list mailing list NetworkManager-list@gnome.org http://mail.gnome.org/mailman/listinfo/networkmanager-list
Re: NetworkManager integrated with ModemManager
On Mon, Feb 9, 2009 at 5:07 AM, Tambet Ingo wrote: > Hi, > > I'm pleased to announce the git master branch of NetworkManager now > uses ModemManager for all operations with modems (discovery, > connecting, disconnecting, ...). Get the latest ModemManager from > > http://people.freedesktop.org/~tambet/ModemManager-0.2.tar.gz > > or clone it from > > git://anongit.freedesktop.org/ModemManager/ModemManager > > ModemManager is used only if available using DBus, so it's not a build > time dependency (reduces ~1000 lines of 'bloat' when you don't need > modems). If this change broke modem connections for you, please enable > ModemManager debugging (either by sending SIGUSR1 to 'modem-manger' > process or by running it with --debug), try to activate the modem and > when it fails, send the ModemManager debug output to the list. One of > the main reasons for ModemManager is to make it easy to add modem > specific workarounds for specific modems but if you don't share your > failures, they never make it to the releases. > > It also means you can write your own ModemManager implementation by > having just two DBus methods (see > 'org.freedesktop.ModemManager.Modem.Simple' from ModemManager for more > information). An interface to 'umtsmon' anyone? wvdial? comgt? Your > favorite tool can now be integrated with stock NetworkManager! > > Tambet Tambet, With ModemManager will the workarounds have to be done in the code or is there some method that an end-user can drop chat script in to ModemManager? For example I have a Blackberry that I tether using Barry and it has a non-standard method of creating a serial port. I would like to help get this working but I am not much of a developer. Thanks! Darren ___ NetworkManager-list mailing list NetworkManager-list@gnome.org http://mail.gnome.org/mailman/listinfo/networkmanager-list
NetworkManager integrated with ModemManager
Hi, I'm pleased to announce the git master branch of NetworkManager now uses ModemManager for all operations with modems (discovery, connecting, disconnecting, ...). Get the latest ModemManager from http://people.freedesktop.org/~tambet/ModemManager-0.2.tar.gz or clone it from git://anongit.freedesktop.org/ModemManager/ModemManager ModemManager is used only if available using DBus, so it's not a build time dependency (reduces ~1000 lines of 'bloat' when you don't need modems). If this change broke modem connections for you, please enable ModemManager debugging (either by sending SIGUSR1 to 'modem-manger' process or by running it with --debug), try to activate the modem and when it fails, send the ModemManager debug output to the list. One of the main reasons for ModemManager is to make it easy to add modem specific workarounds for specific modems but if you don't share your failures, they never make it to the releases. It also means you can write your own ModemManager implementation by having just two DBus methods (see 'org.freedesktop.ModemManager.Modem.Simple' from ModemManager for more information). An interface to 'umtsmon' anyone? wvdial? comgt? Your favorite tool can now be integrated with stock NetworkManager! Tambet ___ NetworkManager-list mailing list NetworkManager-list@gnome.org http://mail.gnome.org/mailman/listinfo/networkmanager-list
ModemManager-0.2 released.
Hello, I'm happy to announce the first official release of ModemManager: http://people.freedesktop.org/~tambet/ModemManager-0.2.tar.gz The most important recent changes: * Moved to git.freedesktop.org. The old tree at gitorious.org is not used anymore. Clone the new tree from git://anongit.freedesktop.org/ModemManager/ModemManager . * Change the DBus return values that returned multiple values. It turned out DBus python bindings did not support that and to make it possible to implement ModemManager interfaces in python, these methods now return tuples. * Changes to the 'org.freedesktop.ModemManager.Modem.Gsm.SMS' interface as suggested by Pablo Martà Gamboa (http://mail.gnome.org/archives/networkmanager-list/2009-January/msg00194.html). * Implement 'org.freedesktop.ModemManager.Modem.Simple' interface. It's a very simple wrapper with just two methods on top of existing functionality to make it as easy as possible to get a modem connected and to query it's status. * Define generic IP address receiving methods to avoid modem specific implementations in applications that use ModemManager. In order to do so, 'org.freedesktop.ModemManager.Modem' interface was extended with: - 'IpMethod' property. It's an 'uint' type with 3 possible values: 0 - ppp (use PPP to get the IP address, most modems), 1 - static (ask IP address from modem, used with HSO modems), 2 - DHCP (run dhcp on the provided device, used with MBM modems). - 'GetIP4Config' method. It's implemented only in case 'IpMethod' property returns 1 (static) and returns a tuple containing (address, dns1, dns2, dns3). - 'DataDevice' property is renamed to 'Device'. It's always the IP device for the modem. Tambet ___ NetworkManager-list mailing list NetworkManager-list@gnome.org http://mail.gnome.org/mailman/listinfo/networkmanager-list