Renamed pool and can't get VM working anymore

Fossil

Cadet
Joined
Dec 1, 2023
Messages
6
So I made a typo when I created this pool and it bothered me enough to change it. This pool had the system dataset, one virtual machine zvol and app datasets on it. I shutdown the VM, moved the system dataset to another pool and unset the dataset in apps.

Exported the pool. Imported in CLI with new name, exported again and then imported with the new name in GUI. Put the system and apps datasets back on it, all good.

Now I wanted to edit the VM and point the disks to their new zvol locations but they don't show up. I get an infinite spinner and in the dropdown it just says "Options cannot be loaded". In my browser console I get this message:

Code:
reason: "[Errno 2] No such file or directory: '/sys/block/zd0p1/ro'"


And indeed that path does not exist, only /sys/block/zd0 exists.

Code:
root@truenas[~]
root@truenas[~]# ll /sys/block/zd0
lrwxrwxrwx 1 root 0 Dec  1 21:57 /sys/block/zd0 -> ../devices/virtual/block/zd0/

# fdisk -l /dev/zd0
Disk /dev/zd0: 250 GiB, 268435456000 bytes, 524288000 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 16384 bytes
I/O size (minimum/optimal): 16384 bytes / 16384 bytes
Disklabel type: dos
Disk identifier: 0x243bf1d4

Device     Boot Start       End   Sectors  Size Id Type
/dev/zd0p1       2048 524287966 524285919  250G 83 Linux


Not sure how to fix this. I deleted the VM but when I try to create a new one I still cannot pick any existing zvols, same thing with the spinner and "Options cannot be loaded"

Any help would be appreciated :smile:
 

Fossil

Cadet
Joined
Dec 1, 2023
Messages
6
I guess I solved it but not sure how. I tried moving one of the zvols to another pool with send|recv but did not destroy the old zvol yet. Apparently that messed things up somewhere.

I verified the new zvol was OK, destroyed the old one and suddenly I could properly edit my VM disk settings again and start the VM.

I can't edit my post but someone can mark it as solved.
 
Top