cloudstack-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sangeetha Hariharan (JIRA)" <j...@apache.org>
Subject [jira] [Created] (CLOUDSTACK-3315) Not able to list storage pool , after a failed attempt to add a primary storage to a cluster that has no hosts.
Date Tue, 02 Jul 2013 01:04:19 GMT
Sangeetha Hariharan created CLOUDSTACK-3315:
-----------------------------------------------

             Summary: Not able to list storage pool , after a failed attempt to add a primary
storage to a cluster that has no hosts.
                 Key: CLOUDSTACK-3315
                 URL: https://issues.apache.org/jira/browse/CLOUDSTACK-3315
             Project: CloudStack
          Issue Type: Bug
      Security Level: Public (Anyone can view this level - this is the default.)
          Components: Management Server
    Affects Versions: 4.2.0
         Environment: Build from master-6-17-stable
            Reporter: Sangeetha Hariharan
             Fix For: 4.2.0


Not able to list storage pool , after a failed attempt to add a primary storage to a cluster
that has no hosts.

Steps to reproduce the problem:

Add a cluster.
Add a primary storage to this cluster (when there are no hosts associated with it).
This fails with the following error message:
"Failed to add data store"

Following exception seen in management server log:

2013-07-01 17:50:33,149 DEBUG [cloud.api.ApiServlet] (catalina-exec-23:null) ===         
                                   START===  10.217.252.50 -- GET  command=createStoragePool&scope=cluster&zoneid=e
                                            c791392-4906-49bc-8a02-f37c672a1f64&podid=647a0c65-167c-4419-b0bc-f6c74fab5893&c
                                            lusterid=03e3e8d7-2485-485a-94c6-a98c6df44429&name=test&url=nfs%3A%2F%2F10.223.1
                                            10.232%2Fexport%2Fhome%2Fsangeetha%2Fipv6%2Fprimary123&response=json&sessionkey=
                                            i1TQqK7wA5tzS1JevWXydR2bGiI%3D&_=1372726568381
2013-07-01 17:50:33,162 DEBUG [datastore.lifecycle.CloudStackPrimaryDataStoreLif         
                                   eCycleImpl] (catalina-exec-23:null) createPool Params @
scheme - nfs storageHost                                              - 10.223.110.232 hostPath
- /export/home/sangeetha/ipv6/primary123 port - -1
2013-07-01 17:50:33,172 DEBUG [cloud.storage.StorageManagerImpl] (catalina-exec-         
                                   23:null) Failed to add data store
com.cloud.utils.exception.CloudRuntimeException: No host up to associate a stora         
                                   ge pool with in cluster 2
        at org.apache.cloudstack.storage.datastore.lifecycle.CloudStackPrimaryDa         
                                   taStoreLifeCycleImpl.attachCluster(CloudStackPrimaryDataStoreLifeCycleImpl.java:
                                            398)
        at com.cloud.storage.StorageManagerImpl.createPool(StorageManagerImpl.ja         
                                   va:854)
        at com.cloud.storage.StorageManagerImpl.createPool(StorageManagerImpl.ja         
                                   va:190)
        at org.apache.cloudstack.api.command.admin.storage.CreateStoragePoolCmd.         
                                   execute(CreateStoragePoolCmd.java:144)
        at com.cloud.api.ApiDispatcher.dispatch(ApiDispatcher.java:155)
        at com.cloud.api.ApiServer.queueCommand(ApiServer.java:528)
        at com.cloud.api.ApiServer.handleRequest(ApiServer.java:371)
        at com.cloud.api.ApiServlet.processRequest(ApiServlet.java:304)
        at com.cloud.api.ApiServlet.doGet(ApiServlet.java:66)
        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(Appl         
                                   icationFilterChain.java:290)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF         
                                   ilterChain.java:206)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV         
                                   alve.java:233)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextV         
                                   alve.java:191)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j         
                                   ava:127)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.j         
                                   ava:102)
        at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:         
                                   555)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineVal         
                                   ve.java:109)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.jav         
                                   a:298)
        at org.apache.coyote.http11.Http11NioProcessor.process(Http11NioProcesso         
                                   r.java:889)
        at org.apache.coyote.http11.Http11NioProtocol$Http11ConnectionHandler.pr         
                                   ocess(Http11NioProtocol.java:721)
        at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoin         
                                   t.java:2268)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.         
                                   java:1110)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor         
                                   .java:603)
        at java.lang.Thread.run(Thread.java:679)
