cloudstack-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CLOUDSTACK-9691) unhandeled excetion in list snapshot command when a primary store is deleted
Date Wed, 22 Feb 2017 16:32:44 GMT

    [ https://issues.apache.org/jira/browse/CLOUDSTACK-9691?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15878645#comment-15878645
] 

ASF GitHub Bot commented on CLOUDSTACK-9691:
--------------------------------------------

Github user nvazquez commented on the issue:

    https://github.com/apache/cloudstack/pull/1847
  
    @borisstoyanov @rhtyd I was checking BlueOrangutan logs:
    
    In `test_primary_storage_8NPG5G\runinfo.txt` lines 27-30, there's PS creation:
    ````
    2017-02-20 11:03:59,678 - DEBUG - Payload: {'apiKey': u'LIN6rqXuaJwMPfGYFh13qDwYz5VNNz1J2J6qIOWcd3oLQOq0WtD4CwRundBL6rzXToa3lQOC_vKjI3nkHtiD8Q',
'name': 'Marvin Primary Pool', 'url': 'NFS://10.2.0.16/acs/primary/pr1847-t854-kvm-centos7/marvin_pri1',
'podid': u'1c6f35e3-a31e-49cc-b0b0-801848dbb9bc', 'clusterid': u'8ac40777-344d-4f36-93a3-7b685361a523',
'zoneid': u'9c474c4e-0742-4fbb-b0ae-cb3d1e63cb70', 'command': 'createStoragePool', 'signature':
'zq6ff7P2n9iLmw3Cw9nDgMM1v90=', 'response': 'json'}
    2017-02-20 11:03:59,678 - DEBUG - ========Sending GET Cmd : createStoragePool=======
    2017-02-20 11:04:00,038 - DEBUG - Response : {podname : u'Pod1', name : u'Marvin Primary
Pool', disksizeallocated : 0, created : u'2017-02-20T11:04:00+0000', clustername : u'p1-c1',
ipaddress : u'10.2.0.16', podid : u'1c6f35e3-a31e-49cc-b0b0-801848dbb9bc', clusterid : u'8ac40777-344d-4f36-93a3-7b685361a523',
zoneid : u'9c474c4e-0742-4fbb-b0ae-cb3d1e63cb70', state : u'Up', scope : u'CLUSTER', overprovisionfactor
: u'2.0', path : u'/acs/primary/pr1847-t854-kvm-centos7/marvin_pri1', zonename : u'pr1847-t854-kvm-centos7',
type : u'NetworkFilesystem', id : u'fa44baa2-267d-3f36-88c9-c5c545e0204b', disksizetotal :
7514055770112}
    2017-02-20 11:04:00,038 - DEBUG - Created storage pool in cluster: 8ac40777-344d-4f36-93a3-7b685361a523
    ````
    
    Then, it gets removed, lines 46-48:
    ````
    2017-02-20 11:04:35,193 - DEBUG - Payload: {'apiKey': u'LIN6rqXuaJwMPfGYFh13qDwYz5VNNz1J2J6qIOWcd3oLQOq0WtD4CwRundBL6rzXToa3lQOC_vKjI3nkHtiD8Q',
'response': 'json', 'command': 'deleteStoragePool', 'signature': '73NDgRVRZDU4uHR/Vc8pRbVg2p4=',
'id': u'fa44baa2-267d-3f36-88c9-c5c545e0204b'}
    2017-02-20 11:04:35,193 - DEBUG - ========Sending GET Cmd : deleteStoragePool=======
    2017-02-20 11:04:35,396 - DEBUG - Response : {success : u'true'}
    ````
    
    Then, on `test_volumes_950C4W\runinfo.txt` lines 474-476 `listStoragePools` command is
