unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
* bug#33832: The VPN service 'org.freedesktop.NetworkManager.openvpn' was not installed.
@ 2018-12-22  3:28 swedebugia
  2019-01-09 12:54 ` Maxim Cournoyer
  0 siblings, 1 reply; 9+ messages in thread
From: swedebugia @ 2018-12-22  3:28 UTC (permalink / raw)
  To: 33832

[-- Attachment #1: Type: text/plain, Size: 1042 bytes --]


Dec 22 04:21:24 localhost NetworkManager[289]: <info>  [1545448884.2537]
audit: op="connection-activate"
uuid="c3d6b24a-d67c-48a9-8695-2e9dd83c1b07" name="Riseup VPN" pid=414
uid=1000 result="fail" reason="The VPN service
'org.freedesktop.NetworkManager.openvpn' was not installed."
Dec 22 04:22:19 localhost NetworkManager[289]: <info>  [1545448939.2045]
device (wlp3s0): set-hw-addr: set MAC address to AE:C7:48:B4:FE:7E
(scanning)
Dec 22 04:22:19 localhost vmunix: [ 3281.066433] IPv6:
ADDRCONF(NETDEV_UP): wlp3s0: link is not ready
Dec 22 04:22:19 localhost NetworkManager[289]: <info>  [1545448939.2203]
device (wlp3s0): supplicant interface state: inactive -> disabled
Dec 22 04:22:19 localhost NetworkManager[289]: <info>  [1545448939.2557]
device (wlp3s0): supplicant interface state: disabled -> inactive

config attached were it is installed systemwide.

my user manifest is also attached were it is also installed.

sdb@antelope ~/src/guix$ guix --version
guix (GNU Guix) 0.16.0-3.6ddc63e

running from git.
-- 
Cheers 
Swedebugia

[-- Attachment #2: config.scm --]
[-- Type: text/plain, Size: 4407 bytes --]

;; This is an operating system configuration template
;; for a "desktop" setup with GNOME and Xfce where the
;; root partition is encrypted with LUKS.

(use-modules (gnu) (gnu system nss))
(use-service-modules desktop networking)
(use-package-modules certs gnome
		     ;; for my-base-packages
		     linux less base nano pciutils admin man texinfo
		     bash guile gawk compression)

(define %my-base-packages
  ;; Like upstream but without wifi-programs and zile.

  ;; Default set of packages globally visible.  It should include anything
  ;; required for basic administrator tasks.
  (cons* procps psmisc which less
	 ;;zile
	 nano
         pciutils usbutils
         util-linux
         inetutils isc-dhcp
         (@ (gnu packages admin) shadow)          ;for 'passwd'

         ;; wireless-tools is deprecated in favor of iw, but it's still what
         ;; many people are familiar with, so keep it around.
         ;;iw wireless-tools

         iproute
         net-tools                        ; XXX: remove when Inetutils suffices
         man-db
         info-reader                     ;the standalone Info reader (no Perl)

         ;; The 'sudo' command is already in %SETUID-PROGRAMS, but we also
         ;; want the other commands and the man pages (notably because
         ;; auto-completion in Emacs shell relies on man pages.)
         sudo

         ;; Get 'insmod' & co. from kmod, not module-init-tools, since udev
         ;; already depends on it anyway.
         kmod eudev

         e2fsprogs kbd

         bash-completion

         ;; XXX: We don't use (canonical-package guile-2.2) here because that
         ;; would create a collision in the global profile between the GMP
         ;; variant propagated by 'guile-final' and the GMP variant propagated
         ;; by 'gnutls', itself propagated by 'guix'.
         guile-2.2

         ;; The packages below are also in %FINAL-INPUTS, so take them from
         ;; there to avoid duplication.
         (map canonical-package
              (list bash coreutils findutils grep sed
                    diffutils patch gawk tar gzip bzip2 xz lzip))))

(operating-system
  (host-name "antelope")
  (timezone "Europe/Paris")
  (locale "en_US.utf8")

  ;; Use the UEFI variant of GRUB with the EFI System
  ;; Partition mounted on /boot/efi.
  (bootloader (bootloader-configuration
                (bootloader grub-bootloader)
		(target "/dev/sda")))

  (file-systems (cons (file-system
                        (device (file-system-label "my-root"))
                        (mount-point "/")
                        (type "ext4"))
		      %base-file-systems))

  (swap-devices '("/dev/sda2"))

  (users (cons (user-account
                (name "sdb")
                (comment "Alice's brother")
                (group "users")
                (supplementary-groups '("wheel" "netdev"
                                        "audio" "video"))
                (home-directory "/home/sdb"))
               %base-user-accounts))

  ;; This is where we specify system-wide packages.
  (packages (cons* nss-certs         ;for HTTPS access
                   gvfs              ;for user mounts
		   gnome-shell-extensions
		   network-manager-openvpn
                   %my-base-packages))

  ;; Add GNOME and/or Xfce---we can choose at the log-in
  ;; screen with F1.  Use the "desktop" services, which
  ;; include the X11 log-in service, networking with
  ;; NetworkManager, and more.
  (services (cons* (gnome-desktop-service)
                   ;;(xfce-desktop-service)
		   (console-keymap-service "se-latin1")
                   (modify-services %desktop-services      ; Add berlin as first priority 
                                                           ; substitute server
                                    (guix-service-type config =>
                                                       (guix-configuration
                                                        (inherit config)
                                                        (substitute-urls '(
									   "https://berlin.guixsd.org https://mirror.hydra.gnu.org"))))
				    (network-manager-service-type config =>
								  (network-manager-configuration
								   (inherit config)
								   (vpn-plugins (list network-manager-openvpn)))))))

  ;; Allow resolution of '.local' host names with mDNS.
  ;;(name-service-switch %mdns-host-lookup-nss)
  )

[-- Attachment #3: sdb.scm --]
[-- Type: text/plain, Size: 1606 bytes --]

(specifications->manifest
 '(
   ;;;;;;;;;;;;;;;;;;;;;;;;;;;
   ;; Base
   ;;;;;;;;;;;;;;;;;;;;;;;;;;;
   "android-udev-rules"
   "glibc-utf8-locales"
   "gnupg"
   "recutils"
   
   ;;;;;;;;;;;;;;;;;;;;;;;;;;;;
   ;; Guix development deps :D
   ;;;;;;;;;;;;;;;;;;;;;;;;;;;;
   "automake"
   "autoconf"
   "bzip2"
   "ccache"
   "emacs-geiser"
   ;;"emacs-guix" ;pulls in a guix with no substitute available.
   "emacs-magit"
   "emacs-markdown-mode"
   "emacs-no-x"
   "emacs-paredit"
   "emacs-rainbow-delimiters"
   ;;"emacs-gnus"
   ;;"emacs-mu4e"
   ;;"mu" ; maildir search ; pulls in xapian no sub
   "gcc"
   "gettext"
   "git"
   "graphviz"
   "guile-colorized"
   "guile-json"
   "guile-gcrypt"
   "guile-readline"
   "guile-sparql"
   "gzip"
   "help2man"
   ;;"jq"					;json multitool
   "libgcrypt"
   "make"
   "po4a"
   "openssh"
   "readline"
   "screen"
   "sqlite"
   "texinfo"
   "tig" ; Ncurses git log viewer
   "unzip"
   "zlib"
   
   ;;;;;;;;;;;;;;;;;;;;;
   ;; Console GUI :)
   ;;;;;;;;;;;;;;;;;;;;;
   "mc" ; GNU Midnight Commander :D
   "mps-youtube"

   ;;;;;;;;;;;;;;;;;;;;;
   ;; GUI
   ;;;;;;;;;;;;;;;;;;;;;
   "dillo"
   "gnome-screenshot"
   "gnome-tweak-tool"
   ;; Gstreamer for html5 videos to work in browsers
   "gst-libav"
   "gst-plugins-base"
   "gst-plugins-good"
   ;;"icecat" ; rust is not built yet :-/
   "network-manager-openvpn"
   "mpv"
   "sbcl-next"
   "tilda"
   "vimb"
   "workrave"

   ;; Test
   ;;"youtube-viewer" ;bug: pulls in gtk
   ;;"youtube-dl-gui" wxpython takes forever to build
   ;; Missing
   ;; nautilus plugins
   ;; gedit plugins
   ))

^ permalink raw reply	[flat|nested] 9+ messages in thread

* bug#33832: The VPN service 'org.freedesktop.NetworkManager.openvpn' was not installed.
  2018-12-22  3:28 bug#33832: The VPN service 'org.freedesktop.NetworkManager.openvpn' was not installed swedebugia
@ 2019-01-09 12:54 ` Maxim Cournoyer
  2019-01-10 12:51   ` Maxim Cournoyer
  0 siblings, 1 reply; 9+ messages in thread
From: Maxim Cournoyer @ 2019-01-09 12:54 UTC (permalink / raw)
  To: swedebugia; +Cc: 33832

Hi,

swedebugia@riseup.net writes:

> Dec 22 04:21:24 localhost NetworkManager[289]: <info>  [1545448884.2537]
> audit: op="connection-activate"
> uuid="c3d6b24a-d67c-48a9-8695-2e9dd83c1b07" name="Riseup VPN" pid=414
> uid=1000 result="fail" reason="The VPN service
> 'org.freedesktop.NetworkManager.openvpn' was not installed."
> Dec 22 04:22:19 localhost NetworkManager[289]: <info>  [1545448939.2045]
> device (wlp3s0): set-hw-addr: set MAC address to AE:C7:48:B4:FE:7E
> (scanning)
> Dec 22 04:22:19 localhost vmunix: [ 3281.066433] IPv6:
> ADDRCONF(NETDEV_UP): wlp3s0: link is not ready
> Dec 22 04:22:19 localhost NetworkManager[289]: <info>  [1545448939.2203]
> device (wlp3s0): supplicant interface state: inactive -> disabled
> Dec 22 04:22:19 localhost NetworkManager[289]: <info>  [1545448939.2557]
> device (wlp3s0): supplicant interface state: disabled -> inactive
>
> config attached were it is installed systemwide.
>
> my user manifest is also attached were it is also installed.
>
> sdb@antelope ~/src/guix$ guix --version
> guix (GNU Guix) 0.16.0-3.6ddc63e
>
> running from git.

I can confirm the bug; it makes the network-manager-openvpn useless at
what it's supposed to be helpful with ;-).

Given that it seems to be a DBus error, I tried to modify our
network-manager-service-type so that it would consider the VPN plugins
as well when extending the dbus-system-service:

1 file changed, 10 insertions(+), 7 deletions(-)
gnu/services/networking.scm | 17 ++++++++++-------

modified   gnu/services/networking.scm
@@ -919,25 +919,28 @@ and @command{wicd-curses} user interfaces."
               (stop #~(make-kill-destructor))))))))
 
 (define network-manager-service-type
-  (let
-      ((config->package
+  (let*
+      ((config->packages
         (match-lambda
-         (($ <network-manager-configuration> network-manager)
-          (list network-manager)))))
+         (($ <network-manager-configuration> network-manager _ vpn-plugins)
+          `(,network-manager ,@vpn-plugins)))))
 
     (service-type
      (name 'network-manager)
      (extensions
       (list (service-extension shepherd-root-service-type
                                network-manager-shepherd-service)
-            (service-extension dbus-root-service-type config->package)
-            (service-extension polkit-service-type config->package)
+            (service-extension dbus-root-service-type config->packages)
+            (service-extension polkit-service-type
+                               (compose
+                                list
+                                network-manager-configuration-network-manager))
             (service-extension activation-service-type
                                (const %network-manager-activation))
             (service-extension session-environment-service-type
                                network-manager-environment)
             ;; Add network-manager to the system profile.
-            (service-extension profile-service-type config->package)))
+            (service-extension profile-service-type config->packages)))
      (default-value (network-manager-configuration))
      (description
       "Run @uref{https://wiki.gnome.org/Projects/NetworkManager,

Unfortunately that didn't work... I'll have to read on DBus to debug
this further.  Any help would be appreciated :-)

