使用LoadRunner監控MySQL的方法介紹

發表于:2009-06-03來源:作者:點擊數: 標簽:loadrunnerLoadRunnerLoadrunnerloadRunnerMYsql
在LoadRunner中沒有提供直接監控MySQL的方法,但是在實際工作中需要我們對mysql 數據庫 服務器 進行監控,我們可以利用sitescope監控然后在 lr 中顯示SiteScope監控的結果,達到間接監控mysql的目的。 備注:Mercyry SiteScope 介紹:它是一款無代理監測 解決
在LoadRunner中沒有提供直接監控MySQL的方法,但是在實際工作中需要我們對mysql數據庫服務器進行監控,我們可以利用sitescope監控然后在lr中顯示SiteScope監控的結果,達到間接監控mysql的目的。 

備注:Mercyry SiteScope 介紹:它是一款無代理監測解決方案,可確保分布式IT基礎架構——如服務器、操作系統、網絡設備、網絡服務、應用和應用組件的可用性和性能。這款主動的、基于Web界面的基礎架構監測解決方案是非常簡潔的,而且完全根據客戶度身定制,無需在您的上線系統中增加額外的代理。 
SiteScope為上線系統提供24×7的監控服務,為維護工程師及時發現問題提供幫助,確保系統架構內一切組建的正常運作。SiteScope在大量增加檢測周期的同時也降低了維護人員的工作成本 。 
SiteScope能夠監控UNIX服務器資源、windows服務器資源、weblogic應用服務器、IIS應用服務器、Oracle數據庫、SQLServer數據庫、F5、URL地址、Ping、內存、CPU、磁盤空間、服務等等系統架構內各種組建的運行狀況;監控器按照指定頻率對目標進行檢測,一旦發現異常會及時向管理員發送意外事件的報警,警報可以通過聲音提醒、email、短信等方式發送;另外,SiteScope還可以生成監測活動的匯總報告,該對象從日志文件中讀取歷史信息,接著總結、篩選信息,并生成圖表格式的報告。 

SiteScope利用Database Query monitor監控指定的數據庫,通過SiteScope監控器的SHOW STATUS 命令,獲得相應數據,命令如下: 

show status where variable_name like ’innodb_buffer_pool_pages_total’ 

為了確保監控請確認LoadRunner and SiteScope之間的端口, SiteScope和MySQL必須打開TCP 8888 和TCP 3306 . 還有SiteScope要監控必須要確保有JDBC的安裝。 

以下為監控前需要注意的地方: 

1. SiteScope to be deployed. 
2. Sufficient license points for Database Query monitor. 
3. TCP 8888 (default) opened two-way for LoadRunner to SiteScope. 
4. TCP 3306 (default) opened two-way for SiteScope to MySQL. 
5. Monitoring privileges for SiteScope to monitor MySQL. 
6. JDBC driver to be installed on SiteScope. 
7. Have knowledge of the counter you want to monitor. 
轉自SiteScope幫助: 

Monitoring mySQL Databases 
Monitoring a MySQL database requires the use of a JDBC driver. To enable SiteScope to monitor a MySQL database: 

Download the JDBC driver from http://www.mysql.com/downloads/api-jdbc.html 
Uncompress the distribution file 
Among all the other files, you should find a file with a .jar extension. 
Copy the .jar file into the <SiteScope install path>/SiteScope/java/lib/ext directory 
Stop and restart SiteScope 
Now, use your browser to add a Database Query Monitor within SiteScope. 
The Database Connection URL format for the MySQL JDBC driver is: 

jdbc:mysql://<database hostname>[:<tcp port>]/<database> 

For example to connect to the MySQL database "aBigDatabase" on a machine using the standard MySQL port number 3306 you would use: 
jdbc:mysql://206.168.191.19/aBigDatabase 

If you are using a different port to connect to the database then you should include that port number as part of the IP address. 

The specification for the MySQL JDBC driver is: org.gjt.mm.mysql.Driver 

Enter this string into the Database Driver text box under the Advanced Options section of the Add Database Query Monitor form. 


除此之外還可以利用Mysql 提供的監控接口 ,編寫dll 然后利用lr中用戶定義監控器進行監控,由于最近時間比較忙,忙過這段時間在提供demo例子

原文轉自:http://www.anti-gravitydesign.com

国产97人人超碰caoprom_尤物国产在线一区手机播放_精品国产一区二区三_色天使久久综合给合久久97