I am trying to share a folder between host and a VM. When starting the VM I get the following message: Error: Failed to start device "shared": Required binary 'virtfs-proxy-helper' couldn't be found Reproducible: Always Steps to Reproduce: 1. share folder with VM: devices: shared: path: /tmp/shared source: /tmp/shared type: disk 2. try to start VM Actual Results: Error: Failed to start device "shared": Required binary 'virtfs-proxy-helper' couldn't be found Expected Results: Should work. I have analyzed the code. LXD ist looking in PATH for virtfs-proxy-helper. [0] In gentoo the file is installed to /usr/libexec/virtfs-proxy-helper which is not in PATH. There is an alternative hardcoded PATH where LXD is looking for the executable, but it assumes running on a Debian based distribution. [1] Changing the hardcoded path fixes the issue for gentoo: sed -i \ -e "s:/usr/lib/qemu/virtfs-proxy-helper:/usr/libexec/virtfs-proxy-helper:g" \ lxd/device/disk.go || die "Failed to fix virtfs-proxy-helper path." I will attach a patch for the ebuild. [0] https://github.com/lxc/lxd/blob/lxd-4.0.6/lxd/device/disk.go#L572 [1] https://github.com/lxc/lxd/blob/lxd-4.0.6/lxd/device/disk.go#L574
Created attachment 719607 [details, diff] Patch to fix virtfs-proxy-helper path
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=41765dab645acb31174d787d8d7c4288ae8bce18 commit 41765dab645acb31174d787d8d7c4288ae8bce18 Author: Benedikt Neuffer <gentoo@itfriend.de> AuthorDate: 2021-06-27 14:55:09 +0000 Commit: Joonas Niilola <juippis@gentoo.org> CommitDate: 2021-06-30 04:39:29 +0000 app-emulation/lxd: fix virtfs-proxy-helper path Closes: https://bugs.gentoo.org/798924 Signed-off-by: Joonas Niilola <juippis@gentoo.org> app-emulation/lxd/lxd-4.0.6.ebuild | 5 +++++ 1 file changed, 5 insertions(+)
Thanks for the patch, much appreciated! xen also installs virtfs-proxy-helper but I see lxd was meant for it to be used with qemu.
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5bd04ef5dc1514fe99e65550f7e72bcf7ab993eb commit 5bd04ef5dc1514fe99e65550f7e72bcf7ab993eb Author: Joonas Niilola <juippis@gentoo.org> AuthorDate: 2022-02-02 08:45:41 +0000 Commit: Joonas Niilola <juippis@gentoo.org> CommitDate: 2022-02-02 08:53:06 +0000 app-containers/lxd: add 4.0.9 - inherit go-module.eclass; upstream uses go.mod now, - new documentation offered by upstream, e.g. a handy cheatsheet, - openrc init file and systemd service file now manages the log directory (#817287), - virtfs-proxy-helper bin path isn't hardcoded anymore (#798924), - -Werror patch turned into sed for easier maintainability. Bug: https://bugs.gentoo.org/798924 Closes: https://bugs.gentoo.org/817287 Signed-off-by: Joonas Niilola <juippis@gentoo.org> app-containers/lxd/Manifest | 2 + app-containers/lxd/files/lxd-4.0.9.initd | 49 ++++++++ app-containers/lxd/files/lxd-4.0.9.service | 25 +++++ app-containers/lxd/lxd-4.0.9.ebuild | 174 +++++++++++++++++++++++++++++ 4 files changed, 250 insertions(+)
https://github.com/lxc/lxd/issues/10092
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=88557686e5382ac1e164f61c72bb63a7a076a240 commit 88557686e5382ac1e164f61c72bb63a7a076a240 Author: Joonas Niilola <juippis@gentoo.org> AuthorDate: 2022-03-21 09:26:12 +0000 Commit: Joonas Niilola <juippis@gentoo.org> CommitDate: 2022-03-21 09:31:12 +0000 app-containers/lxd: fix finding virtfs-proxy-helper, again - the code has been divided amongst different files. Closes: https://bugs.gentoo.org/798924 Signed-off-by: Joonas Niilola <juippis@gentoo.org> app-containers/lxd/{lxd-4.0.9-r2.ebuild => lxd-4.0.9-r3.ebuild} | 5 +++++ 1 file changed, 5 insertions(+)