2013-07-01 17:50:33,172 ERROR [cloud.api.ApiServer] (catalina-exec-23:null) unha         
                                   ndled exception executing api command: createStoragePool
com.cloud.utils.exception.CloudRuntimeException: Failed to add data store
        at com.cloud.storage.StorageManagerImpl.createPool(StorageManagerImpl.ja         
                                   va:861)
        at com.cloud.storage.StorageManagerImpl.createPool(StorageManagerImpl.ja         
                                   va:190)
        at org.apache.cloudstack.api.command.admin.storage.CreateStoragePoolCmd.         
                                   execute(CreateStoragePoolCmd.java:144)
        at com.cloud.api.ApiDispatcher.dispatch(ApiDispatcher.java:155)
        at com.cloud.api.ApiServer.queueCommand(ApiServer.java:528)
        at com.cloud.api.ApiServer.handleRequest(ApiServer.java:371)
        at com.cloud.api.ApiServlet.processRequest(ApiServlet.java:304)
        at com.cloud.api.ApiServlet.doGet(ApiServlet.java:66)
        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(Appl         
                                   icationFilterChain.java:290)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF         
                                   ilterChain.java:206)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV         
                                   alve.java:233)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextV         
                                   alve.java:191)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j         
                                   ava:127)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.j         
                                   ava:102)
        at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:         
                                   555)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineVal         
                                   ve.java:109)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.jav         
                                   a:298)
        at org.apache.coyote.http11.Http11NioProcessor.process(Http11NioProcesso         
                                   r.java:889)
        at org.apache.coyote.http11.Http11NioProtocol$Http11ConnectionHandler.pr         
                                   ocess(Http11NioProtocol.java:721)
        at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoin         
                                   t.java:2268)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.         
                                   java:1110)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor         
                                   .java:603)
        at java.lang.Thread.run(Thread.java:679)
Caused by: com.cloud.utils.exception.CloudRuntimeException: No host up to associ         
                                   ate a storage pool with in cluster 2
        at org.apache.cloudstack.storage.datastore.lifecycle.CloudStackPrimaryDa         
                                   taStoreLifeCycleImpl.attachCluster(CloudStackPrimaryDataStoreLifeCycleImpl.java:
                                            398)
        at com.cloud.storage.StorageManagerImpl.createPool(StorageManagerImpl.ja         
                                   va:854)
        ... 25 more
2013-07-01 17:50:33,180 DEBUG [cloud.api.ApiServlet] (catalina-exec-23:null) ===         
                                   END===  10.217.252.50 -- GET  command=createStoragePool&scope=cluster&zoneid=ec7
                                            91392-4906-49bc-8a02-f37c672a1f64&podid=647a0c65-167c-4419-b0bc-f6c74fab5893&clu
                                            sterid=03e3e8d7-2485-485a-94c6-a98c6df44429&name=test&url=nfs%3A%2F%2F10.223.110
                                            .232%2Fexport%2Fhome%2Fsangeetha%2Fipv6%2Fprimary123&response=json&sessionkey=i1
                                            TQqK7wA5tzS1JevWXydR2bGiI%3D&_=1372726568381
2013-07-01 17:50:33,661 DEBUG [agent.manager.AgentManagerImpl] (AgentManager-Han         
                                   dler-6:null) Ping from 4

We still see the storage pool entry in the DB in "Initialized" state with no scope set.

mysql> select * from storage_pool;
+----+------+--------------------------------------+-------------------+------+----------------+--------+------------+-----------------+----------------+----------------+-----------+----------------------------------------+---------------------+---------+-------------+-------------+-------------------------------------+---------+------------+
| id | name | uuid                                 | pool_type         | port | data_center_id
| pod_id | cluster_id | available_bytes | capacity_bytes | host_address   | user_info | path
                                  | created             | removed | update_time | status 
    | storage_provider_name               | scope   | hypervisor |
