Re: Ethernet connection not listed through DBus/ListConnections




On Wed, May 27, 2009 at 5:56 PM, daniel åkerud <daniel akerud gmail com> wrote:

I am trying to automatically connect to a VPN (PPTP) connection through DBus. I have used the script posted by Tambet Ingo as a starting point, found here:
http://www.nabble.com/dbus-and-OpenVPN-Autostart-td21905375.html

The problem is that my Ethernet connection ("Auto Eth1"), that is required to be connected before the VPN, is not listed through the org.freedesktop.NetworkManagerUserSettings.ListConnections function.

So how do I get the last parameter to ActivateConnection? I.e.:

  iface.ActivateConnection('org.freedesktop.NetworkManagerUserSettings',
                             vpn_connection, # = "/org/freedesktop/NetworkManagerSettings/0" which is my VPN
                             dbus.ObjectPath("/"),
                             active_connection, # where to get?
                             reply_handler=reply_handler,
                             error_handler=error_handler)

I do have the UUID for both connections, found under
  cat /etc/NetworkManager/system-connections/Auto eth1
and
  cat ~/.gconf/system/networking/connections/2/connection/%gconf.xml
respectively.

I am using network-manager-0.7.1~rc4.1.cf199a964 under Ubuntu 9.04.

Any and all help appreciated.

BR/D


I'm stuck here, and the PPTP connection goes down several times a day, really frustrating. Anyone can shed some light on this dbus issue? What could trigger that my ethernet connection is not listed in ListConnections?

/D




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]