Thanks,

Maxim

^ permalink raw reply	[flat|nested] 9+ messages in thread

* bug#33832: The VPN service 'org.freedesktop.NetworkManager.openvpn' was not installed.
  2019-01-09 12:54 ` Maxim Cournoyer
@ 2019-01-10 12:51   ` Maxim Cournoyer
  2019-02-19 20:10     ` Tomáš Čech
  0 siblings, 1 reply; 9+ messages in thread
From: Maxim Cournoyer @ 2019-01-10 12:51 UTC (permalink / raw)
  To: swedebugia; +Cc: 33832

Debugging a bit further, it seems that my change to the
network-manager-service-type had the following effect:

A file populated at /etc/dbus-1/system-local.conf now has an include
directive for network-manager-openvpn:

--8<---------------cut here---------------start------------->8---
<includedir>/gnu/store/gw3ckmw2pihc44d23lc8pipfw7wr16g7-network-manager-openvpn-1.8.0/etc/dbus-1/system.d</includedir>
--8<---------------cut here---------------end--------------->8---

There is no /etc/dbus-1/system.conf file, which usually should source
the above system-local.conf, although the package holds a copy of it
such as
/gnu/store/5bda3bgy871dyb9cna4k7gnz002j88rq-dbus-1.12.6/share/dbus-1/system.conf,
and this file has:

--8<---------------cut here---------------start------------->8---
<!-- This is included last so local configuration can override what's

       in this standard file -->
  <include ignore_missing="yes">/etc/dbus-1/system-local.conf</include>
--8<---------------cut here---------------end--------------->8---

I'm not sure if it works though, because using the Emacs dbus support to
view the available definitions, I cannot see the ones from the
system-local.conf file:

--8<---------------cut here---------------start------------->8---
(require 'dbus)
(dbus-list-activatable-names ':system)

;; Results:
("org.freedesktop.DBus"		     ;
 "org.freedesktop.UPower"	     ;from /etc/dbus-1/system-services
 "org.freedesktop.GeoClue2"	     ;from /etc/dbus-1/system-services
 "org.freedesktop.login1"	     ;from /etc/dbus-1/system-services
 "org.freedesktop.UDisks2"	     ;from /etc/dbus-1/system-services
 "org.freedesktop.ColorHelper"	     ;from /etc/dbus-1/system-services
 "org.freedesktop.PolicyKit1"	     ;from /etc/dbus-1/system-services
 "org.freedesktop.Accounts"	     ;from /etc/dbus-1/system-services
 "org.freedesktop.ColorManager"	     ;from /etc/dbus-1/system-services
 "org.freedesktop.nm_dispatcher")	;from /etc/dbus-1/system-services
--8<---------------cut here---------------end--------------->8---

So it could be that the system-local.conf file is not read in.

I've tried stracing the dbus-daemon (by attaching to it) as suggested by
Ludovic on #guix, but that doesn't mention anything about reading the
files.

So, to debug this further, I've added the documentation to dbus [1] and
in `man dbus-daemon`, we can read:



--8<---------------cut here---------------start------------->8---
DEBUGGING
       If you're trying to figure out where your messages are going or why you aren't getting messages, there are
       several things you can try.

       Remember that the system bus is heavily locked down and if you haven't installed a security policy file to
       allow your message through, it won't work. For the session bus, this is not a concern.

       The simplest way to figure out what's happening on the bus is to run the dbus-monitor program, which comes
       with the D-Bus package. You can also send test messages with dbus-send. These programs have their own man
       pages.

       If you want to know what the daemon itself is doing, you might consider running a separate copy of the daemon
       to test against. This will allow you to put the daemon under a debugger, or run it with verbose output,
       without messing up your real session and system daemons.

       To run a separate test copy of the daemon, for example you might open a terminal and type:

             DBUS_VERBOSE=1 dbus-daemon --session --print-address

       The test daemon address will be printed when the daemon starts. You will need to copy-and-paste this address
       and use it as the value of the DBUS_SESSION_BUS_ADDRESS environment variable when you launch the applications
       you want to test. This will cause those applications to connect to your test bus instead of the
       DBUS_SESSION_BUS_ADDRESS of your real session bus.

       DBUS_VERBOSE=1 will have NO EFFECT unless your copy of D-Bus was compiled with verbose mode enabled. This is
       not recommended in production builds due to performance impact. You may need to rebuild D-Bus if your copy
       was not built with debugging in mind. (DBUS_VERBOSE also affects the D-Bus library and thus applications
       using D-Bus; it may be useful to see verbose output on both the client side and from the daemon.)

       If you want to get fancy, you can create a custom bus configuration for your test bus (see the session.conf
       and system.conf files that define the two default configurations for example). This would allow you to
       specify a different directory for .service files, for example.
--8<---------------cut here---------------end--------------->8---

This should help in further debbugging the issue, along with this local
definition that enables the verbose mode of dbus:

--8<---------------cut here---------------start------------->8---
gnu/packages/glib.scm | 11 +++++++++++

modified   gnu/packages/glib.scm
@@ -68,6 +68,7 @@
   ;; Export variables up-front to allow circular dependency with the 'xorg'
   ;; module.
   #:export (dbus
+            my-dbus
             glib
             gobject-introspection
             dbus-glib
@@ -156,6 +157,16 @@ or through unencrypted TCP/IP suitable for use behind a firewall with
 shared NFS home directories.")
     (license license:gpl2+)))                     ; or Academic Free License 2.1
 
+(define my-dbus
+  (package
+    (inherit dbus)
+    (name "my-dbus")
+    (arguments
+     (substitute-keyword-arguments
+         (package-arguments dbus)
+       ((#:configure-flags flags)
+        `(cons "--enable-verbose-mode" ,flags))))))
+
 (define glib
   (package
    (name "glib")
--8<---------------cut here---------------end--------------->8---

To be continued...

Maxim

[1]:  https://debbugs.gnu.org/cgi/bugreport.cgi?bug=34028

^ permalink raw reply	[flat|nested] 9+ messages in thread

* bug#33832: The VPN service 'org.freedesktop.NetworkManager.openvpn' was not installed.
  2019-01-10 12:51   ` Maxim Cournoyer
@ 2019-02-19 20:10     ` Tomáš Čech
  2019-03-06 13:19       ` Ludovic Courtès
  0 siblings, 1 reply; 9+ messages in thread
From: Tomáš Čech @ 2019-02-19 20:10 UTC (permalink / raw)
  To: Maxim Cournoyer; +Cc: 33832

[-- Attachment #1: Type: text/plain, Size: 8391 bytes --]

On Thu, Jan 10, 2019 at 07:51:07AM -0500, Maxim Cournoyer wrote:
>Debugging a bit further, it seems that my change to the
>network-manager-service-type had the following effect:
>
>A file populated at /etc/dbus-1/system-local.conf now has an include
>directive for network-manager-openvpn:
>
>--8<---------------cut here---------------start------------->8---
><includedir>/gnu/store/gw3ckmw2pihc44d23lc8pipfw7wr16g7-network-manager-openvpn-1.8.0/etc/dbus-1/system.d</includedir>
>--8<---------------cut here---------------end--------------->8---
>
>There is no /etc/dbus-1/system.conf file, which usually should source
>the above system-local.conf, although the package holds a copy of it
>such as
>/gnu/store/5bda3bgy871dyb9cna4k7gnz002j88rq-dbus-1.12.6/share/dbus-1/system.conf,
>and this file has:
>
>--8<---------------cut here---------------start------------->8---
><!-- This is included last so local configuration can override what's
>
>       in this standard file -->
>  <include ignore_missing="yes">/etc/dbus-1/system-local.conf</include>
>--8<---------------cut here---------------end--------------->8---
>
>I'm not sure if it works though, because using the Emacs dbus support to
>view the available definitions, I cannot see the ones from the
>system-local.conf file:
>
>--8<---------------cut here---------------start------------->8---
>(require 'dbus)
>(dbus-list-activatable-names ':system)
>
>;; Results:
>("org.freedesktop.DBus"		     ;
> "org.freedesktop.UPower"	     ;from /etc/dbus-1/system-services
> "org.freedesktop.GeoClue2"	     ;from /etc/dbus-1/system-services
> "org.freedesktop.login1"	     ;from /etc/dbus-1/system-services
> "org.freedesktop.UDisks2"	     ;from /etc/dbus-1/system-services
> "org.freedesktop.ColorHelper"	     ;from /etc/dbus-1/system-services
> "org.freedesktop.PolicyKit1"	     ;from /etc/dbus-1/system-services
> "org.freedesktop.Accounts"	     ;from /etc/dbus-1/system-services
> "org.freedesktop.ColorManager"	     ;from /etc/dbus-1/system-services
> "org.freedesktop.nm_dispatcher")	;from /etc/dbus-1/system-services
>--8<---------------cut here---------------end--------------->8---
>
>So it could be that the system-local.conf file is not read in.
>
>I've tried stracing the dbus-daemon (by attaching to it) as suggested by
>Ludovic on #guix, but that doesn't mention anything about reading the
>files.
>
>So, to debug this further, I've added the documentation to dbus [1] and
>in `man dbus-daemon`, we can read:
>
>
>
>--8<---------------cut here---------------start------------->8---
>DEBUGGING
>       If you're trying to figure out where your messages are going or why you aren't getting messages, there are
>       several things you can try.
>
>       Remember that the system bus is heavily locked down and if you haven't installed a security policy file to
>       allow your message through, it won't work. For the session bus, this is not a concern.
>
>       The simplest way to figure out what's happening on the bus is to run the dbus-monitor program, which comes
>       with the D-Bus package. You can also send test messages with dbus-send. These programs have their own man
>       pages.
>
>       If you want to know what the daemon itself is doing, you might consider running a separate copy of the daemon
>       to test against. This will allow you to put the daemon under a debugger, or run it with verbose output,
>       without messing up your real session and system daemons.
>
>       To run a separate test copy of the daemon, for example you might open a terminal and type:
>
>             DBUS_VERBOSE=1 dbus-daemon --session --print-address
>
>       The test daemon address will be printed when the daemon starts. You will need to copy-and-paste this address
>       and use it as the value of the DBUS_SESSION_BUS_ADDRESS environment variable when you launch the applications
>       you want to test. This will cause those applications to connect to your test bus instead of the
>       DBUS_SESSION_BUS_ADDRESS of your real session bus.
>
>       DBUS_VERBOSE=1 will have NO EFFECT unless your copy of D-Bus was compiled with verbose mode enabled. This is
>       not recommended in production builds due to performance impact. You may need to rebuild D-Bus if your copy
>       was not built with debugging in mind. (DBUS_VERBOSE also affects the D-Bus library and thus applications
>       using D-Bus; it may be useful to see verbose output on both the client side and from the daemon.)
>
>       If you want to get fancy, you can create a custom bus configuration for your test bus (see the session.conf
>       and system.conf files that define the two default configurations for example). This would allow you to
>       specify a different directory for .service files, for example.
>--8<---------------cut here---------------end--------------->8---
>
>This should help in further debbugging the issue, along with this local
>definition that enables the verbose mode of dbus:
>
>--8<---------------cut here---------------start------------->8---
>gnu/packages/glib.scm | 11 +++++++++++
>
>modified   gnu/packages/glib.scm
>@@ -68,6 +68,7 @@
>   ;; Export variables up-front to allow circular dependency with the 'xorg'
>   ;; module.
>   #:export (dbus
>+            my-dbus
>             glib
>             gobject-introspection
>             dbus-glib
>@@ -156,6 +157,16 @@ or through unencrypted TCP/IP suitable for use behind a firewall with
> shared NFS home directories.")
>     (license license:gpl2+)))                     ; or Academic Free License 2.1
>
>+(define my-dbus
>+  (package
>+    (inherit dbus)
>+    (name "my-dbus")
>+    (arguments
>+     (substitute-keyword-arguments
>+         (package-arguments dbus)
>+       ((#:configure-flags flags)
>+        `(cons "--enable-verbose-mode" ,flags))))))
>+
> (define glib
>   (package
>    (name "glib")
>--8<---------------cut here---------------end--------------->8---
>
>To be continued...

You seem to be on very right track. There is another unexpect problem
- NetworkManager doesn't seem to respect NM_VPN_PLUGIN_PATH in the
right place.

Try this quick patch:

From fc8bbfe018b4f19fb383391c71e3518a9c46e0f3 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Tom=C3=A1=C5=A1=20=C4=8Cech?= <sleep_walker@gnu.org>
Date: Sun, 17 Feb 2019 13:23:43 +0100
Subject: [PATCH] respect NM_VPN_PLUGIN_DIR

---
 src/vpn/nm-vpn-manager.c | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/src/vpn/nm-vpn-manager.c b/src/vpn/nm-vpn-manager.c
index 8e708d1..86238c9 100644
--- a/src/vpn/nm-vpn-manager.c
+++ b/src/vpn/nm-vpn-manager.c
@@ -223,6 +223,7 @@ nm_vpn_manager_init (NMVpnManager *self)
 	GSList *infos, *info;
 	const char *conf_dir_etc = _nm_vpn_plugin_info_get_default_dir_etc ();
 	const char *conf_dir_lib = _nm_vpn_plugin_info_get_default_dir_lib ();
+        const char *conf_dir_user = _nm_vpn_plugin_info_get_default_dir_user ();
 
 	/* Watch the VPN directory for changes */
 	file = g_file_new_for_path (conf_dir_lib);
@@ -241,6 +242,14 @@ nm_vpn_manager_init (NMVpnManager *self)
 		                                         G_CALLBACK (vpn_dir_changed), self);
 	}
 
