顯示具有 Monitor 標籤的文章。 顯示所有文章
顯示具有 Monitor 標籤的文章。 顯示所有文章

2012年9月28日 星期五

如何在HP SIM上監控VM ESXi

這個問題搞了好久(其實大半時間都沒有理它),看了HP SIM的文件以及論壇,才發現,SIM 若想要監控ESXi,必須要有HPWBEM(因為ServerHP),它是靠WBEMEvent送給SIM,而不是SNMP

原始的ESXi並沒有包含HP WBEM,唯一的方式就是安裝” HP Custom Image for ESXi”的版本,這個版本的ESXiHP特製的,裡面除了VM ESXi的主程式,還包括HPDriver以及WBEM等監控必備的Agent
(PS.其他廠牌Server也有對應的ESXi版本,例如IBMDELL…等。)

了解SIM的運作後,以下介紹安裝及設定:
1.下載ESXi For HP專用版本(我以ESXi 5.0為例,其他版本,請自行搜尋):

2.安裝HP Custom Image for ESXiHP Server上。

3.安裝完畢後,接下來要回到HP SIM做設定。

4.SIM必須要能連到ESXi上,探查ESXi的狀況,因此必須將admin的帳號、密碼給SIM。到OptionsàSecurityàCredentialsàGlobal Credentials設定探查的帳密。




5.設定完成之後,接下來做Discovery,探查上述安裝完成的ESXi。探查完畢後,應該可以在SIM上找到那台ESXi

6.點選該台ESXi,可以發現SIM已經抓到基本資料。點選”Properties”,你可以看到更詳細的資料。




到剛剛的步驟為止,SIM已經能正確的抓到ESXi的狀況了。但是我在測試的過程中,竟然發現它不會發Alarm,那我還監控它做什麼?

之後,花了一個多小時努力去問股溝大神,終於在一小篇論壇找到解答。以下繼續步驟:

7.先對這台ESXi,按照標準設定完成Event

8.OptionsàEventsàEvent Filter Settings,勾選”Accept unregistered events”



9.接下來到OptionsàEventsàSubscribe to WBEM Events,將剛剛設定完成的Event加入Subscribe。到此完成所有設定。接下來就可以測試,Alarm是否發揮作用了!!



2012年2月14日 星期二

如何在Windows上安裝OpenNMS

這是一篇如何在Windows上安裝OpenNMS的文章,原文內容在以下網址:



1. Install the JDK
Download the Java 6 (1.6), Java 5 (1.5) or higher Java SE JDK from?java.sun.com?and install it. The JDK, not just a JRE, is required by the web UI, since JSP pages are dynamically compiled. You need the version labeled "Java SE" (for "standard edition"), not EE, ME, or FX.

2. Install JICMP
For OpenNMS 1.3.6 or greater Install?JICMP.
For 64-bit installations: Note that the OpenNMS installer includes 32-bit JICMP. Download 64-bit JICMP fromSourceForge. Between Step 8 and Step 9 of the OpenNMS installation wizard below, copy the 64-bit jicmp.dll and msvc runtime dll to OpenNMS\lib, overwriting the 32-bit files.

3. Install PostgreSQL
a.)Download the Installer
Download the one-click PostgreSQL for Windows installer.
http://www.postgresql.org/download/windows

b.)Run the PostgreSQL Installer
Run the installer. For the most part, the defaults should be just fine. You should not need to run the Stack Builder for OpenNMS, although if you intend to use PostgreSQL for other things, it lets you install replication, web, and ODBC tools.
Note: the PostgreSQL Windows installer has a bug, it does not enable the PL/PGSQL language by default, even if you check the box which tells it to. See the instructions below for adding it.

c.)Initialize the Database
Create a Database in PostgreSQL_Root\data
If for some reason you don't have a default database initialized from the installer, you can create it yourself:
* open a command prompt (Start -> Run -> cmd) and change to the bin directory of your PostgreSQL install (by default,?C:\Program Files\PostgreSQL\X.X\bin)
* Initialize the database with the following command:
* initdb -E UTF-8 -U postgres ..\data