+----+------+--------------------------------------+-------------------+------+----------------+--------+------------+-----------------+----------------+----------------+-----------+----------------------------------------+---------------------+---------+-------------+-------------+-------------------------------------+---------+------------+
|  1 | ps1  | 1f53cfaf-b024-36fa-98df-cf37239206ee | NetworkFilesystem | 2049 |          
   1 |      1 |          1 |   9596864659456 | 11810778316800 | 10.223.110.232 | NULL    
 | /export/home/sangeetha/ipv6/primary    | 2013-07-01 23:33:32 | NULL    | NULL        |
Up          | ancient primary data store provider | CLUSTER | NULL       |
|  2 | test | 48838b47-273e-3862-ba8a-6bd2379c7795 | NetworkFilesystem | 2049 |          
   1 |      1 |          2 |               0 |              0 | 10.223.110.232 | NULL    
 | /export/home/sangeetha/ipv6/primary123 | 2013-07-02 00:50:33 | NULL    | NULL        |
Initialized | ancient primary data store provider | NULL    | NULL       |
+----+------+--------------------------------------+-------------------+------+----------------+--------+------------+-----------------+----------------+----------------+-----------+----------------------------------------+---------------------+---------+-------------+-------------+-------------------------------------+---------+------------+

Trying to list all the primary storages from UI , results in "ERROR" being returned.

http://10.223.195.104:8080/client/api?command=listStoragePools&response=json&sessionkey=i1TQqK7wA5tzS1JevWXydR2bGiI%3D&page=1&pageSize=20&listAll=true&_=1372726705995

{ "liststoragepoolsresponse" : {"uuidList":[],"errorcode":530,"cserrorcode":9999} }


2013-07-01 17:52:50,746 DEBUG [cloud.api.ApiServlet] (catalina-exec-9:null) ===START===  10.217.252.50
-- GET  command=listSt
oragePools&response=json&sessionkey=i1TQqK7wA5tzS1JevWXydR2bGiI%3D&page=1&pageSize=20&listAll=true&_=1372726705995
2013-07-01 17:52:50,758 ERROR [cloud.api.ApiServer] (catalina-exec-9:null) unhandled exception
executing api command: listSto
ragePools
java.lang.NullPointerException
        at com.cloud.api.query.dao.StoragePoolJoinDaoImpl.newStoragePoolResponse(StoragePoolJoinDaoImpl.java:87)
        at com.cloud.utils.component.ComponentInstantiationPostProcessor$InterceptorDispatcher.intercept(ComponentInstantiati
onPostProcessor.java:125)
        at com.cloud.api.ApiDBUtils.newStoragePoolResponse(ApiDBUtils.java:1578)
        at com.cloud.api.query.ViewResponseHelper.createStoragePoolResponse(ViewResponseHelper.java:275)
        at com.cloud.api.query.QueryManagerImpl.searchForStoragePools(QueryManagerImpl.java:1829)
        at org.apache.cloudstack.api.command.admin.storage.ListStoragePoolsCmd.execute(ListStoragePoolsCmd.java:118)
        at com.cloud.api.ApiDispatcher.dispatch(ApiDispatcher.java:155)
        at com.cloud.api.ApiServer.queueCommand(ApiServer.java:528)
        at com.cloud.api.ApiServer.handleRequest(ApiServer.java:371)
        at com.cloud.api.ApiServlet.processRequest(ApiServlet.java:304)
        at com.cloud.api.ApiServlet.doGet(ApiServlet.java:66)
        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:1110)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
        at java.lang.Thread.run(Thread.java:679)
2013-07-01 17:52:50,760 DEBUG [cloud.api.ApiServlet] (catalina-exec-9:null) ===END===  10.217.252.50
-- GET  command=listStor
agePools&response=json&sessionkey=i1TQqK7wA5tzS1JevWXydR2bGiI%3D&page=1&pageSize=20&listAll=true&_=1372726705995



--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message