windows server에서 powershell을 이용하여 hpssacli.exe 커맨드를 이용하는 방법
1. 명령어 파일 다운로드 후 설치
https://support.hpe.com/hpsc/swd/public/detail?swItemId=MTX_05d4c11e7ed3433e85c89ea604
2. 설치 후 cmd에서 명령어 입력 테스트
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 |
Microsoft Windows [Version 6.3.9600] (c) 2013 Microsoft Corporation. All rights reserved. C:\Users\korsys00t>cd C:\Program Files\hp\hpssacli\bin C:\Program Files\hp\hpssacli\bin>hpssacli.exe controller slot=0 show config Smart Array P420i in Slot 0 (Embedded) (sn: 001438010EF4650) Internal Drive Cage at Port 1I, Box 1, OK Internal Drive Cage at Port 2I, Box 1, OK array A (SAS, Unused Space: 0 MB) logicaldrive 1 (279.4 GB, RAID 0, OK) physicaldrive 1I:1:1 (port 1I:box 1:bay 1, SAS, 300 GB, OK) array B (SAS, Unused Space: 0 MB) logicaldrive 2 (1.6 TB, RAID 5, OK) physicaldrive 1I:1:2 (port 1I:box 1:bay 2, SAS, 300 GB, OK) physicaldrive 1I:1:3 (port 1I:box 1:bay 3, SAS, 300.0 GB, OK) physicaldrive 1I:1:4 (port 1I:box 1:bay 4, SAS, 300 GB, OK) physicaldrive 2I:1:5 (port 2I:box 1:bay 5, SAS, 300.0 GB, OK) physicaldrive 2I:1:6 (port 2I:box 1:bay 6, SAS, 300.0 GB, OK) physicaldrive 2I:1:7 (port 2I:box 1:bay 7, SAS, 300 GB, OK) physicaldrive 2I:1:8 (port 2I:box 1:bay 8, SAS, 300 GB, OK) SEP (Vendor ID PMCSIERA, Model SRCv8x6G) 380 (WWID: 5001438010EF465F) C:\Program Files\hp\hpssacli\bin> |
3. 이제 이 부분을 powershell에서 실행하게 구성해보자
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 |
### Show configuration C:\Windows\System32\cmd.exe /c "C:\Program Files\HP\hpssacli\bin\hpssacli.exe" controller slot=0 show config ### Logical 2 Drive Status C:\Windows\System32\cmd.exe /c "C:\Program Files\HP\hpssacli\bin\hpssacli.exe" controller slot=0 ld 2 show ### Controller status C:\Windows\System32\cmd.exe /c "C:\Program Files\HP\hpssacli\bin\hpssacli.exe" controller slot=0 show status ### Show detailed controller information for all controllers C:\Windows\System32\cmd.exe /c "C:\Program Files\HP\hpssacli\bin\hpssacli.exe" controller slot=0 show detail ### Physical disk status C:\Windows\System32\cmd.exe /c "C:\Program Files\HP\hpssacli\bin\hpssacli.exe" controller slot=0 pd all show status ### Show detailed physical disk information C:\Windows\System32\cmd.exe /c "C:\Program Files\HP\hpssacli\bin\hpssacli.exe" controller slot=0 pd all show detail ### Logical disk status C:\Windows\System32\cmd.exe /c "C:\Program Files\HP\hpssacli\bin\hpssacli.exe" controller slot=0 ld all show status ### View Detailed Logical Drive Status C:\Windows\System32\cmd.exe /c "C:\Program Files\HP\hpssacli\bin\hpssacli.exe" controller slot=0 ld 2 show |