ORION (Oracle I/O Calibration Tool) 是校準用于 Oracle 資料庫的存儲系統 I/O 性能的獨立工具。校準結果對于了解存儲系統的性能有很大幫助,不僅可以找出影響 Oracle 資料庫性能的問題,還能測量新資料庫安裝的大小。由于 ORION 是一個獨立工具,使用者不需要建立和運作 Oracle 資料庫。
<b></b>
<b>Orion:它究竟是什麼?</b>
小型随機I/O:如果你在測試一個OLTP資料庫,那這是最佳的選擇,Orion産生已知百分比的讀和寫、給定I/O大小和給定的I/O數量的随機I/O負載。
大型連續讀:通常,DSS(決策支援系統)和資料倉庫應用程式、大量複制、資料裝載、備份和恢複這些活動歸入這類範疇。
大型随機讀:連續流同時通路磁盤,磁盤條帶(即RAID),連續流是跨多塊磁盤的,是以在磁盤級你将會看到多個随機I/O流。
混合負載:一組小型随機I/O和大型連續I/O或更大型随機I/O,讓你可以模拟固定随機讀/寫的OLTP負載和512KB備份連續流負載。
<b>Orion可以在哪裡測試</b>
SAN:隻要LUN映射到本地裝置,Orion就可以測試它。
NAS:确定在運作Orion之前初始化資料檔案。
Orion的下載下傳位址為:
http://www.oracle.com/technetwork/cn/topics/index-088165-zhs.html
(需要先登入oracle網站才行哦,或者在google搜尋 oracle orion 下載下傳 即可)
為了盡可能地模拟 Oracle 資料庫,ORION 使用和 Oracle 相同的 I/O 軟體集生成一個合成的 I/O 負載。可以将 ORION 配置為生成很多 I/O 負載,包括一個模拟 OLTP 和資料倉庫負載的 I/O 負載。
ORION 支援多種平台。将來還會增加對更多平台的支援。使用者指南提供詳細的使用文檔,包括“入門”部分和疑難解答提示。在 ORION 中調用“-help”選項可以直接擷取關于如何使用 ORION 的摘要。
注意,Oracle 不對 ORION提供支援。
優勢:
1、不需要運作load runner以及配置大量的clinet
2、不需要運作oracle資料庫,以及準備大量的測試資料
3、測試結果更具有代表性,如随機IO測試中,該軟體可以讓存儲的命中率接近為0,而更仿真出了磁盤的真實的IOPS,而load runner很難做到這些,最終的磁盤IOPS需要換算得到。
4、可以根據需要定制一定比例的寫操作(預設沒有寫操作),但是需要注意,如果磁盤上有資料,需要小心資料被覆寫掉。
缺點
1、到現在為止,無法指定自定義的總體的運作時間以及加壓的幅度,這裡完全是自動的.
2、無法進行一些自定義的操作類型,如表的掃描操作,裝載測試等等,不過可以與oracle資料庫結合起來達到這個效果.
C:\Program Files(x86)\Oracle\Orion>orion -help
ORION: ORacle IO Numbers -- Version10.2.0.1.0
ORION runs IO performance tests that modelOracle RDBMS IO workloads.
It measures the performance of small(2-32K) IOs and large (128K+) IOs at various load levels. Each Orion data point is done at a specific mixof small and large IO loads sustained for a duration. Anywhere from a single data point to atwo-dimensional array of data points can be tested by setting the rightoptions.
An Orion test consists of data points atvarious small and large IO load levels. These points can be represented as a two-dimensional matrix: Each columnin the matrix represents a fixed small IO load. Each row represents a fixedlarge IO load. The first row is with no largeIO load and the first column is with no small IO load. An Orion test can be a single point, a row, acolumn or the whole matrix.
Parameters 'run','testname', and 'num_disks' are mandatory. Defaults are indicated for all otherparameters. For additional information on the user interface, see the Orion User Guide.
--運作ORAION必須包含run,testname,num_disks 三個參數。
<testname>.lun should contain acarriage-return-separated list of LUNs The output files for a test run areprefixed by <testname>_.
The output files are:
<testname>_summary.txt - Summary ofthe input parameters along with min. small latency, max large MBPS and/or max.small IOPS.
<testname>_mbps.csv - Performanceresults of large IOs in MBPS(吞吐量)
<testname>_iops.csv - Performanceresults of small IOs in IOPS(每秒IO次數)
<testname>_lat.csv - Latency of smallIOs(響應時間)
<testname>_tradeoff.csv - Shows largeMBPS / small IOPS combinations that can be achieved at certain small latencies
<testname>_trace.txt - Extended,unprocessed output(跟蹤資訊,最詳細的資料)
--ORION 執行結束會輸出5個檔案,每個檔案的不同作用參考上面的說明。
WARNING: IF YOU ARE PERFORMING WRITE TESTS,BE PREPARED TO LOSE ANY DATA STORED ON THE LUNS.
Mandatory parameters(強制的參數說明):
run Type of workload to run(simple, normal, advanced)
simple - tests random 8K small IOs at various loads,then random 1M largeIOs at various loads.
normal - tests combinations of random8K small IOs and random 1M large IOs
advanced - run theworkload specified by the user using optional parameters
testname Name of the test run
num_disks Number of disks (physicalspindles)
Optional parameters(可選的參數說明,注意預設值):
size_small Size of small IOs (in KB) -default 8
size_large Size of large IOs (in KB) -default 1024
type Type of large IOs (rand,seq) - default rand
rand - Random largeIOs
seq - Sequential streams of large IOs
num_streamIO Number of concurrent IOs per stream(only if type is seq) - default 4
simulate Orion tests on a virtual volumeformed by combining the provided volumes in one of these ways (default concat):
concat - A serialconcatenation of the volumes
raid0 - A RAID-0mapping across the volumes
write Percentage of writes (SEEWARNING ABOVE) - default 0
cache_size Size *IN MEGABYTES* of thearray's cache.
Unless this option is set to 0, Orion does anumber of (unmeasured) random IO before each large sequential data point. This is done in order to fill up the array cachewith random data. This way, the blocksfrom one data point do not result in cache hits for the next data point. Read tests are preceded with junk reads andwrite tests are preceded with junk writes. If specified, this 'cache warming' is done until cache_size worth of IOhas been read or written.
Default behavior: fillup cache for 2 minutes before each data point.
duration Duration of each data point (inseconds) - default 60
num_small Number of outstanding small IOs(only if matrix is point, col, or max) - no default
num_large For random, number ofoutstanding large IOs.
For sequential, numberof streams (only if matrix is point, row, or max) - nodefault
matrix An Orion test consists ofdata points at various small and large IO load levels. These points can be represented as atwo-dimensional matrix: Each column in the matrix represents a fixed small IOload. Each row represents a fixed largeIO load. The first row is with no largeIO load and the first column is with no small IO load. An Orion test can be a single point, a row, acolumn or the whole matrix, depending on the matrix option setting below (default basic):
basic - test thefirst row and the first column
detailed - test theentire matrix
point - test at loadlevel num_small, num_large
col - varying largeIO load with num_small small IOs
row - varying smallIO load with num_large large IOs
max - test varyingloads up to num_small, num_large
verbose Prints tracing information tostandard output if set.
Default -- not set
Examples
For a preliminary set of data
-run simple -testname <name> -num_disks <#>
For a basic set of data
-run normal -testname <name> -num_disks <#>
To generate combinations of 32KB and 1MBreads to random locations:
-run advanced -testname <name> -num_disks <#>
-size_small 32 -size_large 1024 -type rand -matrix detailed
To generate multiple sequential 1MB writestreams, simulating 1MB RAID0 stripes
-simulate RAID0 -stripe 1024 -write 100 -type seq
-matrix col -num_small 0
C:\Program Files (x86)\Oracle\Orion>
2.1 在Orion的安裝目錄下建立dave.lun檔案,在裡面添加要測試的分區,比如:
這裡我們要對D盤進行測試。
2.2 執行orion指令。
Orion有三個不同的等級,simple,normal,advance. 這個根據自己的需求來進行設定。 如:
<a>--注意這裡的testname 參數,隻需要寫檔案名就可以了,orion 會自動補上擴充名,如果寫上擴充名,反而會報錯</a>
ORION: ORacle IONumbers -- Version 10.2.0.1.0
Test will takeapproximately 9 minutes
Larger cachesmay take longer
這裡的testname 寫我們之前配置的lun檔案的名稱, num_disks 是磁盤的數量。
2.3 檢視結果
在orion的安裝目錄下,會生成幾個檔案:dave_iops.csv;dave_lat.csv;dave_mbps.csv; dave_summary.txt 和dave_trace.txt 檔案。 我們可以看一下summary的内容。
ORION VERSION10.2.0.1.0
Commandline:
-run simple-testname dave -num_disks 1
This maps tothis test:
Test: dave
Small IO size: 8KB
Large IO size:1024 KB
IO Types: SmallRandom IOs, Large Random IOs
Simulated ArrayType: CONCAT
Write: 0%
Cache Size: NotEntered
Duration foreach Data Point: 60 seconds
SmallColumns:, 0
LargeColumns:, 0, 1, 2
Total DataPoints: 8
Name: \\.\D: Size: 1784847360
1 FILEs found.
Maximum LargeMBPS=32.83 @ Small=0 and Large=1
Maximum SmallIOPS=74 @ Small=2 and Large=0
Minimum SmallLatency=13.53 @ Small=1 and Large=0
因為其測試結果是csv檔案,是以可以很友善的根據結果在excle中繪制壓力曲線。
3.1 解壓縮ORION
用root使用者解壓軟體:
unzip orion_linux_x86-64.gz
解壓完成後,生成ORION軟體:orion_linux_x86-64
3.2 配置dave.lun 檔案。如:
/dev/sdc1
/dev/sdd1
/dev/sde1
/dev/sdf1
3.3 執行orion指令:
3.4 檢視結果
4.1、資料庫OLTP類型,假定IO類型全部是8K随機操作,壓力類型,自動加壓,從小到大,一直到存儲壓力極限
#./orion -run advanced -testname dave-num_disks 1 -size_small 8 -size_large 8 -type rand &
4.2、資料庫吞吐量測試,假定IO全部是1M的序列性IO
#./orion -run advanced -testname mytest-num_disks 96 -size_small 1024 -size_large 1024 -type seq &
4.3、指定特定的IO類型與IO壓力,如指定小IO為壓力500的時候,不同大IO下的壓力情況
#./orion -run advanced -testname mytest-num_disks 96 -size_small 8 -size_large 128 -matrix col -num_small 500 -typerand &
4.4、結合不同的IO類型,測試壓力矩陣
#./orion -run advanced -testname mytest-num_disks 96 -size_small 8 -size_large 128 -matrix detailed -type rand &
--------------------------------------------------------
下面部分轉載Eygle Bolg,測試一個HP的MSA1000的存儲,并将資料生成效果圖分析
測試使用如下指令:
./orion -run simple -testname mytest -num_disks 10
以下是iops/mbps/latency的效果圖:
<a target="_blank" href="http://blog.51cto.com/attachment/201201/164507929.jpg"></a>
在目前存儲配置下,IO最大吞吐量可以達到138M/s,iops穩定狀态達到2800左右,而Latency在Load Level 30左右的時候達到10ms。
本文轉自 hsbxxl 51CTO部落格,原文連結:http://blog.51cto.com/hsbxxl/759238,如需轉載請自行聯系原作者