Bug 1062377 - RFE: configurable volume clearing options for nova
Summary: RFE: configurable volume clearing options for nova
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat OpenStack
Classification: Red Hat
Component: openstack-nova
Version: 4.0
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: z2
: 4.0
Assignee: Pádraig Brady
QA Contact: Attila Darazs
URL:
Whiteboard:
: 1057371 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-02-06 18:22 UTC by Daniel Berrangé
Modified: 2022-07-09 06:28 UTC (History)
10 users (show)

Fixed In Version: openstack-nova-2013.2.1-5.el6ost
Doc Type: Enhancement
Doc Text:
In OpenStack Compute, new configurable methods to wipe volumes have been added. This allows more configurable tradeoffs between performance and security. The previous default of writing zeros over deleted volumes took a significant amount of time, and may not be needed. One can now set a global configuration setting to clear only part of a volume (to remove encryption keys for example), or to disable clearing completely. Additionally a new 'shred' capability is available to overwrite with random data instead of zeros.
Clone Of:
Environment:
Last Closed: 2014-03-04 19:05:40 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
OpenStack gerrit 72656 0 None None None Never
Red Hat Issue Tracker OSP-16398 0 None None None 2022-07-09 06:28:05 UTC
Red Hat Product Errata RHSA-2014:0231 0 normal SHIPPED_LIVE Moderate: openstack-nova security and bug fix update 2014-03-05 00:00:29 UTC

Description Daniel Berrangé 2014-02-06 18:22:23 UTC
Description of problem:
Currently the LVM driver in libvirt will unconditionally call 'dd' upon volume delete. 

Cinder meanwhile has a variety of config options for this

  # Method used to wipe old voumes (valid options are: none,
  # zero, shred) (string value)
  #volume_clear=zero

  # Size in MiB to wipe at start of old volumes. 0 => all
  # (integer value)
  #volume_clear_size=0

Nova needs to support these exact same options to provide 100% parity of functionality between images and volumes.

Comment 4 Pádraig Brady 2014-02-12 18:12:09 UTC
To test this, setup nova with

 [DEFAULT]
 libvirt_images_type=lvm
 libvirt_images_volume_group=as_setup_on_your_system

 [libvirt]
 # Select one of zero,none,shred
 volume_clear=zero

Then verify that when deleting images that:

1. Start and then delete an instance, then veryify that
dd if=/dev/zero ... writes to the volume being deleted.
You should have time to see the dd process writing zeros
as it's generally in the GB range (the size of the root disk).

2. Change the volume_clear setting above to 'none',
and restart nova, and a new instance and verify that
on deletion the dd process is not run

Comment 6 Xavier Queralt 2014-02-19 22:10:12 UTC
*** Bug 1057371 has been marked as a duplicate of this bug. ***

Comment 7 Attila Darazs 2014-02-20 17:21:37 UTC
When set to 'zero', the dd process was visible in the task list for several seconds, while on 'none' the lvm volume just quickly disappeared without triggering dd. Verified.

Comment 9 errata-xmlrpc 2014-03-04 19:05:40 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHSA-2014-0231.html


Note You need to log in before you can comment on or make changes to this bug.