d.)Adding PL/PGSQL to the postgres database
Add PL/PGSQL Language
When you initialize the database manually, it does not add PL/PGSQL automatically, so you will need to do so yourself. The easiest way to do this is with the pgAdmin tool which is provided with the PostgreSQL binaries.
1. start PostgreSQL: from the Start bar, go to the "PostgreSQL X.X" menu and run "Start service"
2. run pgAdmin: from the Start bar, go to the "PostgreSQL X.X" menu and run "pgAdmin III"
3. connect to the database: double-click on "PostgreSQL Database Server X.X (localhost:5432)"
4. browse to the postgres database (Databases -> postgres)
5. go to File --> Options and activate the Languages option under the Display tab (click "OK")
6. click the "Refresh" button to be sure everything is being displayed
7. Navigate back to the "postgres" database, you should now see a "Languages" item in the tree
8. Right-click on "Languages" and select "New Language..."
9. Select "plpgsql" from the "Name" drop-down, and click "OK" (accepting the defaults)
10. exit pgAdmin

4. Install OpenNMS
If you did not start PostgreSQL already, start it by going to the "PostgreSQL X.X" menu in the Start bar, and click "Start service".
Then, all you need to do is download the latest?standalone-'opennms-installer-X.X.X.zip'?from the?opennmssection on?the OpenNMS download page. Once it is downloaded to your hard drive, you should be able to just double-click setup32.exe or setup64.exe it in Explorer, and it will start installation. Note that the setupXX.exe you run should match your JVM's arch, so if you're running a 32-bit JVM on 64-bit Windows, install using setup32.exe.
Follow the instructions?and you should have a complete OpenNMS installation!

5. Run OpenNMS
OpenNMS can be run from the command-line, using opennms. bat in your?$OPENNMS_HOME\bin?directory. Assuming you installed OpenNMS to?C:\Program Files\OpenNMS, you would open a command-prompt, and cd to?C:\Program Files\OpenNMS\bin. Then run:
 opennms.bat start
...and OpenNMS should start. Open your browser and point it at?http://localhost:8980/opennms?and log in as "admin" with the password "admin".

2012年1月31日 星期二

如何使用HP SIM監控HP P4000 G2

這篇文章找了好久才找到,如果想將HP P4000 G2加到HP SIM加以監控,不妨參考一下!!



1. Install HP SIM Version 6.0 or 6.1.
2. Install the HP SAN/iQ Version 8.5 Centralized Management Console (CMC) from
SANiQ_Management_Console_8.5.00.0313_20100302.iso .
Note: The Complete option must be selected in order to install the MIB files.
3. After installing the HP SAN/iQ8.5 software with the SNMP Support option, go to the C:\Program Files\LeftHand Networks\UI\mibs directory to continue the installation.
Compile and Load the MIB definitions into HP SIM:
1. Ensure that HP SIM is installed in the C:\Program Files\HP\Systems Insight Manager directory.
2. Copy the following twelve files into the HP SIM MIB C:\Program Files\HP\Systems Insight Manager\mibs directory:
  • All eleven of the LEFTHAND-NETWORK * MIB files.
  • HCNUM-TC.MIB .
3. Modify the LEFTHAND-NETWORKS-NSM-NOTIFICATION-MIB.mib by replacing lhnNsmEvents with lhnNsmDevices .
Note: Strings similar to { lhnNsmEvents 2 } will be located at the bottom each notification.
4. When replacing lhnNsmEvents with lhnNsmDevices, ensure that the numbers are not modified and that there is a space between lhnNsmDevices and the number. For example, make changes similar to the following:
  • Change ::= { lhnNsmEvents 2 } to ::= { lhnNsmDevices 2 }
  • Change ::= { lhnNsmEvents 21 } to ::= { lhnNsmDevices 21 }
5. Append lhn to all occurrences of hostname , cluster , and site .For example, make changes similar to the following:
  • Change Site OBJECT-TYPE to lhnSite OBJECT-TYPE
  • Change Cluster to lhnCluster
