vatesfr / xen-orchestra

The global orchestration solution to manage and backup XCP-ng and XenServer.
https://xen-orchestra.com
Other
775 stars 262 forks source link

Cannot determine disk size accurately from XOA #7038

Open ep1p opened 1 year ago

ep1p commented 1 year ago

If XO from the sources:

Xen Orchestra, commit [6953e] xo-server 5.122.0 xo-web 5.124.1

Describe the bug When you go to look at the disk size within a VM you get an approximation for the disk size, not the actual size. There is no field available within the interface to determine what the actual size is. 1.12TiB, for example, is a rather large rounding.

I have been doing a DR exercise and need to create the same underlying storage in a new VM but can't determine the exact size of the disks from XOA to be able to then create the same exact size for a new disk in a new VM within XOA.

~]# xe vdi-list sr-uuid=fc5218bb-ce27-503d-4900-d308027447a1 [..] uuid ( RO) : a7903871-dcd9-4a87-8aed-9ca8bf14bf88 name-label ( RW): file storage 1 name-description ( RW): sr-uuid ( RO): fc5218bb-ce27-503d-4900-d308027447a1 virtual-size ( RO): 2148446240768 sharable ( RO): false read-only ( RO): false

To Reproduce Go to disks on a VM. Look at the sizes of the disks. They are rounded. There are no exact size numbers.

Expected behavior It should be possible to find out how big your disks are exactly, and then to be able to create a new disk to this exact size without having to use the CLI.

Screenshots xoa-disk-sizes (names obfuscated in SR column in image)

Environment (please provide the following information):

xo-server 5.122.0 xo-web 5.124.1 xcp-ng 8.2.1

Additional context You also cannot create a disk in a TiB size. XOA will show your disks as TiB in size as you can see above. When you go to create or edit the storage size the maximum you can do is GiB. (Whilst this wouldn't help me here as creating a 1.12TiB disk will come out at an exact size rather than the rounded size that you see displayed in the interface which will be larger or smaller than this - smaller being the imperative problem.

xoa-disk-pulldown-no-tib

olivierlambert commented 1 year ago

Hi,

I'm not sure to understand your use case. DR with Xen Orchestra will automatically create the right disk size on destination SR. Why do you need the exact size? If we understand well the use case, we can improve the UI (or the next one) but it's not obvious right now to me :)

ep1p commented 1 year ago

Hi, We are using Veeam as our backup solution rather than Xen Orchestra DR.

The use case is that we need to be able to create a new VM with disks that match the size of an existing VM. As Xen Orchestra can't tell us the exact size of the disks, only a rounded number of '1.12TiB', it ends up creating them a different size to what the other VM has. If they are too small (as 1.12TiB is too vague) then we can't restore the disk to it as the partition size is too small. There is then additional process of having to increase the disk size, and restart the DR process.

1.12TiB presumable means a value between 1142 and 1152 GiB. It shouldn't be too hard to have a popup that shows the actual size on the SR so we can then input this value when creating the disks to get something the same size?

olivierlambert commented 1 year ago

Okay I understand now. We will ask our UI design to see how to integrate that into our new XO 6 UI. For XO 5, adding this info is not a priority (since we limit addition in the "legacy" UI as possible), but external contributions are welcome :)

Adding the issue in the XO 6 milestone as a reminder if we can find a way to display the size in bytes or another unit to get the exact size.