+	file = g_file_new_for_path (conf_dir_user);
+	priv->monitor_etc = g_file_monitor_directory (file, G_FILE_MONITOR_NONE, NULL, NULL);
+	g_object_unref (file);
+	if (priv->monitor_etc) {
+		priv->monitor_id_etc = g_signal_connect (priv->monitor_etc, "changed",
+		                                         G_CALLBACK (vpn_dir_changed), self);
+	}
+
 	/* first read conf_dir_lib. The name files are not really user configuration, but
 	 * plugin configuration. Hence we expect ~newer~ plugins to install their files
 	 * in /usr/lib/NetworkManager. We want to prefer those files.
@@ -255,6 +264,11 @@ nm_vpn_manager_init (NMVpnManager *self)
 		try_add_plugin (self, info->data);
 	g_slist_free_full (infos, g_object_unref);
 
+	infos = _nm_vpn_plugin_info_list_load_dir (conf_dir_user, TRUE, 0, NULL, NULL);
+	for (info = infos; info; info = info->next)
+		try_add_plugin (self, info->data);
+	g_slist_free_full (infos, g_object_unref);
+
 	priv->active_services = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, NULL);
 }
 
-- 
2.20.1

HTH,

S_W

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply related	[flat|nested] 9+ messages in thread

* bug#33832: The VPN service 'org.freedesktop.NetworkManager.openvpn' was not installed.
  2019-02-19 20:10     ` Tomáš Čech
@ 2019-03-06 13:19       ` Ludovic Courtès
  2019-03-06 13:29         ` Tomáš Čech
  0 siblings, 1 reply; 9+ messages in thread
From: Ludovic Courtès @ 2019-03-06 13:19 UTC (permalink / raw)
  To: Tomáš Čech; +Cc: Maxim Cournoyer, 33832

Hi Tomáš,

Tomáš Čech <sleep_walker@gnu.org> skribis:

> On Thu, Jan 10, 2019 at 07:51:07AM -0500, Maxim Cournoyer wrote:

[...]

>>To be continued...
>
> You seem to be on very right track. There is another unexpect problem
> - NetworkManager doesn't seem to respect NM_VPN_PLUGIN_PATH in the
> right place.
>
> Try this quick patch:
>
> From fc8bbfe018b4f19fb383391c71e3518a9c46e0f3 Mon Sep 17 00:00:00 2001
> From: =?UTF-8?q?Tom=C3=A1=C5=A1=20=C4=8Cech?= <sleep_walker@gnu.org>
> Date: Sun, 17 Feb 2019 13:23:43 +0100
> Subject: [PATCH] respect NM_VPN_PLUGIN_DIR

Does this patch solve the problem for you?  How did you get there?  :-)

Thanks,
Ludo’.

^ permalink raw reply	[flat|nested] 9+ messages in thread

* bug#33832: The VPN service 'org.freedesktop.NetworkManager.openvpn' was not installed.
  2019-03-06 13:19       ` Ludovic Courtès
@ 2019-03-06 13:29         ` Tomáš Čech
  2019-06-24 19:34           ` Jelle Licht
  0 siblings, 1 reply; 9+ messages in thread
From: Tomáš Čech @ 2019-03-06 13:29 UTC (permalink / raw)
  To: Ludovic Courtès; +Cc: Maxim Cournoyer, 33832

[-- Attachment #1: Type: text/plain, Size: 1253 bytes --]

Hi Ludo,

On Wed, Mar 06, 2019 at 02:19:20PM +0100, Ludovic Courtès wrote:
>Hi Tomáš,
>
>Tomáš Čech <sleep_walker@gnu.org> skribis:
>
>> On Thu, Jan 10, 2019 at 07:51:07AM -0500, Maxim Cournoyer wrote:
>
>[...]
>
>>>To be continued...
>>
>> You seem to be on very right track. There is another unexpect problem
>> - NetworkManager doesn't seem to respect NM_VPN_PLUGIN_PATH in the
>> right place.
>>
>> Try this quick patch:
>>
>> From fc8bbfe018b4f19fb383391c71e3518a9c46e0f3 Mon Sep 17 00:00:00 2001
>> From: =?UTF-8?q?Tom=C3=A1=C5=A1=20=C4=8Cech?= <sleep_walker@gnu.org>
>> Date: Sun, 17 Feb 2019 13:23:43 +0100
>> Subject: [PATCH] respect NM_VPN_PLUGIN_DIR
>
>Does this patch solve the problem for you?  How did you get there?  :-)

Partially. I was not interested in OpenVPN, but L2TP/IPSec VPN (my new
employer is using) so I was using network-manager-l2tp module with the same problems.
(Actually it is much more painful because it requires some more
patching of xl2tpd and strongswan to bring it up together... They have
somehow hardcoded locations for configuration and secrets...)

But with Maxim's DBus related patches and my NM patch it seemed to be
starting daemons at least.

Best regards,

S_W

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* bug#33832: The VPN service 'org.freedesktop.NetworkManager.openvpn' was not installed.
  2019-03-06 13:29         ` Tomáš Čech
@ 2019-06-24 19:34           ` Jelle Licht
  2019-06-26  8:20             ` Tomáš Čech
  0 siblings, 1 reply; 9+ messages in thread
From: Jelle Licht @ 2019-06-24 19:34 UTC (permalink / raw)
  To: Tomáš Čech, Ludovic Courtès; +Cc: Maxim Cournoyer, 33832

Hi S_W, Maxim

Tomáš Čech <sleep_walker@gnu.org> writes:

> Hi Ludo,
> [...]
>
> But with Maxim's DBus related patches and my NM patch it seemed to be
> starting daemons at least.

Do you still have the patches for these changes lying around? I am
trying to get network-manager-vpnc packaged+working, but it seems this
issue will also need to be solved first.
>
> Best regards,
>
> S_W

All the best,

Jelle

^ permalink raw reply	[flat|nested] 9+ messages in thread

* bug#33832: The VPN service 'org.freedesktop.NetworkManager.openvpn' was not installed.
  2019-06-24 19:34           ` Jelle Licht
@ 2019-06-26  8:20             ` Tomáš Čech
  2019-09-27 20:46               ` Jelle Licht
  0 siblings, 1 reply; 9+ messages in thread
From: Tomáš Čech @ 2019-06-26  8:20 UTC (permalink / raw)
  To: Jelle Licht; +Cc: Maxim Cournoyer, 33832

[-- Attachment #1: Type: text/plain, Size: 629 bytes --]

Hi!

On Mon, Jun 24, 2019 at 09:34:34PM +0200, Jelle Licht wrote:
>Hi S_W, Maxim
>
>Tomáš Čech <sleep_walker@gnu.org> writes:
>
>> Hi Ludo,
>> [...]
>>
>> But with Maxim's DBus related patches and my NM patch it seemed to be
>> starting daemons at least.
>
>Do you still have the patches for these changes lying around? I am
>trying to get network-manager-vpnc packaged+working, but it seems this
>issue will also need to be solved first.

I didn't have time to refresh it to our current version - it's just in the mail:

https://www.mail-archive.com/bug-guix@gnu.org/msg11776.html

Best regards,

S_W

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* bug#33832: The VPN service 'org.freedesktop.NetworkManager.openvpn' was not installed.
  2019-06-26  8:20             ` Tomáš Čech
@ 2019-09-27 20:46               ` Jelle Licht
  0 siblings, 0 replies; 9+ messages in thread
From: Jelle Licht @ 2019-09-27 20:46 UTC (permalink / raw)
  To: Tomáš Čech; +Cc: Maxim Cournoyer, 33832-done



> [snip]
> I didn't have time to refresh it to our current version - it's just in the mail:
>
> https://www.mail-archive.com/bug-guix@gnu.org/msg11776.html

Closing, this was fixed a while ago in commit
40557aeab594907bf56b0a2a367061dbdd19f4aa.

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2019-09-27 20:47 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-12-22  3:28 bug#33832: The VPN service 'org.freedesktop.NetworkManager.openvpn' was not installed swedebugia
2019-01-09 12:54 ` Maxim Cournoyer
2019-01-10 12:51   ` Maxim Cournoyer
2019-02-19 20:10     ` Tomáš Čech
2019-03-06 13:19       ` Ludovic Courtès
2019-03-06 13:29         ` Tomáš Čech
2019-06-24 19:34           ` Jelle Licht
2019-06-26  8:20             ` Tomáš Čech
2019-09-27 20:46               ` Jelle Licht

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).