6. Save the changes to LEFTHAND-NETWORKS-NSM- NOTIFICATION-MIB.mib file.
7. Create a batch file named C:\Program Files\HP\Systems Insight Manager\loadMibs.bat . This file should contain the following commands:
mxmib -a SNMPv2-SMI.cfg .
mxmib -a SNMPv2-TC.cfg
mcompile HCNUM-TC.MIB .
mxmib -a HCNUM-TC.cfg
mcompile LEFTHAND-NETWORKS-GLOBAL-REG-MIB.mib .
mxmib -a LEFTHAND-NETWORKS-GLOBAL-REG-MIB.cfg .
mcompile LEFTHAND-NETWORKS-NSM-MIB.mib .
mxmib -a LEFTHAND-NETWORKS-NSM-MIB.cfg .
mcompile LEFTHAND-NETWORKS-NSM-CLUSTERING-MIB.mib .
mxmib -a LEFTHAND-NETWORKS-NSM-CLUSTERING-MIB.cfg .
mcompile LEFTHAND-NETWORKS-NSM-DNS-MIB.mib .
mxmib -a LEFTHAND-NETWORKS-NSM-DNS-MIB.cfg .
mcompile LEFTHAND-NETWORKS-NSM-INFO-MIB.mib .
mxmib -a LEFTHAND-NETWORKS-NSM-INFO-MIB.cfg
mcompile LEFTHAND-NETWORKS-NSM-NETWORK-MIB.mib
mxmib -a LEFTHAND-NETWORKS-NSM-NETWORK-MIB.cfg
mcompile LEFTHAND-NETWORKS-NSM-NOTIFICATION-MIB.mib
mxmib -a LEFTHAND-NETWORKS-NSM-NOTIFICATION-MIB.cfg
mcompile LEFTHAND-NETWORKS-NSM-NTP-MIB.mib
mxmib -a LEFTHAND-NETWORKS-NSM-NTP-MIB.cfg
mcompile LEFTHAND-NETWORKS-NSM-SECURITY-MIB.mib
mxmib -a LEFTHAND-NETWORKS-NSM-SECURITY-MIB.cfg
mcompile LEFTHAND-NETWORKS-NSM-STATUS-MIB.mib
mxmib -a LEFTHAND-NETWORKS-NSM-STATUS-MIB.cfg
mcompile LEFTHAND-NETWORKS-NSM-STORAGE-MIB.mib
mxmib -a LEFTHAND-NETWORKS-NSM-STORAGE-MIB.cfg
Note: This batch file uses SNMPv2-SMI.cfg and SNMPv2-TC.cfg files from the C:\Program Files\HP\Systems Insight Manager\mibs directory. Do not copy these files from the C:\Program Files\LeftHand Networks\UI\mibs directory.
8. Change directory to C:\Program Files\HP\Systems Insight Manager\mibs and run C:\Program Files\HP\Systems Insight Manager\loadMibs.bat .
To verify that the MIBs are loaded, use the following command:
mxmib -l
Note: The mxmib - command should list the 11 LEFTHAND-NETWORKS MIBs files listed above and the HCNUM-TC MIB file.
9. Discover and configure the P4000 device to send SNMP Traps to the HP SIM server using the proper SNMP Community String via the SANIQ 8.5 CMC console by performing the following:
a. In CMC Getting Started , provide the IP Address , Name , or Subnet to discover the VSA device.
b. Expand the Available Nodes or P4000 Management Group to show the P4000 devices that should be configure.
c. Expand the system that should be configured.
d. Select SNMP from the tree.
e. On the right side of the screen, go to to the SNMP Trap tab sheet.
f. Use the SNMP Trap Tasks drop-down list box and select Edit SNMP Trap Settings from the list.
g. Add the correct SNMP community string.
h. Click Add Button.
i. Add the trap destination Hostname or IP Address of the HP SIM server.
j. Select v1 for the trap version.
k. Click the OK repeatedly to navigate to the SNMP Trap tab page.
Note: It is recommended to reboot the VSA server after the settings are made. 
Figure 1: HP LeftHand Networks Centralized Management Console screen
Procedure for removing the MIBs
1. Create the batch file C:\Program Files\HP\Systems Insight Manager\UNloadMibs.bat and include the following commands:
mxmib -d HCNUM-TC.MIB
del .\mibs\HCNUM-TC.MIB
mxmib -d LEFTHAND-NETWORKS-GLOBAL-REG-MIB.mib
del .\mibs\LEFTHAND-NETWORKS-GLOBAL-REG-MIB.cfg
mxmib -d LEFTHAND-NETWORKS-NSM-CLUSTERING-MIB.mib
del .\mibs\LEFTHAND-NETWORKS-NSM-CLUSTERING-MIB.cfg
mxmib -d LEFTHAND-NETWORKS-NSM-DNS-MIB.mib
del .\mibs\LEFTHAND-NETWORKS-NSM-DNS-MIB.cfg
mxmib -d LEFTHAND-NETWORKS-NSM-INFO-MIB.mib
del .\mibs\LEFTHAND-NETWORKS-NSM-INFO-MIB.cfg
mxmib -d LEFTHAND-NETWORKS-NSM-MIB.mib
del .\mibs\LEFTHAND-NETWORKS-NSM-MIB.cfg
mxmib -d LEFTHAND-NETWORKS-NSM-NETWORK-MIB.mib
del .\mibs\LEFTHAND-NETWORKS-NSM-NETWORK-MIB.cfg
mxmib -d LEFTHAND-NETWORKS-NSM-NOTIFICATION-MIB.mib
del .\mibs\LEFTHAND-NETWORKS-NSM-NOTIFICATION-MIB.cfg
mxmib -d LEFTHAND-NETWORKS-NSM-NTP-MIB.mib
del .\mibs\LEFTHAND-NETWORKS-NSM-NTP-MIB.cfg
mxmib -d LEFTHAND-NETWORKS-NSM-SECURITY-MIB.mib
del .\mibs\LEFTHAND-NETWORKS-NSM-SECURITY-MIB.cfg
mxmib -d LEFTHAND-NETWORKS-NSM-STATUS-MIB.mib
del .\mibs\LEFTHAND-NETWORKS-NSM-STATUS-MIB.cfg
mxmib -d LEFTHAND-NETWORKS-NSM-STORAGE-MIB.mib
del .\mibs\LEFTHAND-NETWORKS-NSM-STORAGE-MIB.cfg
2. Change directory to C:\Program Files\HP\Systems Insight Manager\mibs and run C:\Program Files\HP\Systems Insight Manager\mibs\UNloadMibs. bat.

