Chinaunix首页 | 论坛 | 博客
  • 博客访问: 10327402
  • 博文数量: 1669
  • 博客积分: 16831
  • 博客等级: 上将
  • 技术积分: 12594
  • 用 户 组: 普通用户
  • 注册时间: 2011-02-25 07:23
个人简介

柔中带刚,刚中带柔,淫荡中富含柔和,刚猛中荡漾风骚,无坚不摧,无孔不入!

文章分类

全部博文(1669)

文章存档

2023年(4)

2022年(1)

2021年(10)

2020年(24)

2019年(4)

2018年(19)

2017年(66)

2016年(60)

2015年(49)

2014年(201)

2013年(221)

2012年(638)

2011年(372)

分类: 云计算

2014-06-04 18:55:07

错误log
2014-06-04 11:36:48,736 ERROR [c.c.a.ApiServer] (catalina-exec-11:ctx-1dab6790 ctx-2669ee12) unhandled exception executing api command: deleteStoragePool
com.cloud.utils.exception.CloudRuntimeException: Cannot delete pool primary_01 as there are associated non-destroyed vols for this pool
        at com.cloud.storage.StorageManagerImpl.deletePool(StorageManagerImpl.java:810)
        at org.apache.cloudstack.api.command.admin.storage.DeletePoolCmd.execute(DeletePoolCmd.java:78)
        at com.cloud.api.ApiDispatcher.dispatch(ApiDispatcher.java:161)
        at com.cloud.api.ApiServer.queueCommand(ApiServer.java:531)
        at com.cloud.api.ApiServer.handleRequest(ApiServer.java:374)
        at com.cloud.api.ApiServlet.processRequestInContext(ApiServlet.java:323)
        at com.cloud.api.ApiServlet.access$000(ApiServlet.java:53)
        at com.cloud.api.ApiServlet$1.run(ApiServlet.java:115)
        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:112)        at com.cloud.api.ApiServlet.doGet(ApiServlet.java:74)
        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:2274)        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
        at java.lang.Thread.run(Thread.java:744)2014-06-04 11:36:48,737 DEBUG [c.c.a.ApiServlet] (catalina-exec-11:ctx-1dab6790 ctx-2669ee12) ===END===  192.168.2.55 -- GET  command=deleteStoragePool&id=83099458-d54f-395e-9706-747a176dd7a8&forced=true&response=json&sessionkey=%2F4j05h4yZ36iyBLpkoK42ng1Avo%3D&_=1401853008314

nfs正常,所有vm都能正常使用。

界面无法看到主存储



登入mysql,发现storage_pool只有一条数据,理论上应该有管理节点+计算节点的合计记录数。

mysql>use cloud;
mysql> select * from storage_pool;
+----+------------+--------------------------------------+-------------------+------+----------------+--------+------------+--------------+----------------+---------------+-----------+----------------------------+---------------------+---------+-------------+--------+-----------------------+-------+------------+---------+---------------+
| 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 | primary_01 | 83099458-d54f-395e-9706-747a176dd7a8 | NetworkFilesystem | 2049 |              1 |   NULL |       NULL | 183614570496 |   194487255040 | 192.168.2.212 | NULL      | /mnt/testnfs/nfs1/testnfs1 | 2014-06-03 09:59:12 | NULL    | NULL        | Up     | DefaultPrimary        | ZONE  | KVM        |       0 |          NULL |
+----+------------+--------------------------------------+-------------------+------+----------------+--------+------------+--------------+----------------+---------------+-----------+----------------------------+---------------------+---------+-------------+--------+-----------------------+-------+------------+---------+---------------+
1 row in set (0.00 sec)

估计是那个地方发猫疯了(真没找到原因,估计是哪个地方卡死了,没法更新。)
可参考下这个的解决办法,
但我按他的方法打标记后,主存储是找到了,但所有系统出问题,连主机都找不到了。

幸好先做了备份,最终还是还原mysql的时候意外解决(所以论备份的重要性啊~~~~~~~)。
Linux下MySQL的备份与还原 
备份 
[root@localhost ~]# cd /var/lib/mysql (进入到MySQL库目录,根据自己的MySQL的安装情况调整目录) 
[root@localhost mysql]# mysqldump -u root -p cloud>cloud.sql,输入密码即可。

还原
[root@localhost ~]# cd /var/lib/mysql (进入到MySQL库目录,根据自己的MySQL的安装情况调整目录) 
[root@localhost mysql]# mysql -u root -p cloud
重启,
service cloudstack-management restart

正常。


mysql> use cloud;
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A


Database changed
mysql> select * from storage_pool;
+----+------------------------+--------------------------------------+-------------------+------+----------------+--------+------------+--------------+----------------+---------------+-----------+----------------------------+---------------------+---------+-------------+--------+-----------------------+-------+------------+---------+---------------+
| 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 | primary_01             | 83099458-d54f-395e-9706-747a176dd7a8 | NetworkFilesystem | 2049 |              1 |   NULL |       NULL | 170284154880 |   194487255040 | 192.168.2.212 | NULL      | /mnt/testnfs/nfs1/testnfs1 | 2014-06-03 09:59:12 | NULL    | NULL        | Up     | DefaultPrimary        | ZONE  | KVM        |       0 |          NULL |
|  2 | CentOS03 Local Storage | 5a67a154-795d-4cdb-8b51-ccbb7a6041b9 | Filesystem        |    0 |              1 |      1 |          1 |   2367553536 |   507642617856 | 192.168.2.204 | NULL      | /var/lib/libvirt/images    | 2014-06-04 10:40:30 | NULL    | NULL        | Up     | DefaultPrimary        | HOST  | NULL       |       0 |          NULL |
|  3 | CentOS02 Local Storage | df3a6aae-b970-4806-8532-be1c847a4a9c | Filesystem        |    0 |              1 |      1 |          1 |   2770903040 |   507600674816 | 192.168.2.203 | NULL      | /var/lib/libvirt/images    | 2014-06-04 10:40:30 | NULL    | NULL        | Up     | DefaultPrimary        | HOST  | NULL       |       0 |          NULL |
|  4 | CentOS01 Local Storage | 74c29a2f-cc3d-4acf-a99a-f5f594cf339f | Filesystem        |    0 |              1 |      1 |          1 |   2368122880 |   507642617856 | 192.168.2.202 | NULL      | /var/lib/libvirt/images    | 2014-06-04 10:40:30 | NULL    | NULL        | Up     | DefaultPrimary        | HOST  | NULL       |       0 |          NULL |
+----+------------------------+--------------------------------------+-------------------+------+----------------+--------+------------+--------------+----------------+---------------+-----------+----------------------------+---------------------+---------+-------------+--------+-----------------------+-------+------------+---------+---------------+
4 rows in set (0.00 sec)



阅读(901) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~