Hi,<br><br>Non-root can't use /var/run/libvirt/libvirt-sock even in the case<br>"unix_sock_group" and "unix_sock_rw_perms" are set properly.<br><br>The reason:<br> # ls -l /var/run /var/run/libvirt | grep libvirt | grep -v pid<br>
drwx------ 2 root root 4096 Apr 14 19:14 libvirt<br> srwxrwx--- 1 root libvirt 0 Apr 14 19:14 libvirt-sock<br> srwxrwxrwx 1 root libvirt 0 Apr 14 19:14 libvirt-sock-ro<br><br>
i.e., bad permissions on /var/run/libvirt<br><br>One possible solution (implied in the attached patch) is the following:<br><br>Every time libvirtd starts<br>* it implicitly sets the group id of /var/run/libvirt:<br> chown(/var/run/libvirt, -1, unix_sock_gid).<br>
* if "unix_sock_group" defined in /etc/libvirt/libvirtd.conf, libvirtd does<br> chmod g+x /var/run/libvirt<br> otherwise,<br> chmod g-x /var/run/libvirt<br><br>A.