2011年6月30日 星期四

解決"(SNMP) Rising Threshold Passed (10005): HP SIM Critical Even"錯誤訊息

這一兩天一直收到HP System Insight Manager(SIM)所發出來的錯誤訊息:
"(SNMP) Rising Threshold Passed (10005): HP SIM Critical Even"

查看Server又查不出個鳥蛋出來,上網查詢後,終於在HP的官方網站,如何解決這個錯誤訊息。主要是之前設定Disk閥值所引起的。

解決方式,參考HP網站:


主要做第二項即可。


2010年10月6日 星期三

PRTG設定操作

PRTG跟MRTG同樣都是監控流量軟體,只不過一個要要錢,一個免錢。

免錢的MRTG不是很好嗎?是阿,光是安裝就得研究老半天,設定上更是傳承Linux的指令模式, Windows版也是如此。

要錢的PRTG,它已經幫你把一堆繁瑣事項,全部搞定,安裝時只要下一步下一步。在設定時,簡單易懂的介面,讓你很快就上手。有錢賺的軟體,服務果然不一樣。

小弟是簡單派的,對於Linux這種複雜的東西,採取且戰且走政策,非不得已,儘量少碰。因為若要投靠Linux,又得花許多時間研究,不符合個人效益,所以只好繼續被微軟綁死。

PRTG是靠SNMP來抓流量,因此你要監控的設備,例如Router/Switch…一定要先開啟SNMP服務。

1.下載測試版PRTG(只支援10個Sensors),下載後直接安裝。
http://www.paessler.com/download/prtg

2.執行PRTG

3.PRTG安裝時會順便安裝Web Server的功能,因此安裝完畢後,先測試Web Server是否正常。PRTG預設使用8080 port,打開瀏覽器後,輸入這台電腦的IP位址,再加8080即可http://ip位址:8080


4.測試完畢後,先了解PRTG的版面配置。

n 左邊是面版稱為SensorsSensors的功用是探測你想要知道的設備的流量,因此我們會建立很多Sensors

