Re: [pve-devel] [PATCH manager] storage GUI: fix unintuitive sorting order

2022-02-21 Thread Fabian Ebner
Am 18.02.22 um 11:42 schrieb Matthias Heiserer: > The backups in the 'Backups' table in Storages are now initially > sorted by column 'Name' ascending. > > Previously, they were first sorted by 'vmid' descending, then by date > descending. This was unintuitive as 'vmid' doesn't exist as column > i

Re: [pve-devel] [PATCH manager] storage GUI: fix unintuitive sorting order

2022-02-21 Thread Thomas Lamprecht
On 21.02.22 09:32, Fabian Ebner wrote: > Am 18.02.22 um 11:42 schrieb Matthias Heiserer: >> The backups in the 'Backups' table in Storages are now initially >> sorted by column 'Name' ascending. >> >> Previously, they were first sorted by 'vmid' descending, then by date >> descending. This was unin

[pve-devel] [PATCH pve-zsync 2/2] parse cron: handle additional whitespace

2022-02-21 Thread Fabian Ebner
Can only happen by manually editing AFAICT, but cron does execute the jobs, so just be a bit less restrictive when parsing. Reported in the community forum: https://forum.proxmox.com/threads/105254/ Signed-off-by: Fabian Ebner --- pve-zsync | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-

[pve-devel] [PATCH pve-zsync 1/2] rename encode_cron to parse_cron

2022-02-21 Thread Fabian Ebner
The old name is confusing, because "encode" is usually not used when converting from text to a data structure. Signed-off-by: Fabian Ebner --- pve-zsync | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pve-zsync b/pve-zsync index b466076..7246336 100755 --- a/pve-zsync +++

[pve-devel] [PATCH v3 qemu-server 1/1] fix #3424: api: snapshot delete: wait for active replication

2022-02-21 Thread Fabian Ebner
A to-be-deleted snapshot might be actively used by replication, resulting in a not (or only partially) removed snapshot and locked (snapshot-delete) VM. Simply wait a few seconds for any ongoing replication. Signed-off-by: Fabian Ebner --- Dependency bump for guest-common needed. New in v3. P

[pve-devel] [PATCH-SERIES guest-common/container/qemu-server] fix #3424: wait for active replication when deleting a snapshot

2022-02-21 Thread Fabian Ebner
Avoid that an attempt to remove a snapshot that's actively used by replication leads to a partially (or not) removed snapshot and locked guest. I decided to make the checks at the call sides, because passing the log function and timeout to snapshot_delete felt awkward as they would only be used fo

[pve-devel] [PATCH v3 container 1/2] partially fix #3424: vzdump: cleanup: wait for active replication

2022-02-21 Thread Fabian Ebner
As replication and backup can happen at the same time, the vzdump snapshot might be actively used by replication when backup tries to cleanup, resulting in a not (or only partially) removed snapshot and locked (snapshot-delete) container. Wait up to 10 minutes for any ongoing replication. If repli

[pve-devel] [PATCH v3 guest-common 1/1] guest helpers: add run_with_replication_guard

2022-02-21 Thread Fabian Ebner
Signed-off-by: Fabian Ebner --- New in v3. src/PVE/GuestHelpers.pm | 15 ++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/src/PVE/GuestHelpers.pm b/src/PVE/GuestHelpers.pm index 970c460..1183819 100644 --- a/src/PVE/GuestHelpers.pm +++ b/src/PVE/GuestHelpers.pm @@ -

[pve-devel] [PATCH v3 container 2/2] fix #3424: api: snapshot delete: wait for active replication

2022-02-21 Thread Fabian Ebner
A to-be-deleted snapshot might be actively used by replication, resulting in a not (or only partially) removed snapshot and locked (snapshot-delete) container. Simply wait a few seconds for any ongoing replication. Signed-off-by: Fabian Ebner --- New in v3. src/PVE/API2/LXC/Snapshot.pm | 12 ++

[pve-devel] applied: [PATCH pve-zsync 1/2] rename encode_cron to parse_cron

2022-02-21 Thread Thomas Lamprecht
On 21.02.22 10:07, Fabian Ebner wrote: > The old name is confusing, because "encode" is usually not used when > converting from text to a data structure. > > Signed-off-by: Fabian Ebner > --- > pve-zsync | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > applied, thanks! ___

Re: [pve-devel] [PATCH pve-zsync 2/2] parse cron: handle additional whitespace

2022-02-21 Thread Thomas Lamprecht
On 21.02.22 10:07, Fabian Ebner wrote: > Can only happen by manually editing AFAICT, but cron does execute the > jobs, so just be a bit less restrictive when parsing. I mean, it won't get more broken as already but can we avoid white-space splitting on command arguments in general? We could use

[pve-devel] applied: [PATCH v3 storage 1/2] fix #3894: cast 'size' and 'used' to integer

2022-02-21 Thread Thomas Lamprecht
On 18.02.22 09:58, Mira Limbeck wrote: > Perl's automatic conversion can lead to integers being converted to > strings, for example by matching it in a regex. > > To make sure we always return an integer in the API call, add an > explicit cast to integer. > > Signed-off-by: Mira Limbeck > Review

[pve-devel] applied: [PATCH storage v3 2/2] file_size_info: cast 'size' and 'used' to integer

2022-02-21 Thread Thomas Lamprecht
On 18.02.22 09:58, Mira Limbeck wrote: > `qemu-img info --output=json` returns the size and used values as integers in > the JSON format, but the regex match converts them to strings. > As we know they only contain digits, we can simply cast them back to integers > after the regex. > > The API req

Re: [pve-devel] [PATCH librados2-perl 1/6] mon_command: free outs buffer

2022-02-21 Thread Thomas Lamprecht
On 18.02.22 12:38, Aaron Lauterer wrote: > Signed-off-by: Aaron Lauterer > --- > > thanks @Dominik who realized that we did not free this buffer in all > situations. > note that the status string is normally only allocated in the error case, where we freed it already, so actual impact shouldn't

Re: [pve-devel] [PATCH librados2-perl 2/6] mon_command: optionally ignore errors and return hashmap

2022-02-21 Thread Thomas Lamprecht
On 18.02.22 12:38, Aaron Lauterer wrote: > In some situations, we do not want to abort if the Ceph API returns an > error (ret != 0). We also want to be able to access all the retured > values from the Ceph API (return code, status, data). > > One such situation can be the 'osd ok-to-stop' call w

Re: [pve-devel] [PATCH v2 manager 1/3] ui: lxc/qemu: add disk reassign

2022-02-21 Thread Dominik Csapak
sorry for the late review some comments inline On 11/15/21 16:02, Aaron Lauterer wrote: For the new HDReassign component, we follow the approach of HDMove to have one componend for qemu and lxc as they are the same for most parts. The 'Move disk/volume' button is now a SplitButton which has th