반응형
Avamar Backup Check를 위한 스크립트입니다.
직접 웹에서 확인하기 불편해서 만들었습니다.
주의 : 최근 백업한 내용을 보여주기때문에 일자별 확인 필요합니다.
#!/bin/bash
1_Avamar="111.111.111.111"
2_Avamar="111.111.111.111"
3_Avamar="111.111.111.111"
4_Avamar="111.111.111.111"
5_Avamar="111.111.111.111"
ID=" "
PW=" "
echo "==========================================================================="
echo "=============================1 Avamar Check================================"
echo "==========================================================================="
sshpass -p"${PW}" ssh -o StrictHostKeyChecking=no -o LogLevel=quiet $ID@${1_Avamar} -p22 "mccli server show-prop" | egrep -i "Total capacity|capacity used|Last checkpoint"
sshpass -p"${PW}" ssh -o StrictHostKeyChecking=no -o LogLevel=quiet $ID@${1_Avamar} -p22 "cplist"
sshpass -p"${PW}" ssh -o StrictHostKeyChecking=no -o LogLevel=quiet $ID@${1_Avamar} -p22 "mccli activity show"
echo "==========================================================================="
echo "=============================2 Avamar Check================================"
echo "==========================================================================="
sshpass -p"${PW}" ssh -o StrictHostKeyChecking=no -o LogLevel=quiet $ID@${2_Avamar} -p22 "mccli server show-prop" | egrep -i "Total capacity|capacity used|Last checkpoint"
sshpass -p"${PW}" ssh -o StrictHostKeyChecking=no -o LogLevel=quiet $ID@${2_Avamar} -p22 "cplist"
sshpass -p"${PW}" ssh -o StrictHostKeyChecking=no -o LogLevel=quiet $ID@${2_Avamar} -p22 "mccli activity show"
echo "==========================================================================="
echo "=============================3 Avamar Check================================"
echo "==========================================================================="
sshpass -p"${PW}" ssh -o StrictHostKeyChecking=no -o LogLevel=quiet $ID@${3_Avamar} -p22 "cplist"
sshpass -p"${PW}" ssh -o StrictHostKeyChecking=no -o LogLevel=quiet $ID@${3_Avamar} -p22 "mccli server show-prop" | egrep -i "Total capacity|capacity used|Last checkpoint"
sshpass -p"${PW}" ssh -o StrictHostKeyChecking=no -o LogLevel=quiet $ID@${3_Avamar} -p22 "mccli activity show"
echo "==========================================================================="
echo "==============================4 Avamar Check==============================="
echo "==========================================================================="
sshpass -p"${PW}" ssh -o StrictHostKeyChecking=no -o LogLevel=quiet $ID@${4_Avamar} -p22 "mccli server show-prop" | egrep -i "Total capacity|capacity used|Last checkpoint"
sshpass -p"${PW}" ssh -o StrictHostKeyChecking=no -o LogLevel=quiet $ID@${4_Avamar} -p22 "cplist"
sshpass -p"${PW}" ssh -o StrictHostKeyChecking=no -o LogLevel=quiet $ID@${4_Avamar} -p22 "mccli activity show"
echo "==========================================================================="
echo "==============================5 Avamar Check==============================="
echo "==========================================================================="
sshpass -p"${PW}" ssh -o StrictHostKeyChecking=no -o LogLevel=quiet $ID@${5_Avamar} -p22 "mccli server show-prop" | egrep -i "Total capacity|capacity used|Last checkpoint"
sshpass -p"${PW}" ssh -o StrictHostKeyChecking=no -o LogLevel=quiet $ID@${5_Avamar} -p22 "cplist"
sshpass -p"${PW}" ssh -o StrictHostKeyChecking=no -o LogLevel=quiet $ID@${5_Avamar} -p22 "mccli activity show"
echo " "
echo " Avamar Backup Check completed! "
반응형
'Command & Development > Shell Script' 카테고리의 다른 글
[Shell Script] HP Server Health check Shell(Update) (0) | 2023.09.06 |
---|---|
[ShellScript] DB, NFS Backup check (0) | 2023.07.18 |
[Shell Script] iLO Health Check Script (0) | 2023.02.21 |
[Shell Script] Linux 설치 후 초기 설정 (0) | 2023.01.31 |
[Shell Script] Ubuntu Shell Script : unexpected operator (0) | 2022.11.16 |