准备条件
opennms-1 (192.168.1.22) opennms-2 (192.168.1.23)
ip1.txt ip2.txt
requisition-1 requisition-2
OpenNMS 安装 安装
Postgresql 安装
httpd 安装
--------------------------------------------------------------
Newts 192.168.1.21
1 启用一个httpd
添加两个设备IP地址集合文件
vi /var/www/html/ip1.txt,内容如下,opennms-1管理的设备
123.127.197.66
202.106.57.226
vi /var/www/html/ip2.txt,内容如下,opennms-2管理的设备
202.106.42.46
2 配置 Provisioning Requisitions
Configure OpenNMS -> Manage Provisioning Requisitions
Add Requisition -> 添加 requisition-1 (opennms-1)
requisition-2 (opennms-2)
3 配置设备发现
Configure OpenNMS -> Configure Discovery
Foreign Source: 选择requisition-1
Include URLs: 添加
4 数据采集配置
vi etc/opennms.properties
修改
# findByServiceType query
# org.opennms.dao.ipinterface.findByServiceType=select distinct ipIf from OnmsIpInterface as ipIf join ipIf.monitoredServices as monSvc where monSvc.serviceType.name = ?
改为
org.opennms.dao.ipinterface.findByServiceType=select distinct ipInterface from OnmsIpInterface as ipInterface join ipInterface.monitoredServices as monSvc where monSvc.serviceType.name = ? and ipInterface.node.foreignSource = 'requisition-1'
5 配置服务轮询
vi etc/poller-configuration.xml,修改package的name为example1的
IPADDR != '0.0.0.0'
修改为
IPADDR != '0.0.0.0' & foreignSource = 'requisition-1'
注意:& 的转义字符为 &
6 其它问题
opennms-2开启Vacuumd
OpenNMS分布式部署视频
视频地址:
视频下载:
阅读(1242) | 评论(0) | 转发(0) |