create_cloned_volume of HPE 3PAR Cinder Driver has a performance bottleneck when source/target volume size are different

Bug #1645136 reported by William Durairaj
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Cinder
Fix Released
Undecided
Unassigned

Bug Description

CREATED CLONED VOLUME WITH 1TB VOLUME CREATED AS A SOURCE
----------------------------------------------------------
1d [stack@csimbe11b15:~]⥠$ cinder create --name iscsi-CloneVol-1.5TB --source-volid 893e2e96-44ec-45ce-98af-0c0691b951fc 1536

when the source volume has an image and it's of lesser size than the target volume to be copied, 3PAR physical copy takes too much time to complete (~ 1 hr).

Analysis:

Flow of events:

This condition is false in if volume['size'] == src_vref['size'] https://review.openstack.org/#/c/401285/6/cinder/volume/drivers/hpe/hpe_3par_common.py Line 2019

2016-11-25 13:02:35.373 29407 DEBUG cinder.volume.drivers.hpe.hpe_3par_iscsi [req-e168d6c1-95a1-45df-9537-c6be6a453bab 4a63240c374c4830b091012932680b7d 6733f00e1e5f489ab04bb83881c65954 - - -] ==> create_cloned_volume: call {'volume': Volume(_name_id=None,admin_metadata={},attach_status='detached',availability_zone='nova',bootable=False,consistencygroup=<?>,consistencygroup_id=None,created_at=2016-11-25T13:02:32Z,deleted=False,deleted_at=None,display_description=None,display_name='ec1b602a-porrato',ec2_id=None,encryption_key_id=None,glance_metadata=<?>,host='ha-volume-manager@3par_iSCSI#helion',id=ab5328ca-d983-4b11-b7d3-ecad26ab53ac,launched_at=None,metadata={},migration_status=None,multiattach=False,previous_status=None,project_id=63f32e6a1b6e4c72a3ed4f7b3a13c4e2,provider_auth=None,provider_geometry=None,provider_id=None,provider_location=None,replication_driver_data=None,replication_extended_status=None,replication_status='disabled',scheduled_at=2016-11-25T13:02:33Z,size=1024,snapshot_id=None,snapshots=<?>,source_volid=None,status='creating',terminated_at=None,updated_at=2016-11-25T13:02:33Z,user_id=3fdba5ecca9c40baaea502490ade1d85,volume_attachment=<?>,volume_type=VolumeType(16948cc5-8ce6-485f-ae99-f3895a22494b),volume_type_id=16948cc5-8ce6-485f-ae99-f3895a22494b), 'src_vref': Volume(_name_id=None,admin_metadata={readonly='True'},attach_status='detached',availability_zone='nova',bootable=False,consistencygroup=<?>,consistencygroup_id=None,created_at=2016-11-24T20:51:51Z,deleted=False,deleted_at=None,display_description=None,display_name='image-a9b0c5fc-8237-4b60-9b08-09cf57a2f3fb',ec2_id=None,encryption_key_id=None,glance_metadata=<?>,host='ha-volume-manager@3par_iSCSI#helion',id=77fd160d-d3e2-4111-b84c-4a2717ae7c0f,launched_at=2016-11-24T20:52:23Z,metadata={},migration_status=None,multiattach=False,previous_status=None,project_id=6733f00e1e5f489ab04bb83881c65954,provider_auth=None,provider_geometry=None,provider_id=None,provider_location=None,replication_driver_data=None,replication_extended_status=None,replication_status='disabled',scheduled_at=2016-11-24T20:51:53Z,size=1,snapshot_id=None,snapshots=<?>,source_volid=c90a70e6-efb5-4d5e-b042-19cd65aab5ef,status='available',terminated_at=None,updated_at=2016-11-24T20:52:23Z,user_id=3fdba5ecca9c40baaea502490ade1d85,volume_attachment=<?>,volume_type=VolumeType(16948cc5-8ce6-485f-ae99-f3895a22494b),volume_type_id=16948cc5-8ce6-485f-ae99-f3895a22494b), 'self': <cinder.volume.drivers.hpe.hpe_3par_iscsi.HPE3PARISCSIDriver object at 0x7f5559dc2710>} trace_logging_wrapper /opt/stack/venv/cinder-20161014T013009Z/lib/python2.7/site-packages/cinder/utils.py:901

So, it does’nt look like a regression in the fix done by review request 401285 , since the original IF condition was this statement (before fix).

