Inconsistent behaviour in openstack backup restore BACKUP_ID VOLUME_ID

Bug #2053010 reported by Arnaud Garin
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
devstack
New
Undecided
Unassigned

Bug Description

On openstack documentation page `Back up and restore volumes and snapshots` the command to restore a backup is presented as follows `openstack volume backup restore BACKUP_ID VOLUME_ID`

However in the CLI the VOLUME_ID is not specified as a mandatory parameter

`openstack volume backup restore [-h] [-f {json,shell,table,value,yaml}] [-c COLUMN] [--noindent] [--prefix PREFIX] [--max-width <integer>] [--fit-width] [--print-empty] [--force] <backup> [<volume>]`

Then when I try to restore a backup with `openstack volume backup restore <backup-id>` I get hit with an error `Either of 'name' or 'volume_id' must be specified.`. Which is still somehow logical.

However when I try to restore a backup with 2 arguments `openstack volume backup restore <backup-id> 12345` I get hit with another error `too many values to unpack (expected 2)`.

What is even funnier is that in the second case the restore still goes through !

```
+--------------------------------------+-----------+-----------+------+-------------------------------+
| ID | Name | Status | Size | Attached to |
+--------------------------------------+-----------+-----------+------+-------------------------------+
| <Other ID> | 12345 | available | 1 | |
| <ID> | | in-use | 1 | Attached to NAME on /dev/vda |
+--------------------------------------+-----------+-----------+------+-------------------------------+
```

Any opinions on that ?

I use a custom made cinder backup driver if that is any relevant.

EDIT: Additional config information

root@stackdev:/opt/stack/devstack# sudo -u stack git describe --all --long
heads/master-0-g1ba76adc

root@stackdev:/opt/stack/devstack# cat /etc/os-release
PRETTY_NAME="Ubuntu 22.04.3 LTS"
NAME="Ubuntu"
VERSION_ID="22.04"
VERSION="22.04.3 LTS (Jammy Jellyfish)"
VERSION_CODENAME=jammy
ID=ubuntu
ID_LIKE=debian
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
UBUNTU_CODENAME=jammy

Arnaud Garin (razoff)
description: updated
description: updated
description: updated
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.