今天nagios告警: 172.17.9.76有Alert,看agent的日志有如下:

(Agent-Handler-3:null) Connected to the server

Lost connection to the server. Dealing with the remai

然后参考这篇文章

https://www.server110.com/cloudstack/201404/10553.html

重启agent、libvirtd服务,异常依然。重启host,问题还是一样。

从日志中能看出,异常是management-server在连接上cloud-agent后,刷新vm状态时问题导致的。而此时,除了vRouter,所有vm的状态均为Stoped。vRouter的状态缺为Running,就此找到问题所在。不知何故,在host上使用virsh list并不能看到vRouter,而management-server却认为他是Running状态,需要刷新一下状态,导致在management-server查询不到vRouter,所以抛出异常。这应该是一个bug,需要修复。

解决方案,删除vRoute(需要先在数据库将状态置为Stopped,执行sql   “update vm_instance set state = 'Stopped' where vm_type = 'DomainRouter';”)。

################################################################################################################################

我的做法:

登录cloudstack数据库查询HOST上跑的虚机信息,针对不同的HOST机请修改查询语句的IP信息
   select c.account_name,a.instance_name,a.display_name,a.state,b.public_ip_address from vm_instance a,host b,account c where a.power_host=b.id and a.account_id=c.id and a.instance_name like "i%" and a.state not in ("Expunging","Destroyed") and b.public_ip_address="172.17.9.56";
   查询结果类似如下:
   +---------------------+---------------+--------------+---------+-------------------+
   | account_name        | instance_name | display_name | state   | public_ip_address |
   +---------------------+---------------+--------------+---------+-------------------+
   | 8871_9639_3908_8088 | i-150-568-VM  | test2014002  | Running | 172.17.9.76       |
   | 6455_1427_2201_7373 | i-162-613-VM  | yaojianedu   | Running | 172.17.9.76       |
   | 4562_9860_0757_4566 | i-275-992-VM  | cloudHost01  | Running | 172.17.9.76       |

可用如下命令进行查询应该启动的二级VR
  mysql> select c.account_name,a.instance_name,a.display_name,a.state,b.public_ip_address from vm_instance a,host b,account c where a.power_host=b.id and a.account_id=c.id and a.instance_name like "r%" and a.state not in ("Expunging","Destroyed") and b.public_ip_address="172.17.9.53";
  +---------------------+---------------+--------------+---------+-------------------+
  | account_name        | instance_name | display_name | state   | public_ip_address |
  +---------------------+---------------+--------------+---------+-------------------+
  | 5357_3036_2997_0118 | r-46-VM       | NULL         | Running | 172.17.9.53       |
  | 1095_2254_5824_2083 | r-82-VM       | NULL         | Running | 172.17.9.53       |
  | 5806_7846_8176_1902 | r-118-VM      | NULL         | Running | 172.17.9.53       |
  | admin               | r-279-VM      | NULL         | Running | 172.17.9.53       |

在cloudstack agent  启动vr,重启cloudstack management 和 agent 服务 大概等15分钟Alert 消失

cloudstack agent host Alert 告警处理的更多相关文章

  1. CloudStack全局配置參数

    參数 描写叙述 类型 默认值 account.cleanup.interval 清除用户账户所须要等待的时间(秒) 整数 86400 agent.lb.enabled If agent load ba ...

  2. zabbix3.4.7配置邮件告警详细步骤

    Zabbix服务器操作 1.  安装sendmail或postfix (邮件传送代理MTA),本教程使用sendmail软件. (标注:如果直接使用外部邮箱发送邮件可以不需要配置sendmail或po ...

  3. Nagios告警和监控主机安装介绍(三)

    Nagios邮件告警 配置sendEmail 解压缩tar –zxvf sendEmail-v1.56.tar.gz cd sendEmail-v1.56 将可执行程序复制cp sendEmail / ...

  4. cloudstack下libvirtd服务无响应问题

    在cloudstack4.5.2版本下,偶尔出现libvirtd服务无响应的情况,导致virsh命令无法使用,同时伴随cloudstack master丢失该slave主机连接的情况.最初怀疑是lib ...

  5. zabbix系列之九——添加钉钉告警

    一.添加钉钉机器人 1. 2. 复制webhook后面脚本用到:https://oapi.dingtalk.com/robot/send?access_token=36e69dd50bbcc54b7b ...

  6. CloudStack 云计算平台框架

    前言 CloudStack 和OpenStack 一样都是IaaS层 开源框架,可以管理XenServer.ESXI.KVM.OVM等主流虚拟机,相对OpenStack比较简单.稳定: 二.Cloud ...

  7. zabbix实现微信告警配置

    zabbix设置微信报警的配置过程 zabbix的报警方式有很多,在这里我们来详细说明一下如何通过微信报警 微信企业号的申请 注册的地址https://qy.weixin.qq.com/  这样企业就 ...

  8. 分布式监控系统Zabbix3.4-钉钉告警配置记录

    群机器人是钉钉群的高级扩展功能,群机器人可以将第三方服务的信息聚合到群聊中,实现自动化的信息同步.例如:通过聚合GitHub,GitLab等源码管理服务,实现源码更新同步:通过聚合Trello,JIR ...

  9. CloudStack学习-3

    此次试验主要是CloudStack结合openvswitch 背景介绍 之所以引入openswitch,是因为如果按照之前的方式,一个网桥占用一个vlan,假如一个zone有20个vlan,那么岂不是 ...

随机推荐

  1. ubuntn安装

    环境win7 64 ,在vmn中安装ubuntn,需要开启虚拟化操作步骤: 1.首先进入BIOS,我的是thinkphpE440,在开机联想界面出现的那刻按F1: 2.选择切换到security页面, ...

  2. LeetCode 536----Construct Binary Tree from String

    536. Construct Binary Tree from String You need to construct a binary tree from a string consisting ...

  3. iOS如何解析crash文件中的地址

    1.目录中存放app文件 2.打开文件 3.执行命令otool -arch arm64 -l ./QQStock  | grep -B 1 -A 10 "LC_SEGM" | gr ...

  4. Android实现不同Active页面间的跳转

    Intent intent = new Intent(); intent.setClass(ErrorPageActive.this, LoginActive.class); startActivit ...

  5. 云卡门禁苹果SDK_BLEDOOR_SDK_IOS_2016_12_15

    // // BLElib.h // BLElib // // Created by szbosk on 16/8/16. // Copyright © 2016年 szbosk. All rights ...

  6. windows 程序员电脑设置

    程序员电脑设置: 1.详细目录 a.在一个文件夹下设为详细信息 b.win7点击"组织"-->"文件夹的搜索选项"-->"查看" ...

  7. asp.net(C#)常用时间日期处理类

    using System; using System.Data; using System.Configuration; using System.Web; using System.Web.Secu ...

  8. 通过ES6实现的Ajax类

    个人学习用途而已,仅供参考. class Ajax { constructor(xhr) { xhr = window.XMLHttpRequest ? new XMLHttpRequest() : ...

  9. 转:Eclipse+webservice开发实例

    原文地址:http://blog.csdn.net/xw13106209/article/details/7049614 1.参考文献: 1.利用Java编写简单的WebService实例  http ...

  10. Linux uname命令详解

    uname常见命令参数 -a, --all print all information, in the following order, except omit -p and -i if unknow ...