_http_log_resp /opt/stack/venv/cinder-20161014T013009Z/lib/python2.7/site-packages/hpe3parclient/http.py:180
2016-11-25 13:02:35.950 29407 DEBUG hpe3parclient.http [req-e168d6c1-95a1-45df-9537-c6be6a453bab 4a63240c374c4830b091012932680b7d 6733f00e1e5f489ab04bb83881c65954 - - -] RESP BODY:{"key":"6-fb315e0
09243eacc237738254419d2a3-6b363858"}
_http_log_resp /opt/stack/venv/cinder-20161014T013009Z/lib/python2.7/site-packages/hpe3parclient/http.py:181
2016-11-25 13:02:35.957 29407 DEBUG cinder.volume.drivers.hpe.hpe_3par_common [req-e168d6c1-95a1-45df-9537-c6be6a453bab 4a63240c374c4830b091012932680b7d 6733f00e1e5f489ab04bb83881c65954 - - -] Creating a clone of volume,using non-online copy. create_cloned_volume /opt/stack/venv/cinder-20161014T013009Z/lib/python2.7/site-packages/cinder/volume/drivers/hpe/hpe_3par_common.py:2046
2016-11-25 13:02:35.958 29407 DEBUG cinder.volume.drivers.hpe.hpe_3par_common [req-e168d6c1-95a1-45df-9537-c6be6a453bab 4a63240c374c4830b091012932680b7d 6733f00e1e5f489ab04bb83881c65954 - - -] CREA
TE VOLUME (ec1b602a-porrato: volume-ab5328ca-d983-4b11-b7d3-ecad26ab53ac osv-q1MoytmDSxG30.ytJqtTrA on ha-volume-manager@3par_iSCSI#helion) create_volume /opt/stack/venv/cinder-20161014T013009Z/lib
/python2.7/site-packages/cinder/volume/drivers/hpe/hpe_3par_common.py:1816
2016-11-25 13:02:36.067 29407 DEBUG hpe3parclient.http [req-e168d6c1-95a1-45df-9537-c6be6a453bab 4a63240c374c4830b091012932680b7d 6733f00e1e5f489ab04bb83881c65954 - - -]
REQ: curl -i https://172.30.0.239:8080/api/v1/volumes -X POST -H "X-Hp3Par-Wsapi-Sessionkey: 6-fb315e009243eacc237738254419d2a3-6b363858" -H "Content-Type: application/json" -H "Accept: application
/json" -H "User-Agent: python-3parclient"
_http_log_req /opt/stack/venv/cinder-20161014T013009Z/lib/python2.7/site-packages/hpe3parclient/http.py:169
2016-11-25 13:02:36.068 29407 DEBUG hpe3parclient.http [req-e168d6c1-95a1-45df-9537-c6be6a453bab 4a63240c374c4830b091012932680b7d 6733f00e1e5f489ab04bb83881c65954 - - -] REQ BODY: {"comment": "{\"v
olume_type_name\": \"3PAR\", \"display_name\": \"ec1b602a-porrato\", \"name\": \"volume-ab5328ca-d983-4b11-b7d3-ecad26ab53ac\", \"volume_type_id\": \"16948cc5-8ce6-485f-ae99-f3895a22494b\", \"volum
e_id\": \"ab5328ca-d983-4b11-b7d3-ecad26ab53ac\", \"qos\": {}, \"type\": \"OpenStack\"}", "sizeMiB": 1048576, "tpvv": true, "name": "osv-q1MoytmDSxG30.ytJqtTrA", "tdvv": false, "snapCPG": "helion",
"cpg": "helion"}
_http_log_req /opt/sta

_http_log_resp /opt/stack/venv/cinder-20161014T013009Z/lib/python2.7/site-packages/hpe3parclient/http.py:181
2016-11-25 13:02:36.353 29407 DEBUG hpe3parclient.http [req-e168d6c1-95a1-45df-9537-c6be6a453bab 4a63240c374c4830b091012932680b7d 6733f00e1e5f489ab04bb83881c65954 - - -]
REQ: curl -i https://172.30.0.239:8080/api/v1/volumes/osv-d-0WDdPiQRG4TEonF658Dw -X POST -H "X-Hp3Par-Wsapi-Sessionkey: 6-fb315e009243eacc237738254419d2a3-6b363858" -H "Content-Type: application/json" -H "Accept: application/json" -H "User-Agent: python-3parclient"
_http_log_req /opt/stack/venv/cinder-20161014T013009Z/lib/python2.7/site-packages/hpe3parclient/http.py:169
2016-11-25 13:02:36.355 29407 DEBUG hpe3parclient.http [req-e168d6c1-95a1-45df-9537-c6be6a453bab 4a63240c374c4830b091012932680b7d 6733f00e1e5f489ab04bb83881c65954 - - -] REQ BODY: {"action": "createPhysicalCopy", "parameters": {"destVolume": "osv-q1MoytmDSxG30.ytJqtTrA", "priority": 1}}

2016-11-25 13:02:36.489 29407 DEBUG requests.packages.urllib3.connectionpool [req-e168d6c1-95a1-45df-9537-c6be6a453bab 4a63240c374c4830b091012932680b7d 6733f00e1e5f489ab04bb83881c65954 - - -] "POST /api/v1/volumes/osv-d-0WDdPiQRG4TEonF658Dw HTTP/1.1" 201 None _make_request /opt/stack/venv/cinder-20161014T013009Z/lib/python2.7/site-packages/requests/packages/urllib3/connectionpool.py:387
2016-11-25 13:02:36.493 29407 DEBUG hpe3parclient.http [req-e168d6c1-95a1-45df-9537-c6be6a453bab 4a63240c374c4830b091012932680b7d 6733f00e1e5f489ab04bb83881c65954 - - -] RESP:{'status': '201'
'Server': 'hp3par-wsapi'
'Connection': 'close'
'Location': '/api/v1/volumes/osv-q1MoytmDSxG30.ytJqtTrA'
'Pragma': 'no-cache'
'Cache-Control': 'no-cache'
'Date': 'Fri, 25 Nov 2016 13:02:36 GMT'
'Content-Type': 'application/json'}
_http_log_resp /opt/stack/venv/cinder-20161014T013009Z/lib/python2.7/site-packages/hpe3parclient/http.py:180
2016-11-25 13:02:36.493 29407 DEBUG hpe3parclient.http [req-e168d6c1-95a1-45df-9537-c6be6a453bab 4a63240c374c4830b091012932680b7d 6733f00e1e5f489ab04bb83881c65954 - - -] RESP BODY:{"taskid":25784}

_http_log_resp /opt/stack/venv/cinder-20161014T013009Z/lib/python2.7/site-packages/hpe3parclient/http.py:181
2016-11-25 13:02:36.494 29407 DEBUG hpe3parclient.http [-]
REQ: curl -i https://172.30.0.239:8080/api/v1/tasks/25784 -

2016-11-25 13:58:49.445 29407 DEBUG requests.packages.urllib3.connectionpool [-] "GET /api/v1/tasks/25784 HTTP/1.1" 200 None _make_request /opt/stack/venv/cinder-20161014T013009Z/lib/python2.7/site-packages/requests/packages/urllib3/connectionpool.py:387
2016-11-25 13:58:49.449 29407 DEBUG hpe3parclient.http [-] RESP:{'status': '200'
'content-location': u'https://172.30.0.239:8080/api/v1/tasks/25784'
'Server': 'hp3par-wsapi'
'Connection': 'close'
'Pragma': 'no-cache'
'Cache-Control': 'no-cache'
'Date': 'Fri, 25 Nov 2016 13:58:49 GMT'
'Content-Type': 'application/json'}
_http_log_resp /opt/stack/venv/cinder-20161014T013009Z/lib/python2.7/site-packages/hpe3parclient/http.py:180
2016-11-25 13:58:49.449 29407 DEBUG hpe3parclient.http [-] RESP BODY:{"id":25784,"type":1,"name":"osv-d-0WDdPiQRG4TEonF658Dw->osv-q1MoytmDSxG30.ytJqtTrA","status":1,"startTime":"2016-11-25 13:02:36 GMT","finishTime":"2016-11-25 13:58:48 GMT","priority":1,"user":"helion"}

_http_log_resp /opt/stack/venv/cinder-20161014T013009Z/lib/python2.7/site-pack

Tags: 3par drivers
Changed in cinder:
assignee: nobody → William Durairaj (william-dur-sandanaraj)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to cinder (master)

Fix proposed to branch: master
Review: https://review.openstack.org/403452

Changed in cinder:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to cinder (stable/mitaka)

Fix proposed to branch: stable/mitaka
Review: https://review.openstack.org/403627

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on cinder (stable/mitaka)

Change abandoned by William Durairaj (<email address hidden>) on branch: stable/mitaka
Review: https://review.openstack.org/403627
Reason: Will cherry pick this change from master after the change is merged.

Eric Harney (eharney)
tags: added: 3par drivers
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to cinder (master)

Fix proposed to branch: master
Review: https://review.openstack.org/403882

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on cinder (master)

Change abandoned by William Durairaj (<email address hidden>) on branch: master
Review: https://review.openstack.org/403452
Reason: I have to make my change dependant on review request https://review.openstack.org/#/c/401285/. Hence abadoning and creating review request on https://review.openstack.org/#/c/403882/

Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Change abandoned by William Durairaj (<email address hidden>) on branch: master
Review: https://review.openstack.org/403882
Reason: 3PAR 3.2.2-MU3 P52 patch resolves this.

Revision history for this message
Sean McGinnis (sean-mcginnis) wrote : Bug Assignee Expired

Unassigning due to no activity for > 6 months.

Changed in cinder:
assignee: William Durairaj (william-dur-sandanaraj) → nobody
status: In Progress → New
Revision history for this message
Jay Bryant (jsbryant) wrote :

It looks like this can be closed out based on comment #6.

Changed in cinder:
status: New → Fix Released
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.