backup delete fail

Bug #1907542 reported by FengJiankui
16
This bug affects 3 people
Affects Status Importance Assigned to Milestone
Cinder
Triaged
Low
FengJiankui

Bug Description

an backup attribute has_dependent_backups is False, but exception is raised when delete the backup , and the execption as follows:

Failed to delete backup with name or ID '40b9d629-bc36-4094-913b-b6c32903c19c': Invalid backup: Incremental backups exist for this backup. (HTTP 400) (Request-ID: req-31bda700-7b9a-4f60-b6b8-3811cce25632)
1 of 1 backups failed to delete.

the backup detail as follows:

+-----------------------+--------------------------------------------+
| Property | Value |
+-----------------------+--------------------------------------------+
| availability_zone | nova1 |
| container | 40/b9/40b9d629-bc36-4094-913b-b6c32903c19c |
| created_at | 2020-12-10T07:51:07.000000 |
| data_timestamp | 2020-12-10T07:51:07.000000 |
| description | None |
| fail_reason | None |
| has_dependent_backups | False |
| id | 40b9d629-bc36-4094-913b-b6c32903c19c |
| is_incremental | False |
| name | test1 |
| object_count | 22 |
| size | 1 |
| snapshot_id | None |
| status | available |
| updated_at | 2020-12-10T07:51:21.000000 |
| volume_id | 50ae12d3-1608-44cd-9a3e-40b44d715537 |
+-----------------------+--------------------------------------------+

Found there is a backup with an error status, its parent backup is above backup.

+-----------------------+--------------------------------------+
| Property | Value |
+-----------------------+--------------------------------------+
| availability_zone | nova1 |
| container | None |
| created_at | 2020-12-10T07:52:43.000000 |
| data_timestamp | 2020-12-10T07:52:43.000000 |
| description | None |
| fail_reason | global name 'dd' is not defined |
| has_dependent_backups | False |
| id | 4de46669-a29c-4b92-9ca3-9fe527103dc8 |
| is_incremental | True |
| name | test2 |
| object_count | 0 |
| size | 1 |
| snapshot_id | None |
| status | error |
| updated_at | 2020-12-10T07:52:47.000000 |
| volume_id | 50ae12d3-1608-44cd-9a3e-40b44d715537 |

after delete the child backup, parent backup can be deleted

Changed in python-cinderclient:
assignee: nobody → FengJiankui (fengjiankui)
Changed in python-cinderclient:
status: New → Triaged
tags: added: backup dependents failure
Changed in python-cinderclient:
importance: Undecided → Low
affects: python-cinderclient → cinder
Revision history for this message
Brian Rosmaita (brian-rosmaita) wrote :

This needs to be fixed in Cinder, the python-cinderclient is just acting as an interface here.

Please read through the discussion at this week's cinder meeting:
http://eavesdrop.openstack.org/meetings/cinder/2020/cinder.2020-12-16-14.00.log.html#l-154

A few key points:

1) has_dependent_backups == False on the existing backup is correct, we don't want to count a failed backup as a dependent

2) we could implement a 'cascade' option for deletion that would delete a backup AND its dependent backups. This is probably a good idea independently of this particular bug. Its impact on this bug is that it would be useful in this situation, though a user wouldn't know to use it immediately because has_dependent_backups == False.

3) we could implement it so that if a backup is requested to be deleted, and it has a dependent backup in ERROR status, then it acts like 'cascade' even without the 'cascade' option.

Think it over, and we can discuss it in #openstack-cinder or at the weekly meeting or on the mailing list.

Revision history for this message
FengJiankui (fengjiankui) wrote :

Not only backups that failed to create, but also backups that failed to delete, etc. Why can these failed backups be considered dependencies?

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.