MegaCli 命令使用指南Word格式文档下载.docx

上传人:b****4 文档编号:16176863 上传时间:2022-11-21 格式:DOCX 页数:10 大小:172.79KB
下载 相关 举报
MegaCli 命令使用指南Word格式文档下载.docx_第1页
第1页 / 共10页
MegaCli 命令使用指南Word格式文档下载.docx_第2页
第2页 / 共10页
MegaCli 命令使用指南Word格式文档下载.docx_第3页
第3页 / 共10页
MegaCli 命令使用指南Word格式文档下载.docx_第4页
第4页 / 共10页
MegaCli 命令使用指南Word格式文档下载.docx_第5页
第5页 / 共10页
点击查看更多>>
下载资源
资源描述

MegaCli 命令使用指南Word格式文档下载.docx

《MegaCli 命令使用指南Word格式文档下载.docx》由会员分享,可在线阅读,更多相关《MegaCli 命令使用指南Word格式文档下载.docx(10页珍藏版)》请在冰豆网上搜索。

MegaCli 命令使用指南Word格式文档下载.docx

17.#/opt/MegaRAID/MegaCli/MegaCli64 

-cfgdsply 

-aALL【显示Raid卡型号,Raid设置,Disk相关信息】

18.3.磁带状态的变化,从拔盘,到插盘的过程中。

19.Device 

|Normal|Damage|Rebuild|Normal

20.VirtualDrive 

|Optimal|Degraded|Degraded|Optimal

21.PhysicalDrive 

|Online|Failed–>

 

Unconfigured|Rebuild|Online

22.4.查看磁盘缓存策略

23.#/opt/MegaRAID/MegaCli/MegaCli64 

-LDGetProp 

-Cache 

-L0 

-a0

24.or

25.#/opt/MegaRAID/MegaCli/MegaCli64 

-L1 

26.or

27.#/opt/MegaRAID/MegaCli/MegaCli64 

28.ro

29.#/opt/MegaRAID/MegaCli/MegaCli64 

-aALL

30.ro

31.#/opt/MegaRAID/MegaCli/MegaCli64 

-DskCache 

32.5.设置磁盘缓存策略

33.缓存策略解释:

34.

35.WT 

