progetti:cloud-areapd:operations:save_and_remove_cinder_volume_stuck
Differences
This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
| progetti:cloud-areapd:operations:save_and_remove_cinder_volume_stuck [2015/08/18 09:15] – created straldi@infn.it | progetti:cloud-areapd:operations:save_and_remove_cinder_volume_stuck [2015/08/18 09:18] (current) – straldi@infn.it | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| + | ====== Save and Remove Cinder Volume Stuck ====== | ||
| + | * Find using openstack command the volume stuck and the file associated to it: | ||
| + | <code bash> | ||
| + | cinder list --all-tenants | ||
| + | </ | ||
| + | |||
| + | * Determine from the project or the user the volume. We suppose the file is: | ||
| + | <code bash> | ||
| + | / | ||
| + | </ | ||
| + | |||
| + | * Mount the file in a specific path: | ||
| + | <code bash> | ||
| + | mount -t ext4 -o loop, | ||
| + | </ | ||
| + | |||
| + | * Create a tar with the contents of the directory just mounted: | ||
| + | <code bash> | ||
| + | cd / | ||
| + | tar -czvf / | ||
| + | </ | ||
| + | |||
| + | * Copy the file in a secure zone where the user have access, for example in a nfs export. | ||
| + | <code bash> | ||
| + | scp fileBuild20150715.tgz root@cld-storage-01:/ | ||
| + | </ | ||
| + | |||
| + | * Send a mail to the user and the cloud-support where the file has been copiated. | ||
| + | |||
| + | * To erase the volume from cld-ctrl-01 enter in mysql and execute this query: | ||
| + | <code bash> | ||
| + | mysql> select * from cinder_prod.snapshots where volume_id = | ||
| + | ' | ||
| + | +---------------------+------------+------------+---------+--------------------------------------+--------------------------------------+----------------------------------+----------------------------------+----------+----------+-------------+--------------+--------------+---------------------+-------------------+-------------------+----------------+ | ||
| + | | created_at | ||
| + | id | | ||
| + | volume_id | ||
| + | | project_id | status | ||
| + | display_name | display_description | provider_location | | ||
| + | encryption_key_id | volume_type_id | | ||
| + | +---------------------+------------+------------+---------+--------------------------------------+--------------------------------------+----------------------------------+----------------------------------+----------+----------+-------------+--------------+--------------+---------------------+-------------------+-------------------+----------------+ | ||
| + | | 2015-07-14 06:30:40 | NULL | NULL | ||
| + | 38dc71ee-7ebc-4b20-806a-f2c0bd7581d1 | | ||
| + | 2a367882-9bd7-4ee1-a99e-fa491bcaf0af | 7210e789b5454b5486783271059628aa | ||
| + | | e9ddc1e36c1348fa812c56f1922371b5 | creating | 0% | ||
| + | NULL | NULL | NULL | NULL | | ||
| + | NULL | NULL | | ||
| + | +---------------------+------------+------------+---------+--------------------------------------+--------------------------------------+----------------------------------+----------------------------------+----------+----------+-------------+--------------+--------------+---------------------+-------------------+-------------------+----------------+ | ||
| + | 1 row in set (0.00 sec) | ||
| + | |||
| + | mysql> delete from cinder_prod.snapshots where volume_id = | ||
| + | ' | ||
| + | Query OK, 1 row affected (0.01 sec) | ||
| + | </ | ||
