I have installed Virtualizor (KVM) on a CentOS server and I’m trying to create a VPS
I have added storage and an IP pool for my VMs
for creating storage I followed this guide
https://www.virtualizor.com/wiki/Add_New_Storage
when I try to create a VPS it fails and gives me the following logssh: /bin/chattr: Permission denied Starting Task : 12 Syncing up with Slave Creating VPS : 3 File descriptor 3 (socket:[147315]) leaked on lvcreate invocation. Parent PID 43360: /usr/local/emps/bin/php File descriptor 4 (socket:[147332]) leaked on lvcreate invocation. Parent PID 43360: /usr/local/emps/bin/php File descriptor 5 (socket:[164259]) leaked on lvcreate invocation. Parent PID 43360: /usr/local/emps/bin/php selabel_open failed: No such file or directory selabel_open failed: No such file or directory WARNING: dos signature detected on /dev/vg1/vsv1003-doguu2eku8qqo2f6- d8m51fxht2j4olsu at offset 510. Wipe it? [y/n]: [n] Aborted wiping of dos. 1 existing signature left on the device. File descriptor 3 (socket:[147315]) leaked on lvdisplay invocation. Parent PID 43360: /usr/local/emps/bin/php File descriptor 4 (socket:[147332]) leaked on lvdisplay invocation. Parent PID 43360: /usr/local/emps/bin/php File descriptor 5 (socket:[164259]) leaked on lvdisplay invocation. Parent PID 43360: /usr/local/emps/bin/php selabel_open failed: No such file or directory selabel_open failed: No such file or directory File descriptor 3 (socket:[147315]) leaked on lvresize invocation. Parent PID 43360: /usr/local/emps/bin/php File descriptor 4 (socket:[147332]) leaked on lvresize invocation. Parent PID 43360: /usr/local/emps/bin/php File descriptor 5 (socket:[164259]) leaked on lvresize invocation. Parent PID 43360: /usr/local/emps/bin/php selabel_open failed: No such file or directory selabel_open failed: No such file or directory New size (25600 extents) matches existing size (25600 extents). sfdisk: Warning: The partition table looks like it was made for C/H/S=*/4/32 (instead of 13054/255/63). For this listing I'll assume that geometry. Checking that no-one is using this disk right now ... BLKRRPART: Invalid argument OK sfdisk: Warning: The partition table looks like it was made for C/H/S=*/4/32 (instead of 13054/255/63). For this listing I'll assume that geometry. Warning: partition 1 does not end at a cylinder boundary Warning: partition 2 does not start at a cylinder boundary Warning: partition 2 does not end at a cylinder boundary Warning: no primary partition is marked bootable (active) This does not matter for LILO, but the DOS MBR will not boot this disk. BLKRRPART: Invalid argument If you created or changed a DOS partition, /dev/foo7, say, then use dd(1) to zero the first 512 bytes: dd if=/dev/zero of=/dev/foo7 bs=512 count=1 (See fdisk(8).) mkswap: /dev/mapper/vg1-vsv1003--doguu2eku8qqo2f6--d8m51fxht2j4olsu2: warning: wiping old swap signature. device-mapper: remove ioctl on vg1-vsv1003--doguu2eku8qqo2f6-- d8m51fxht2j4olsu2 failed: Device or resource busy e2fsck 1.42.9 (28-Dec-2013) resize2fs 1.42.9 (28-Dec-2013) setlocale: No such file or directory error: failed to connect to the hypervisor error: Failed to connect socket to '/var/run/libvirt/libvirt-sock': No such file or directory Creation Done Setting Root / Admin Password setlocale: No such file or directory error: failed to connect to the hypervisor error: Failed to connect socket to '/var/run/libvirt/libvirt-sock': No such file or directory Building DHCP Redirecting to /bin/systemctl restart dhcpd.service Starting VPS setlocale: No such file or directory error: failed to connect to the hypervisor error: Failed to connect socket to '/var/run/libvirt/libvirt-sock': No such file or directory setlocale: No such file or directory error: failed to connect to the hypervisor error: Failed to connect socket to '/var/run/libvirt/libvirt-sock': No such file or directory setlocale: No such file or directory error: failed to connect to the hypervisor error: Failed to connect socket to '/var/run/libvirt/libvirt-sock': No such file or directory Fetching VPS Status setlocale: No such file or directory error: failed to connect to the hypervisor error: Failed to connect socket to '/var/run/libvirt/libvirt-sock': No such file or directory
I also noticed that libvirtd service fails to start with the following errors
Oct 17 09:12:40 master libvirtd[42928]: 2018-10-17 13:12:40.091+0000: 42944: info : hostname: master Oct 17 09:12:40 master libvirtd[42928]: 2018-10-17 13:12:40.091+0000: 42944: error : virSecuritySELinuxQEMUInitialize:634 : cannot open SELinux label_handle: No such file or directory Oct 17 09:12:40 master libvirtd[42928]: 2018-10-17 13:12:40.093+0000: 42944: error : qemuSecurityInit:447 : internal error: Failed to initialize security drivers Oct 17 09:12:40 master libvirtd[42928]: 2018-10-17 13:12:40.093+0000: 42944: error : virStateInitialize:775 : Initialization of QEMU state driver failed: internal error: Failed to initialize security drivers Oct 17 09:12:40 master libvirtd[42928]: 2018-10-17 13:12:40.093+0000: 42944: error : daemonRunStateInit:837 : Driver state initialization failed
Anybody has any idea what is wrong with my installation?
Answer
i looked around and the problem was actually SElinux
i disabled SElinux by editing the /etc/selinux/config file and rebooted the server which solved the issue
Attribution
Source : Link , Question Author : moses , Answer Author : moses