Dell服务器忘记idrac密码,如何在不重启服务器的情况下重置密码?

同HP提供了hponconfig工具一样,Dell也为我们提供了RACADM工具,包含在Dell EMC iDRAC Tools(RACADM + IPMITool)中。

Linux版下载地址:https://www.dell.com/support/home/cn/zh/cnbsd1/drivers/driversdetails?driverid=0992n

Windows版下载地址:https://www.dell.com/support/home/cn/zh/cnbsd1/drivers/driversdetails?driverid=2v013

下面以Linux系统为例,介绍一下重置idrac root密码的方式。

1、 下载tar.gz文件并上传至目标目录,操作系统必须是直接安装在裸金属服务器的。

2、解压,安装RACADM

[root@localhost ~]# tar -zxvf DellEMC-iDRACTools-Web-LX-9.4.0-3732_A00.tar.gz 
iDRACTools/
iDRACTools/license.txt
iDRACTools/ipmitool/
iDRACTools/ipmitool/RHEL7_x86_64/
iDRACTools/ipmitool/RHEL7_x86_64/ipmitool-1.8.18-99.dell.3732.15734.el7.x86_64.rpm
iDRACTools/ipmitool/RHEL8_x86_64/
iDRACTools/ipmitool/RHEL8_x86_64/ipmitool-1.8.18-99.dell.3732.15734.el8.x86_64.rpm
iDRACTools/ipmitool/SLES15_x86_64/
iDRACTools/ipmitool/SLES15_x86_64/ipmitool-1.8.18-99.dell.3732.15734.sles15.x86_64.rpm
iDRACTools/readme.txt
iDRACTools/racadm/
iDRACTools/racadm/uninstall_racadm.sh
iDRACTools/racadm/install_racadm.sh
iDRACTools/racadm/SLES15/
iDRACTools/racadm/SLES15/x86_64/
iDRACTools/racadm/SLES15/x86_64/srvadmin-hapi-9.4.0-3732.15734.sles15.x86_64.rpm
iDRACTools/racadm/SLES15/x86_64/srvadmin-idracadm7-9.4.0-3732.15734.sles15.x86_64.rpm
iDRACTools/racadm/SLES15/x86_64/srvadmin-argtable2-9.4.0-3732.15734.sles15.x86_64.rpm
iDRACTools/racadm/RHEL7/
iDRACTools/racadm/RHEL7/x86_64/
iDRACTools/racadm/RHEL7/x86_64/srvadmin-argtable2-9.4.0-3732.15734.el7.x86_64.rpm
iDRACTools/racadm/RHEL7/x86_64/srvadmin-hapi-9.4.0-3732.15734.el7.x86_64.rpm
iDRACTools/racadm/RHEL7/x86_64/srvadmin-idracadm7-9.4.0-3732.15734.el7.x86_64.rpm
iDRACTools/racadm/RHEL8/
iDRACTools/racadm/RHEL8/x86_64/
iDRACTools/racadm/RHEL8/x86_64/srvadmin-argtable2-9.4.0-3732.15734.el8.x86_64.rpm
iDRACTools/racadm/RHEL8/x86_64/srvadmin-idracadm7-9.4.0-3732.15734.el8.x86_64.rpm
iDRACTools/racadm/RHEL8/x86_64/srvadmin-hapi-9.4.0-3732.15734.el8.x86_64.rpm
iDRACTools/gpl.txt
[root@localhost ~]# ls
iDRACTools            
DellEMC-iDRACTools-Web-LX-9.4.0-3732_A00.tar.gz
[root@localhost ~]# cd iDRACTools/
[root@localhost iDRACTools]# ls
gpl.txt  ipmitool  license.txt  racadm  readme.txt
[root@localhost iDRACTools]# cd racadm/
[root@localhost racadm]# ls
install_racadm.sh  RHEL7  RHEL8  SLES15  uninstall_racadm.sh
[root@localhost racadm]# ./install_racadm.sh 
警告:srvadmin-argtable2-9.4.0-3732.15734.el7.x86_64.rpm: 头V4 RSA/SHA512 Signature, 密钥 ID 34d8786f: NOKEY
准备中...                          ################################# [100%]
正在升级/安装...
   1:srvadmin-hapi-9.4.0-3732.15734.el################################# [ 33%]
   2:srvadmin-argtable2-9.4.0-3732.157################################# [ 67%]
   3:srvadmin-idracadm7-9.4.0-3732.157################################# [100%]
     **********************************************************
     After the install process completes, you may need 
     to logout and then login again to reset the PATH
     variable to access the RACADM CLI utilities

     **********************************************************

按照提示退出并重新登录操作系统,以重置环境变量。

查看环境变量。

[root@localhost racadm]# export
declare -x OLDPWD="/root/iDRACTools"
declare -x PWD="/root/iDRACTools/racadm"

3、查看idrac root索引号,索引号为2

[root@localhost ~]# racadm getconfig -u root
# cfgUserAdminIndex=2
cfgUserAdminUserName=root
# cfgUserAdminPassword=******** (Write-Only)
cfgUserAdminEnable=1
cfgUserAdminPrivilege=0x000001ff
cfgUserAdminIpmiLanPrivilege=4
cfgUserAdminIpmiSerialPrivilege=4
cfgUserAdminSolEnable=1

4、重置icrac root密码

[root@localhost ~]# racadm set iDRAC.Users.2.Password calvin
[Key=iDRAC.Embedded.1#Users.2]
Object value modified successfully

密码设置成功,可登录idrac测试。