app-emulation/libvirt depends on net-analyzer/netcat. The latter does not support the "-U" option for connecting to UNIX sockets on Gentoo, which remote virsh/libvirt-installations expect to be supported when connection over a SSH tunnel, thus failing with: --- snip --- user@some-host:~$ virsh -c "qemu+ssh://remoteuser@gentoo-libvirt-host/system" Connecting to uri: qemu+ssh://remoteuser@gentoo-libvirt-host/system nc: invalid option -- 'U' nc -h for help libvir: Remote error : socket closed unexpectedly error: failed to connect to the hypervisor --- snip --- Reproducible: Always Steps to Reproduce: 1. Install libvirt (thereby pulling netcat) on Gentoo 2. connect to Gentoo libvirtd from another machine via virsh or virt-manager using SSH tunnelling 3. virsh or virt-manager cannot connect to Gentoo's libvirtd due to `nc` bailing on an unknown option on its command line Actual Results: Remote management of virtual machines using libvirt on Gentoo hosts is impossible, as the connection to the libvirt daemon cannot be established. Expected Results: virsh/virt-manager should be able to connect to libvirtd on Gentoo just fine. It works fine with the net-analyzer/netcat6 program (after renaming/symlinking its binary from `nc6` to `nc`). This however conflicts with app-emulation/libvirt dependencies, as it pulls net-analyzer/netcat expliciitly. It may be wise to drop net-analyzer/netcat in favour of net-analyzer/netcat6, and have its ebuild automatically link /usr/bin/nc to /usr/bin/nc6.
Created attachment 201232 [details, diff] patch making libvirt ebuild depend on net-analyzer/netcat6 insetad of net-analyzer/netcat Note: this won't yield anything without an appropriately modified net-analyzer/netcat6 ebuild!
Created attachment 201234 [details, diff] Patch for net-analyzer/netcat6 ebuild for compatibility with netcat and libvirt This should probably also block on other installed versions of netcat. Maybe a virtual for netcat would be warranted?
Created attachment 201236 [details, diff] patch making libvirt ebuild depend on net-analyzer/netcat6 insetad of net-analyzer/netcat (correct version) This is what you get from having your shell expand wildcards... Patch should make sense now.
+ 08 Sep 2009; Patrick Lauer <patrick@gentoo.org> +libvirt-0.6.5-r1.ebuild: + Fixing netcat dep #280650 #237277 #283884