NetApp NFS Driver: copy volume_to_image Uses Live Volume Copy Instead of Snapshots

Bug #2137259 reported by Alexander Hild
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Cinder
New
High
Unassigned

Bug Description

With the Cinder config parameter enable_force_upload=True, uploading in-use volumes as images becomes possible.

The NetApp NFS driver lacks its own copy_volume_to_image implementation and instead relies on the default implementation. [1]

The default copy_volume_to_image function copies the live volume directly during upload rather than creating a point-in-time snapshot.

This results in inconsistent data for 'in-use' volumes with active I/O, potentially leading to corrupt or incomplete images.

[1]https://github.com/openstack/cinder/blob/master/cinder/volume/drivers/remotefs.py#L558

Eric Harney (eharney)
Changed in cinder:
importance: Undecided → High
Revision history for this message
Fernando Ferraz (fernando-ferraz) wrote :

Hi Alexander, thanks for reporting your findings.

Just confirming, have you set image_upload_use_cinder_backend=True in your backend in cinder.conf?

I believe this is required for the NetApp backend to handle the request as a clone operation [1] instead of going through generic nfs code.

This doc has more details: https://docs.openstack.org/cinder/latest/admin/volume-backed-image.html#uploading-a-volume-to-image-service

[1] https://opendev.org/openstack/cinder/src/commit/00505d25879992b268402a71125ccc65b3c4088d/cinder/volume/manager.py#L1771

Revision history for this message
Alexander Hild (hildale) wrote :

Hello,

We are not using the image_upload_use_cinder_backend parameter.

This Cinder option keeps the uploaded image as a Cinder volume and registers it in Glance, instead of streaming the data directly into Glance's own storage.

In our use case, we need the full image stored separately in Glance.

To address this, I submitted the following change:
https://review.opendev.org/c/openstack/cinder/+/971969

It creates a temporary snapshot and uploads the snapshot into Glance.

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.