n 左邊是Panel,主要作為顯示用途。你可以建立多個Panel,因此可以用Panel來歸類要顯示的Sensors資訊。




5.範例:假設某台Server怪怪的,懷疑中鏢後在散佈大量封包,因此想監控這台電腦使用的流量。這台電腦是接到10.3.12.3 Switch的第12 Port


6.首先按左上角
”Add Sensors,出現一個歡迎視窗,按下一步。


7.選擇”Standard SNMP Traffic Sensor,按Next


8.給予一個可識別的名稱,並輸入設備的IP位址及Community String,按Next


9.勾選Server所接的第12 Port.


10.接下來設定Group name.

Group 作為Sensors的分類,若是下拉式選單沒有你要的,直接輸入名稱,便可新增一個Group name。在此案例中,我以”Server Group”做為Group name


11.下一步Panel設定:

Panel Selection”,選擇”Create one new panel with all graphs”新增一個Panel

“Charts per Graph Selection”則是要呈現的監控時間週期。

。按FinishSensors設定完成。


12.因為新增的Panel名稱,不易識別。按右鍵,選擇Edit Panel




13.更改名稱後,按OK


14.檢查Panel名稱已更改完成.



15.回到Web上看,你就可以看到剛剛設定的Panel。點進去後,流量已經開始在跑囉~~~




16.最後不要忘記存檔,避免辛苦設定的東東,就這樣殘念。

2010年9月25日 星期六

免費Cisco網管軟體 --- Cisco Network Assistant

Cisco提供一套免費的網管軟體Cisco Network Assistant(簡稱CNA),專門用來管理自家的設備(Switch /Router/ AP/ Firewall/ IP Phone….),除了提供便利的管理操作介面,個人認為它最大的功能在於繪出拓樸圖,設備資產管理,以及設備狀況告知。

1.首先到Cisco網站。
http://tools.cisco.com/support/downloads/pub/Redirect.x?mdfid=279230132

2.找到這套軟體(需事先註冊一個帳號才能下載)。

3.下載後,按照一般步驟安裝即可。

4.安裝完後,開啟CNA,會看到以下畫面。第一次先選擇”Create Community”。


5.接下來輸入可識別的Name及Company Name。

6.“Discover device”會自動掃描設備,它可以掃單一設備、Subnet、或者是一個IP網段。在此案例中,我們以IP網段作為掃描範圍。
。輸入”Start IP”及”End IP”後,按”Start”按鈕,便會開始掃描。
。之後,會出現掃描到的設備清單。
。按”OK”鈕,繼續下一個步驟。



7.接下來,它會要設備的帳號、密碼(如果你有設定),輸入後繼續按OK。



8.等一會之後,CNA就會繪出網路拓樸圖。



9.如果想知道這條線怎麼連的,在線上按右鍵,選擇”Properties”,就會出現”Link Properties”,清楚的標示對連狀況。





10.如果想知道設備資產,選擇上方Inventory。之後一張資產清單就出來了,以後就不用再費心紀錄啦。




11.Even Notification可以告知你現在設備有哪些狀況。

結語,CNA是一套強大的且易用的Cisco設備管理軟體,上述只是介紹常用的功能,更多功能則需要你慢慢品嚐。

2009年9月27日 星期日

HostMonitor[1] -- 安裝

HostMonitor是一套優異的監控程式,在Windows的運作環境中,因為它是去抓取Windows內建的監控值,因此針對Windows平台,幾乎是無所不監。

我會分很多篇文章,來介紹這套軟體,畢竟監控這個議題,可大可小。後續介紹常用的功能,若沒提到的,請自行試玩。

1.下載HostMonitor 8測試版。
http://ftp.isu.edu.tw/pub/Windows/softking/soft/en/a/host-mon.exe

2.執行該程式,選擇”Installation”,按Next 。

3.選擇安裝版本,按"?"會告訴你各版本差異。選擇預設的"Enterprice"版本,按Next。

4.按Install 。

5.安裝完畢後,出現以下畫面。按Done。
6.接下來,會執行該程式。
7.右下角常駐工具列,會出現紅色閃電Icon,代表程式運作中。
8.出現HostMonitor管理畫面。