sent and lists previously deleted PS:
    ````
    2017-02-20 13:54:49,407 - DEBUG - Payload: {'apiKey': u'LIN6rqXuaJwMPfGYFh13qDwYz5VNNz1J2J6qIOWcd3oLQOq0WtD4CwRundBL6rzXToa3lQOC_vKjI3nkHtiD8Q',
'command': 'listStoragePools', 'signature': 'l3xL+RNaPCVAYEpCovbu1snTIRI=', 'response': 'json'}
    2017-02-20 13:54:49,407 - DEBUG - ========Sending GET Cmd : listStoragePools=======
    2017-02-20 13:54:49,432 - DEBUG - Response : [{podname : u'Pod1', storagecapabilities
: {VOLUME_SNAPSHOT_QUIESCEVM : u'false'}, name : u'Marvin Primary Pool', disksizeallocated
: 8590328832, podid : u'1c6f35e3-a31e-49cc-b0b0-801848dbb9bc', clustername : u'p1-c1', ipaddress
: u'10.2.0.16', created : u'2017-02-20T12:51:45+0000', clusterid : u'8ac40777-344d-4f36-93a3-7b685361a523',
zoneid : u'9c474c4e-0742-4fbb-b0ae-cb3d1e63cb70', state : u'Up', disksizeused : 174845853696,
id : u'fa44baa2-267d-3f36-88c9-c5c545e0204b', overprovisionfactor : u'2.0', path : u'/acs/primary/pr1847-t854-kvm-centos7/marvin_pri1',
zonename : u'pr1847-t854-kvm-centos7', type : u'NetworkFilesystem', scope : u'CLUSTER', disksizetotal
: 7514055770112}, {podname : u'Pod1', storagecapabilities : {VOLUME_SNAPSHOT_QUIESCEVM : u'false'},
name : u'pr1847-t854-kvm-centos7-kvm-pri2', disksizeallocated : 977060864, podid : u'1c6f35e3-a31e-49cc-b0b0-801848dbb9bc',
clustername : u'p1-c1', ipaddress : u'10.2.0.16', created : u'2017-02-20T08:52:51+0000', clusterid
: u'8ac40777-344d-4f36-93a3-7b685361a523', zoneid : u'9c474c4e-0742-4fbb-b0ae-cb3d1e63cb70',
state : u'Up', disksizeused : 174845853696, id : u'7a360219-f4a9-3edb-a1e3-241cbc2dee7f',
overprovisionfactor : u'2.0', path : u'/acs/primary/pr1847-t854-kvm-centos7/pr1847-t854-kvm-centos7-kvm-pri2',
zonename : u'pr1847-t854-kvm-centos7', type : u'NetworkFilesystem', scope : u'CLUSTER', disksizetotal
: 7514055770112}, {podname : u'Pod1', storagecapabilities : {VOLUME_SNAPSHOT_QUIESCEVM : u'false'},
name : u'pr1847-t854-kvm-centos7-kvm-pri1', disksizeallocated : 3221422592, podid : u'1c6f35e3-a31e-49cc-b0b0-801848dbb9bc',
clustername : u'p1-c1', ipaddress : u'10.2.0.16', created : u'2017-02-20T08:52:50+0000', clusterid
: u'8ac40777-344d-4f36-93a3-7b685361a523', zoneid : u'9c474c4e-0742-4fbb-b0ae-cb3d1e63cb70',
state : u'Up', disksizeused : 174845853696, id : u'4435931f-bb5a-3ce6-a2f5-6f7345d5eb0a',
overprovisionfactor : u'2.0', path : u'/acs/primary/pr1847-t854-kvm-centos7/pr1847-t854-kvm-centos7-kvm-pri1',
zonename : u'pr1847-t854-kvm-centos7', type : u'NetworkFilesystem', scope : u'CLUSTER', disksizetotal
: 7514055770112}]
    ````
    
    Please note that although there's almost 3-hour difference between logs, there exists
a PS with the same id ("fa44baa2-267d-3f36-88c9-c5c545e0204b"), but creation times are different:
    `created: u'2017-02-20T11:04:00+0000'` vs `created : u'2017-02-20T12:51:45+0000'`
    
    So, when `test_snapshots.py` gets executed, it tries creating PS and fails due to there
is already a PS with the same url. I agree with @serg38 on adding a new entry on `test_data.py`
which would solve the problem, but I think it would require modifying `test_data.py` each
time we want to create a PS using nfs. What do you guys think, that you know how BlueOrangutan
works, that would be the best approach?