(Writethrough

36.WB 

(Writeback)

37.NORA 

(Noreadahead)

38.RA 

(Readahead)

39.ADRA 

(Adaptivereadahead)

40.Cached

41.Direct

42.例子:

43.#/opt/MegaRAID/MegaCli/MegaCli64 

-LDSetPropWT|WB|NORA|RA|ADRA 

44.or

45.#/opt/MegaRAID/MegaCli/MegaCli64 

-LDSetProp 

-Cached|-Direct 

46.or

47.enable 

disablediskcache

48.#/opt/MegaRAID/MegaCli/MegaCli64 

-EnDskCache|-DisDskCache 

49.6.创建一个raid5阵列,由物理盘2,3,4构成,该阵列的热备盘是物理盘5

50.#/opt/MegaRAID/MegaCli/MegaCli64 

-CfgLdAdd 

-r5 

[1:

2,1:

3,1:

4] 

WBDirect 

-Hsp[1:

5] 

51.7.创建阵列,不指定热备

52.#/opt/MegaRAID/MegaCli/MegaCli64 

53.8.删除阵列

54.#/opt/MegaRAID/MegaCli/MegaCli64 

-CfgLdDel 

55.9.在线添加磁盘

56.#/opt/MegaRAID/MegaCli/MegaCli64 

-LDRecon 

-Start 

-Add 

-PhysDrv[1:

57.10.阵列创建完后,会有一个初始化同步块的过程,可以看看其进度。

58.#/opt/MegaRAID/MegaCli/MegaCli64 

-LDInit 

-ShowProg 

59.或者以动态可视化文字界面显示

60.#/opt/MegaRAID/MegaCli/MegaCli64 

-ProgDsply 

61.11.查看阵列后台初始化进度

62.#/opt/MegaRAID/MegaCli/MegaCli64 

-LDBI 

63.或者以动态可视化文字界面显示

64.#/opt/MegaRAID/MegaCli/MegaCli64 

65.12.指定第5块盘作为全局热备

66.#/opt/MegaRAID/MegaCli/MegaCli64 

-PDHSP 

-Set 

[-EnclAffinity] 

[-nonRevertible] 

67.13.指定为某个阵列的专用热备

68.#/opt/MegaRAID/MegaCli/MegaCli64 

[-Dedicated 

[-Array1]] 

69.14.删除全局热备

70.#/opt/MegaRAID/MegaCli/MegaCli64 

-Rmv 

71.15.将某块物理盘下线/上线

72.#/opt/MegaRAID/MegaCli/MegaCli64 

-PDOffline 

-PhysDrv 

73.#/opt/MegaRAID/MegaCli/MegaCli64 

-PDOnline 

74.16.查看物理磁盘重建进度

75.#/opt/MegaRAID/MegaCli/MegaCli64 

-PDRbld 

76.或者以动态可视化文字界面显示

77.#/opt/MegaRAID/MegaCli/MegaCli64 

78.

79.磁带状态的变化,从拔盘,到插盘的过程中:

80.Device 

81.VirtualDrive 

82.PhysicalDrive 

83.1、 

查看RAID级别

84.

85.2、 

查看RAID卡信息,主要输出RAID卡的一些配置信息

86.

87.

88.RAIDLevel:

Primary-1,Secondary-0,RAIDLevelQualifier-0

Size:

1.086TB

State:

Optimal

StripSize:

128KB

NumberOfDrivesperspan:

4//表示每4个物理盘做成一个RAID1盘组

SpanDepth:

2//表示共2个RAID1盘组做成了RAID10

89.

90.3、 

查看所有硬盘的信息

91./opt/MegaCli64 

-pdlist 

–aALL

92.

93.4、 

查看当前raid缓存状态,raid缓存状态设置为wb的话要注意电池放电事宜,设置电池放电模式为自动学习模式

94./opt/MegaRAID/MegaCli/MegaCli64 

-ldgetprop 

-dskcache-lall 

-aall

95.

96.5、 

raid 

电池设置相关

97.查看电池状态信息(Display 

BBU 

Status 

Information)

MegaCli 

-aN|-a0,1,2|-aALL

98.查看电池容量(Display 

Capacity 

99.查看电池设计参数(Display 

Design 

Parameters)

100.查看电池属性(Display 

Current 

Properties)

101.设置电池为学习模式为循环模式(Start 

Learning 

Cycle)

Description 

Starts 

the 

learning 

cycle 

on 

BBU.

No 

parameter 

is 

needed 

for 

this 

option.

-BbuLearn 

102.设置磁盘的缓存模式和访问方式 

(Change 

Virtual 

Disk 

Cache 

and 

Access 

Allows 

you 

to 

change 

following 

virtual 

disk 

parameters:

-WT 

(Write 

through), 

WB 

back):

Selects 

write 

policy.

-NORA 

(No 

read 

ahead), 

RA 

(Read 

ADRA 

(Adaptive 

ahead):

-Cached, 

-Direct:

cache 

-RW, 

-RO, 

Blocked:

access 

-EnDskCache:

Enables 

cache.

-DisDskCache:

Disables 

WT 

WB|NORA 

|RA 

ADRA|-Cached|Direct} 

|

{-RW|RO|Blocked} 

{-Name[string]} 

{-EnDskCache|DisDskCache} 

–Lx 

-L0,1,2|-Lall 

103.显示磁盘缓存和访问方式(Display 

-Access 

-Name 

-Lx|-L0,1,2|

Displays 

policies 

of 

disk(s):

-Cache, 

Direct:

-Access, 

-DskCache:

physical 

104.

105.Megaraid必知必会使用LSI的megaraid可以对raid进行有效监控。

别的厂商比如HP,IBM也有自己的raidAPI

MegaCli-ldinfo-lall-aall

查询raid级别,磁盘数量,容量,条带大小。

MegaCli-cfgdsply-aALL|grepPolicy

查询控制器cache策略

MegaCli-LDSetPropWB-L0-a0

设置writeback功能

MegaCli-LDSetPropCachedBadBBU-L0-a0

设置即使电池坏了还是保持WB功能

MegaCli-AdpBbuCmd-BbuLearna0

手动充电

MegaCli-FwTermLog-Dsply-aALL 

查询日志

显示适配器个数:

MegaCli-adpCount

显示所有适配器信息:

MegaCli-AdpAllInfo-aAll

CriticalDisks:

FailedDisks:

显示所有逻辑磁盘组信息:

MegaCli-LDInfo-LALL-aAll

显示所有的物理信息:

MegaCli-PDList-aAll

MediaErrorCount:

0

OtherErrorCount:

查看充电状态:

MegaCli-AdpBbuCmd-GetBbuStatus-aALL

LearnCycleRequested:

No

FullyCharged:

Yes

显示BBU(后备电池)状态信息:

显示BBU容量信息:

MegaCli-AdpBbuCmd-GetBbuCapacityInfo-aALL

显示BBU设计参数:

MegaCli-AdpBbuCmd-GetBbuDesignInfo-aALL

显示当前BBU属性:

MegaCli-AdpBbuCmd-GetBbuProperties-aALL

显示Raid卡型号,Raid设置,Disk相关信息:

MegaCli-cfgdsply-aALL

查看Cache策略设置:

MegaCli-cfgdsply-aALL|grep-iPolicy

CurrentCachePolicy:

WriteBack,ReadAheadNone,Direct,WriteCacheOKifBadBBU

查看充电进度百分比:

MegaCli-AdpBbuCmd-GetBbuStatus-aALL 

各种设备和磁盘的不同状态:

Device|Normal|Damage|Rebuild|Normal

VirtualDrive|Optimal|Degraded|Degraded|Optimal

PhysicalDrive|Online|Failed–>

Unconfigured|Rebuild|Online

106.6、 

通过脚本检测RAID 

磁盘状态

107.Linux下脚本

108.#!

/bin/bash

109.#check 

status

110.MEGACLI="

/opt/MegaRAID/MegaCli/MegaCli64 

"

111.$MEGACLI 

grep 

Firmware 

state"

awk 

-F 

:

'

{print 

$2}'

 

$1}'

>

/tmp/fireware.log

112.$MEGACLI 

-E 

Media 

Error|Other 

Error"

/tmp/disk.log

113.for 

in 

`cat 

<

/tmp/disk.log`

114.do

115.if 

$i 

-ne 

]

116. 

then

117.curl 

http:

//xxxxxxB&

state=ALARM&

description=raid_disk_error"

118.fi

119.done

120.for 

/tmp/fireware.log`

121.do

122.if 

!

Online 

123. 

124.curl 

//xxxxxxstate=ALARM&

description=raid_disk_offline"

125.fi

126.done

127.Windows 

下脚本

128.Windows下脚本用的工具是gnu 

windows平台的一些软件,如 

bash 

cat

129.通过bash直接调用脚本

130.如:

G:

\raid_check\unixtools>

bash.exe 

\disk.sh

131.#check 

132.MEGACLI="

//G/raid_check/MegaCli.exe"

133.GREP="

//G/raid_check/unixtools/grep.exe"

134.AWK="

//G/raid_check/unixtools/awk.exe"

135.CAT="

//G/raid_check/unixtools/cat.exe"

136.CURL="

//G/raid_check/unixtools/curl.exe"

137.$MEGACLI 

$GREP 

|$AWK 

-F:

//c/fireware.log

138.$MEGACLI 

$AWK 

//c/disk.log

139.for 

`$CAT 

c:

/disk.log`

140.do

141.if 

142. 

143.$CURL 

//xxxxxx&

144.fi

145.done

146.for 

/fireware.log`

147.do

148.if 

149. 

150.$CURL 

//xxxxx&

151.fi

(注:

文档可能无法思考全面,请浏览后下载,供参考。

可复制、编制,期待你的好评与关注)

展开阅读全文
相关资源
猜你喜欢
相关搜索

当前位置:首页 > 医药卫生 > 临床医学

copyright@ 2008-2022 冰豆网网站版权所有

经营许可证编号:鄂ICP备2022015515号-1