December 8, 20232 yr Hello, My goal was to move the Libvirt storage location from /mnt/vms_nvme/libvirt.img to a new larger NVME - /mnt/vms2_nvme/libvirt.img. I did not delete the image file from the original location or delete any other files. I disabled VM using VM Manager and updated the location to /mnt/vms2_nvme/libvirt.img and then I enabled VM. When I checked VM's there was nothing there and then I thought it was because there was no libvirt.img file in the new location. I wanted to go back to the original location and when I did that, there were still no VM's listed. Is there a way I can restore my original setup? I have attached the diagnostics for your review. Thanks in advance for anyone who can help. frankenstein-diagnostics-20231208-1141.zip
December 8, 20232 yr Author Adding some information from the libvirt log I see the Network error but in the VM Manager the Default Network Source is virbr0
December 8, 20232 yr Community Expert 15 minutes ago, Ablatem said: I disabled VM using VM Manager and updated the location to /mnt/vms2_nvme/libvirt.img and then I enabled VM. But did you move the existing file to the new location? If not it'd create a new empty one. When changing you may need to stop the array completely or even reboot, stopping/starting VM without also stopping Docker often causes libvirt.img not to unmount correctly. 16 minutes ago, Ablatem said: to a new larger NVME Why? It's just 1GB.
December 8, 20232 yr Author Hello, @Kilrah, Thanks for your response. I did not move the existing file before so I thought that could be the issue. I wanted to go back to the original location and that is when I saw no VM's. I just tried restarting the array and that didn't make any difference so I took another look at the locations. I see a problem - in both locations (/mnt/vms_nvme and /mnt/vms2_nvme) there are libvirt.img files - so 2 image files. Both are the same size - 1.07 GB I thought about what you mentioned about the file size being only 1 GB and I decided that it could be left where it is and I can move VM's from the original nvme over to the new nvme to make a little extra space. With that being said, I assume that now I need to delete the libvirt.img file located in the new location: /mnt/vms2_nvme - then restart the array again. I know what happens when you assume so can you confirm that?
December 8, 20232 yr Community Expert Deleting the new one and making sure the settings point to the "old" file should work. I would set VM and Docker services to disabled, reboot, check after starting array that the file is at the expected place and settings point to it, then restart the services. Edited December 8, 20232 yr by Kilrah
December 9, 20232 yr Author I deleted the new libvirt.img file and made sure VM Manager was set to point to the original location. I disabled Docker and VM then I rebooted. When it came back online, I confirmed that the VM Manager location was the same and it was. I started Docker and VM. When I checked VM, there were still no VMs listed. I looked at the libvirt log and I see an error about the Network interface being already in use by interface br0 - I don't know where this is coming from because in VM Manager, the Default network source is virbr0 I see this under Libvirt volume info - Should I check Correct file system errors and click 'scrub'?
December 9, 20232 yr Community Expert If you don't have the old libvirt or a backup you can recreate the VMs and point to the existing vdisks.
December 9, 20232 yr Author Thanks for the reply, @JorgeB. I do have the old libvirt and I am pointing to it but I can't get any vm's to be listed. The libvirt.img file I have is 1.07 GB. Is there a documented process for recreating the VM's using the existing vdisk file? I am making a copy of one of my existing VM's vdisk and then I was going to attempt to recreate it. Could the network error I am seeing in the libvirt log be causing a problem with not being able to see the existing vm's?
December 9, 20232 yr Author Solution I was able to restore a 'test' vm which looks fine. I created a new vm and used the same name as before as assigned CPU and RAM. The Primary vDisk location is set to Auto since it was using a valid path - /mnt/user/domains/RedHat/vdisk1.img Network Source is virbrO Network Model is virtio-net I didn't make any other changes. So far so good - I will take another look at it and then try a restore of another VM. Does this sounds like the correct process to use as far as recreating the vm's? Note: I had to change the Network Source to br0 - Network Model - left this the same - virtio-net This change gave me network connectivity. I will use this setting going forward. Edited December 9, 20232 yr by Ablatem
December 10, 20232 yr Community Expert 18 hours ago, Ablatem said: Does this sounds like the correct process to use as far as recreating the vm's? Yes, that should do it.
December 11, 20232 yr Author Thanks @Kilrah and @JorgeB for your assistance. I have been able to recreate my original VM's with no issues using the steps I mentioned above in the comment I marked as the solution. I appreciate the help.
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.