> unhandeled excetion in list snapshot command when a primary store is deleted
> ----------------------------------------------------------------------------
>
>                 Key: CLOUDSTACK-9691
>                 URL: https://issues.apache.org/jira/browse/CLOUDSTACK-9691
>             Project: CloudStack
>          Issue Type: Bug
>      Security Level: Public(Anyone can view this level - this is the default.) 
>            Reporter: Anshul Gangwar
>            Assignee: Anshul Gangwar
>
> Repro steps:
> I have a setup with 3 clusters . for one cluster i deleted the primary storage
> now when i traverse to storage tab getting exception "Unable to locate datastore with
id 1"
> DB entries for deleted primary storage :
> "id"	"name"	"uuid"	"pool_type"	"port"	"data_center_id"	"pod_id"	"cluster_id" "used_bytes"
"capacity_bytes"	"host_address"	"user_info"	"path"	"created" "removed"	"update_time"	"status"
"storage_provider_name"	"scope"	"hypervisor" "managed"	"capacity_iops"
> "1"	"dddd"	\N	"NetworkFilesystem"	"2049"	"1"	"1"	"1"	"4674624913408" "5902284816384"
"10.147.28.7"	\N	"/export/home/shweta/471.xen.primary"	"2016-08-17 08:14:12"	"2016-08-25 04:54:53"
\N	"Maintenance"	"DefaultPrimary" "CLUSTER"	\N	"0"	\N
> MS log shows :
> 2016-08-26 14:34:36,709 DEBUG [c.c.a.ApiServlet] (catalina-exec-1:ctx-90c9ba3a) (logid:115e39ad)
===START=== 10.233.88.59 – GET command=listSnapshots&response=json&listAll=true&page=1&pagesize=20&_=1472202277072
> 2016-08-26 14:34:36,747 ERROR [c.c.a.ApiServer] (catalina-exec-1:ctx-90c9ba3a ctx-94284178)
(logid:115e39ad) unhandled exception executing api command: [Ljava.lang.String;@77f27ce8
> com.cloud.utils.exception.CloudRuntimeException: Unable to locate datastore with id 1
> at org.apache.cloudstack.storage.datastore.manager.PrimaryDataStoreProviderManagerImpl.getPrimaryDataStore(PrimaryDataStoreProviderManagerImpl.java:61)
> at org.apache.cloudstack.storage.datastore.DataStoreManagerImpl.getDataStore(DataStoreManagerImpl.java:48)
> at com.cloud.api.ApiResponseHelper.getDataStoreRole(ApiResponseHelper.java:571)
> at com.cloud.api.ApiResponseHelper.createSnapshotResponse(ApiResponseHelper.java:537)
> at org.apache.cloudstack.api.command.user.snapshot.ListSnapshotsCmd.execute(ListSnapshotsCmd.java:117)
> at com.cloud.api.ApiDispatcher.dispatch(ApiDispatcher.java:132)
> at com.cloud.api.ApiServer.queueCommand(ApiServer.java:707)
> at com.cloud.api.ApiServer.handleRequest(ApiServer.java:538)
> at com.cloud.api.ApiServlet.processRequestInContext(ApiServlet.java:297)
> at com.cloud.api.ApiServlet$1.run(ApiServlet.java:129)
> at org.apache.cloudstack.managed.context.impl.DefaultManagedContext$1.call(DefaultManagedContext.java:56)
> at org.apache.cloudstack.managed.context.impl.DefaultManagedContext.callWithContext(DefaultManagedContext.java:103)
> at org.apache.cloudstack.managed.context.impl.DefaultManagedContext.runWithContext(DefaultManagedContext.java:53)
> at com.cloud.api.ApiServlet.processRequest(ApiServlet.java:126)
> at com.cloud.api.ApiServlet.doGet(ApiServlet.java:86)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
> at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
> at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
> at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
> at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
> at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
> at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:555)
> at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
> at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)
> at org.apache.coyote.http11.Http11NioProcessor.process(Http11NioProcessor.java:889)
> at org.apache.coyote.http11.Http11NioProtocol$Http11ConnectionHandler.process(Http11NioProtocol.java:721)
> at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:2268)
> at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
> at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
> at java.lang.Thread.run(Thread.java:745)
> 2016-08-26 14:34:36,749 DEBUG [c.c.a.ApiServlet] (catalina-exec-1:ctx-90c9ba3a ctx-94284178)
(logid:115e39ad) ===END=== 10.233.88.59 – GET command=listSnapshots&response=json&listAll=true&page=1&pagesize=20&_=1472202277072
> 2016-08-26 14:34:38,478 DEBUG [c.c.a.m.AgentManagerImpl] (AgentManager-Handler-8:null)
(logid SeqA 3-49869: Processing Seq 3-49869: { Cmd , MgmtId: -1, via: 3, Ver: v1, Flags: 11,
[{"com.cloud.agent.api.ConsoleProxyLoadReportCommand":{"_proxyVmId":2,"_loadInfo":"
> {\n \"connections\": []\n}
> ","wait":0}}] }



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Mime
View raw message