Cluster Tools - IPMItool

See: IpmiTool for general information

ipmitool usage and scripts for controlling IPMI enabled devices

ipmitool scripts

  • Notes:
    • scripts not ending in _nodes require an IPMI/lom address as the first argument
      • localhost causing the script to talk directly to the lom via the kernel on the host you are logged into
    • The scripts below use ipmitool to manage common tasks for ipmi devices
      • setup or change user accounts and passwords
      • list users
      • add users, modify users
      • reset
      • power on/off
      • pxe boot
      • bios setup
      • normal boot
      • Scripts with the suffix _nodes are for operations on all nodes in a cluster

ipmitool - usage examples and options

  • This tool is used by ALL scripts in this document
  • *apt-get install
  • You may add a remote host to the ipmitool command by adding
    • -I lanplus -H lom_address
  • You may provide the user and password
    • -U userid -P password
  • Local Examples:
    • list users - note each user has an number id
      • ipmitool user list 1
    • set user password
      • ipmitool user set 2
    • test user password - not you might want to be carefull - this password is on the command line!
      • ipmitool user test 2 16
    • display ilom network settings
      • ipmitool lan print 1
    • set ilom dhcp
      • ipmitool lan set 1 ipsrc dhcp
    • set static address
      • ipmitool lan set 1 ipsrc static
      • ipmitool lan set 1 ipaddr 172.19.128.254
      • ipmitool lan set 1 defgw ipaddr 172.19.128.
    • Get current active ilom network port
      • ipmitool -I open delloem lan get active
    • Set ilom network port ( on iDRAC12g OR iDRAC13g : dedicated, shared with lom1, shared with lom2,shared with lom3,shared with lom4,shared with failover lom1,shared with failover lom2,shared with failover lom3,shared with failover lom4,shared with Failover all loms, shared with Failover None))
      • ipmitool -I open delloem lan set dedicated
    • Get current ilom network port
      • ipmitool -I open delloem lan get
    • ipmitool chassis status
            System Power         : on
            Power Overload       : false
            Power Interlock      : inactive
            Main Power Fault     : false
            Power Control Fault  : false
            Power Restore Policy : always-off
            Last Power Event     : 
            Chassis Intrusion    : inactive
            Front-Panel Lockout  : inactive
            Drive Fault          : false
            Cooling/Fan Fault    : false
            
  • *Update IPMI/BMC default port
      • To get LAN mode: ipmitool raw 0x30 0x70 0x0c 0
      • To set LAN mode dedicated: ipmitool raw 0x30 0x70 0x0c 1 0
      • To set LAN mode onboard/shared: ipmitool raw 0x30 0x70 0x0c 1 1
      • To set LAN mode failover: ipmitool raw 0x30 0x70 0x0c 1 2

These raw values will also work with ipmicfg (just remember to use -raw instead of raw).

IPMI scripts - Documentation notes

  • Note: Documentation for all of the *ipmi commands below were automatically generated using the sh2twiki command*
    • ssh cscf-adm@asimov
    • cd /cscf-adm/src
    • sudo bash
    • * make docs - invokes sh2wtiki to create both HTML adn TWIKI documents
    • All of the generated TWIKI files will be found under /cscf-adm/src/twiki

Support files

  • see cscf@asimov.uwaterloo.ca:/cscf-adm/ipmi
  • * ipmifunctions: ipmifunctions - ipmi shell functions
    • ipmi bash functions used by all ipmi scripts documented here
  • * common_functions: common functions - shell functions common to all scripts
    • includes common_vars and common_host
  • * common_vars: common variables - global variables to control all scripts
    • Global / Institutional default settings defined as shell variables
  • * common_host: common variables - m160 host specific variables to control all scripts
    • Host specific variables dettings - defined as shell variables - can override any common_vars settings
  • * NODES: NODES file contains definitions for all nodes and ILOMs in a cluster
    • this example from m160

ipmi_account_setup

  • Updated: Fri Oct 28 15:20:53 2016

Add all admin users to ILOM/BMC using ipmiusermod_nodes

  • ipmi_account_setup - document source
  • Author: Mike Gore
  • Date:
    • 25 Oct 2016
  • Depends:
  • package:
    • openmpi
  • scripts:
    • ipmifunctions, common_host,common_vars,common_functions and NODES found in /usr/local/bin
  • Example:
    • ./impi_account_setup
    • We can set accounts here, or in common_host prior to calling ipmiusermod_nodes
    • ADMIN - Name of default ADMIN user
    • ADMINPASS - Password of Admin user
    • CSCFADM - CSCF Admin user - default is: cscf-adm
    • CSCFADMPASS - CSCF Amdin password
    • OTHERUSER - Cluster Admin - if not set or empty the other user is NOT created
    • OTHERPASS - Cluster Admiin password

ipmibios

  • Updated: Thu Oct 27 16:44:42 2016

boot into BIOS after next reboot

  • ipmibios - document source
  • Author: Mike Gore
  • Date:
    • 25 Oct 2016
  • Depends:
  • package:
    • openmpi
  • scripts:
    • ipmifunctions, common_host,common_vars,common_functions and NODES found in /usr/local/bin
  • Example:
    • ./ipmibios host-ilom
    • - Where host-ilom is the node ILOM/BMC interface
    • - needs and AMDIN user and password to function
  • Result:
    • The node will boot into BIOS on next restart
  • Notes:
    • The script will prompt for ADMIN user and password unless the following environment variables are set:
    • ADMIN - userid of ADMIN user
    • ADMINPASS - Password of "ADMIN" user

ipmibios_nodes

  • Updated: Fri Oct 28 09:46:56 2016

Boot into BIOS after next restart

  • ipmibios_nodes - document source
  • Author: Mike Gore
  • Date:
    • 25 Oct 2016
  • Depends:
  • package:
    • openmpi
  • scripts:
    • ipmifunctions, common_host,common_vars,common_functions and NODES found in /usr/local/bin
  • Example:
    • ./ipmibios_nodes
    • - needs and AMDIN user and password to function
  • Result:
    • All nodes are set to boot to bios after next restart
  • Notes:
    • The script will prompt for ADMIN user and password unless the following environment variables are set:
    • ADMIN - userid of ADMIN user
    • ADMINPASS - Password of "ADMIN" user

ipmibootnormal

  • Updated: Tue Nov 1 11:38:20 2016

boot normally after next reboot

  • ipmibootnormal - document source
  • Author: Mike Gore
  • Date:
    • 25 Oct 2016
  • Depends:
  • package:
    • openmpi
  • scripts:
    • ipmifunctions, common_host,common_vars,common_functions and NODES found in /usr/local/bin
  • Example:
    • ./ipmibootbormal host-ilom
    • - Where host-ilom is the node ILOM/BMC interface
    • - needs and AMDIN user and password to function
  • Result:
    • The node will boot normally after next restart
  • Notes:
    • The script will prompt for ADMIN user and password unless the following environment variables are set:
    • ADMIN - userid of ADMIN user
    • ADMINPASS - Password of "ADMIN" user

ipmibootnormal_nodes

  • Updated: Tue Nov 1 11:39:04 2016

Boot normally after next reboot

  • ipmibootnormal_nodes - document source
  • Author: Mike Gore
  • Date:
    • 25 Oct 2016
  • Depends:
  • package:
    • openmpi
  • scripts:
    • ipmifunctions, common_host,common_vars,common_functions and NODES found in /usr/local/bin
  • Example:
    • ./ipmibootnormal_nodes
    • - needs and AMDIN user and password to function
  • Result:
    • All nodes are set to boot normally after after next restart
  • Notes:
    • The script will prompt for ADMIN user and password unless the following environment variables are set:
    • ADMIN - userid of ADMIN user
    • ADMINPASS - Password of "ADMIN" user

ipmipoweroff

  • Updated: Thu Oct 27 16:46:18 2016

Power off node

  • ipmipoweroff - document source
  • Author: Mike Gore
  • Date:
    • 25 Oct 2016
  • Depends:
  • package:
    • openmpi
  • scripts:
    • ipmifunctions, common_host,common_vars,common_functions and NODES found in /usr/local/bin
  • Example:
    • ./ipmipoweroff ilom-host
    • - Where host-ilom is the node ILOM/BMC interface
    • - needs and AMDIN user and password to function
  • Result:
    • The node will poweroff NOW
  • Notes:
    • The script will prompt for ADMIN user and password unless the following environment variables are set:
    • ADMIN - userid of ADMIN user
    • ADMINPASS - Password of "ADMIN" user

ipmipoweroff_nodes

  • Updated: Fri Oct 28 09:44:59 2016

Power off all nodes

  • ipmipoweroff_nodes - document source
  • Author: Mike Gore
  • Date:
    • 25 Oct 2016
  • Depends:
  • package:
    • openmpi
  • scripts:
    • ipmifunctions, common_host,common_vars,common_functions and NODES found in /usr/local/bin
  • Example:
    • ./ipmipoweroff_nodes
    • - needs and AMDIN user and password to function
  • Result:
    • ALl nodes are powered off
  • Notes:
    • The script will prompt for ADMIN user and password unless the following environment variables are set:
    • ADMIN - userid of ADMIN user
    • ADMINPASS - Password of "ADMIN" user

ipmipoweron

  • Updated: Thu Oct 27 16:46:08 2016

Power on node

  • ipmipoweron - document source
  • Author: Mike Gore
  • Author: Mike Gore
  • Date:
    • 25 Oct 2016
  • Depends:
  • package:
    • openmpi
  • scripts:
    • ipmifunctions, common_host,common_vars,common_functions and NODES found in /usr/local/bin
  • Example:
    • ./ipmipoweron host-ilom
    • - host-ilom is the node ILOM/BMC interface
    • - needs and AMDIN user and password to function
  • Result:
    • The node will power on NOW
  • Notes:
    • The script will prompt for ADMIN user and password unless the following environment variables are set:
    • ADMIN - userid of ADMIN user
    • ADMINPASS - Password of "ADMIN" user

ipmipoweron_nodes

  • Updated: Fri Oct 28 09:45:40 2016

Power on all nodes

  • ipmipoweron_nodes - document source
  • Author: Mike Gore
  • Date:
    • 25 Oct 2016
  • Depends:
  • package:
    • openmpi
  • scripts:
    • ipmifunctions, common_host,common_vars,common_functions and NODES found in /usr/local/bin
  • Example:
    • ./ipmipoweron_nodes
    • - needs and AMDIN user and password to function
  • Result:
    • ALl nodes are powered on
  • Notes:
    • The script will prompt for ADMIN user and password unless the following environment variables are set:
    • ADMIN - userid of ADMIN user
    • ADMINPASS - Password of "ADMIN" user

ipmipxeboot

  • Updated: Tue Nov 1 11:51:07 2016

PXE boot setting takes effect after next reboot

  • ipmipxeboot - document source
  • Author: Mike Gore
  • Date:
    • 25 Oct 2016
  • Depends:
  • package:
    • openmpi
  • scripts:
    • ipmifunctions, common_host,common_vars,common_functions and NODES found in /usr/local/bin
  • Example:
    • ./ipmipxeboot host-ilom
    • - The node will PXE boot the next time it is restarted
    • - Where host-ilom is the node ILOM/BMC interface
    • - needs and AMDIN user and password to function
  • Result:
    • node will PXE boot on next reboot only
  • Notes:
    • The script will prompt for ADMIN user and password unless the following environment variables are set:
    • ADMIN - userid of ADMIN user
    • ADMINPASS - Password of "ADMIN" user

ipmipxeboot_nodes

  • Updated: Tue Nov 1 11:51:14 2016

Boot into PXE after next restart

  • ipmipxeboot_nodes - document source
  • Author: Mike Gore
  • Date:
    • 25 Oct 2016
  • Depends:
  • package:
    • openmpi
  • scripts:
    • ipmifunctions, common_host,common_vars,common_functions and NODES found in /usr/local/bin
  • Example:
    • ./ipmipxeboot_nodes
    • - needs and AMDIN user and password to function
  • Result:
    • All nodes are set to boot to pxe after next restart
  • Notes:
    • The script will prompt for ADMIN user and password unless the following environment variables are set:
    • ADMIN - userid of ADMIN user
    • ADMINPASS - Password of "ADMIN" user

ipmireset

  • Updated: Thu Oct 27 16:45:38 2016

Reset node - right now no waiting

  • ipmireset - document source
  • Author: Mike Gore
  • Date:
    • 25 Oct 2016
  • Depends:
  • package:
    • openmpi
  • scripts:
    • ipmifunctions, common_host,common_vars,common_functions and NODES found in /usr/local/bin
  • Example:
    • ./ipmireset host-ilom
    • - Where host-ilom is the node ILOM/BMC interface
    • - needs and AMDIN user and password to function
  • Result:
    • Reset node NOW
  • Notes:
    • The script will prompt for ADMIN user and password unless the following environment variables are set:
    • ADMIN - userid of ADMIN user
    • ADMINPASS - Password of "ADMIN" user

ipmireset_nodes

  • Updated: Fri Oct 28 09:48:48 2016

Reset all nodes NOW

  • ipmireset_nodes - document source
  • Author: Mike Gore
  • Date:
    • 25 Oct 2016
  • Depends:
  • package:
    • openmpi
  • scripts:
    • ipmifunctions, common_host,common_vars,common_functions and NODES found in /usr/local/bin
  • Example:
    • ./ipmireset_nodes
    • - needs and AMDIN user and password to function
  • Result:
    • All nodes are reset right now
  • Notes:
    • The script will prompt for ADMIN user and password unless the following environment variables are set:
    • ADMIN - userid of ADMIN user
    • ADMINPASS - Password of "ADMIN" user

ipmiuserdel

  • Updated: Tue Nov 1 11:47:41 2016

Delete an ILOM/BMC user and permissions on a node

  • ipmiuserdel - document source
  • Author: Mike Gore
  • Author: Mike Gore
  • Date:
    • 25 Oct 2016
  • Depends:
  • package:
    • openmpi
  • scripts:
    • ipmifunctions, common_host,common_vars,common_functions and NODES found in /usr/local/bin
  • Example:
    • ./ipmiuserdel host-ilom usernumber
    • - Where host-ilom is the node ILOM/BMC interface
    • - Where usernumber is number entry for a given user
    • - needs and AMDIN user and password to function
  • Result:
    • Delet a user from a node
  • Notes:
    • The script will prompt for ADMIN user and password unless the following environment variables are set:
    • ADMIN - userid of ADMIN user
    • ADMINPASS - Password of "ADMIN" user

  • VARS:

ipmiuserlist

  • Updated: Fri Oct 28 09:34:50 2016

List ILOM/BMC users and permissions on a node

  • ipmiuserlist - document source
  • Author: Mike Gore
  • Author: Mike Gore
  • Date:
    • 25 Oct 2016
  • Depends:
  • package:
    • openmpi
  • scripts:
    • ipmifunctions, common_host,common_vars,common_functions and NODES found in /usr/local/bin
  • Example:
    • ./ipmiuserlist host-ilom
    • - Where host-ilom is the node ILOM/BMC interface
    • - needs and AMDIN user and password to function
  • Result:
    • List ILOM/BMC users permissions on a node
  • Notes:
    • The script will prompt for ADMIN user and password unless the following environment variables are set:
    • ADMIN - userid of ADMIN user
    • ADMINPASS - Password of "ADMIN" user

  • VARS:

ipmiuserlist_nodes

  • Updated: Fri Oct 28 09:40:51 2016

List users and permissions on ALL nodes

  • ipmiuserlist_nodes - document source
  • Author: Mike Gore
  • Date:
    • 25 Oct 2016
  • Depends:
  • package:
    • openmpi
  • scripts:
    • ipmifunctions, common_host,common_vars,common_functions and NODES found in /usr/local/bin
  • Example:
    • ./ipmiuserlist_nodes
    • - needs and AMDIN user and password to function
  • Result:
    • List ILOM/BMC users permissions on ALL nodes
  • Notes:
    • The script will prompt for ADMIN user and password unless the following environment variables are set:
    • ADMIN - userid of ADMIN user
    • ADMINPASS - Password of "ADMIN" user

ipmiusermod

  • Updated: Thu Oct 27 16:40:41 2016

Update or add users on the ILOM/BMC

  • ipmiusermod - document source
  • Author: Mike Gore
  • Date:
    • 25 Oct 2016
  • Depends:
  • package:
    • openmpi
  • scripts:
    • ipmifunctions, common_host,common_vars,common_functions and NODES found in /usr/local/bin
  • Example:
    • ./ipmiusermod host-ilom
    • - Where host-ilom is the node ILOM/BMC interface
  • Result:
    • Add / Update users on ILOM/BMC interface
    • - Used for creating or updating users on ILOM/BMC
    • - Can update AMDIN password
    • - Creates or updates cscf-adm user name and password
    • - Optionally Creates or updates cluster admin user and password
  • Notes:
    • The script will prompt for input user and passwords required
  • Returns:
    • ADMIN - Name of default ADMIN user
    • ADMINPASS - Password of Admin user
    • OLDADMINPASS - Original password of Admin user
    • CSCFADM - CSCF Admin user - default is: cscf-adm
    • CSCFADMPASS - CSCF Amdin password
    • OTHERUSER - Cluster Admin - if not set or empty the other user is NOT created
    • OTHERPASS - Cluster Admin password

ipmiusermod_manual

  • Updated: Tue Nov 1 11:52:16 2016

Change an ILOM/BMC user user entry with manual user number,name and password values

  • ipmiusermod_manual - document source
  • Author: Mike Gore
  • Date:
    • 25 Oct 2016
  • Depends:
  • package:
    • openmpi
  • scripts:
    • ipmifunctions, common_host,common_vars,common_functions and NODES found in /usr/local/bin
  • Example:
    • ./ipmiusermod_manual host-ilom USERNUM USERNAME PASSWORD
    • - Where host-ilom is the node ILOM/BMC interface
    • - needs and AMDIN user and password to function
  • Result:
    • List ILOM/BMC users permissions on a node
  • Notes:
    • The script will prompt for ADMIN user and password unless the following environment variables are set:
    • ADMIN - userid of ADMIN user
    • ADMINPASS - Password of "ADMIN" user

  • VARS:

  • 1:
    • allback level, 2:User level, 3: Operator level, 4:Administrator level
    • priv []

ipmiusermod_manual_nodes

  • Updated: Tue Nov 1 11:52:29 2016

Change an ILOM/BMC user user entry with manual user number,name and password values

  • ipmiusermod_manual_nodes - document source
  • Author: Mike Gore
  • Author: Mike Gore
  • Date:
    • 25 Oct 2016
  • Depends:
  • package:
    • openmpi
  • scripts:
    • ipmifunctions, common_host,common_vars,common_functions and NODES found in /usr/local/bin
  • Example:
    • ./ipmiusermod_manual USERNUM USERNAME PASSWORD
    • - Where host-ilom is the node ILOM/BMC interface
    • - needs and AMDIN user and password to function
  • Result:
    • List ILOM/BMC users permissions on a node
  • Notes:
    • The script will prompt for ADMIN user and password unless the following environment variables are set:
    • ADMIN - userid of ADMIN user
    • ADMINPASS - Password of "ADMIN" user

ipmiusermod_nodes

  • Updated: Fri Oct 28 15:20:34 2016

Add admin users to ILOM/BMC on ALL NODES in a cluster

  • ipmiusermod_nodes - document source
  • Author: Mike Gore
  • Date:
    • 25 Oct 2016
  • Depends:
  • package:
    • openmpi
  • scripts:
    • ipmifunctions, common_host,common_vars,common_functions and NODES found in /usr/local/bin
  • Example:
    • ./ipmiusermod_nodes
    • - needs and AMDIN user and password to function
  • Result:
    • Add or update users on ALL ILOM/BMC nodes
    • - Used for creating initial users on ILOM/BMC
    • - Updates AMDIN password for user ADMIN
    • - Creates: cscf-adm user and password
    • - Optionally Creates: cluster admin user and password
    • - Add ILMOM/BMC users to all nodes in a cluster
    • - needs and AMDIN user and password to function
  • Notes:
    • The script will prompt for input -
    • unless the following environment variables are set prior to running the script
    • ADMIN - Name of default ADMIN user
    • ADMINPASS - Password of Admin user
    • CSCFADM - CSCF Admin user - default is: cscf-adm
    • CSCFADMPASS - CSCF Amdin password
    • OTHERUSER - Cluster Admin - if not set or empty the other user is NOT created
    • OTHERPASS - Cluster Admiin password

ipmifunctions

  • Updated: Tue Nov 1 10:52:10 2016

IPMI functions - LPMI/LOM access and account maintanence functions used by all ipmi scripts

  • ipmifunctions - document source
  • Author: Mike Gore
  • Date:
    • 25 Oct 2016
  • Depends:
    • package: openipmi, Scripts: common_host,common_vars,common_functions and NODES found in /usr/local/bin
  • Scripts:
    • see cscf-adm@asimov.uwaterloo.ca:/cscf-adm/ipmi
    • common_functions
    • common bash functions/tools
    • includes common_vars and common_host
    • common_vars
    • Global / Institutional default settings defined as shell variables
    • common_host
    • Host specific variables dettings - defined as shell variables - can override any common_vars settings
    • ipmifunctions
    • ipmi bash functions used by all ipmi scripts documented here
  • Example:
    • update admin password and cscf-adm password - see ipmiusermod for a full example
    • . ipmifunctions
    • if ! lom_check "$1"
    • then
    • fatal "LOM $1 is not responding"
    • fi
    • set_default_accounts
    • set_admin_password change
    • set_user_passwords
    • if [ -n "$OLDADMINPASS" ]
    • then
    • usermod "$ADMIN" "$OLDADMINPASS" "$ADMIN" "$ADMINPASS"
    • else
    • usermod "$ADMIN" "$ADMINPASS" "$ADMIN" "$ADMINPASS"
    • fi
    • updatepriv
    • if [ -n "$CSCFADM" ]
    • then
    • usermod "$ADMIN" "$ADMINPASS" "$CSCFADM" "$CSCFADMPASS"
    • fi

set_default_accounts()

  • Function:
    • Set default account names for CSCFAND and OTHER
  • Arguments:
    • none
  • Notes:
    • common_host / common_vars should define these accounts
    • This function is ONLY for STANDALONE use outside of a cluster context
  • Vars:
    • CSCFADM - Name of default CSCF ADMIN user
    • OTHERUSER - Name of optional other userid or blank - typically a cluster user for cluster admins
  • Depends:
    • common_functions - optional common_vars and common_host
  • Example:
    • . ipmifunctions
    • if ! lom_check "$1"
    • then
    • fatal "LOM $1 is not responding"
    • fi
    • set_default_accounts

lom_check()

  • Function:
    • check if LOM is up and set the ipmitool options for remote access
  • Arguments:
    • LOM IP address or name
    • fatal error if LOM is not specified
  • Returns:
    • LOMHOST - used by ipmitool
    • LOM - LOM hostname or IP address
  • Depends:
    • common_functions - optional common_vars and common_host
  • Example:
    • . ipmifunctions
    • if ! lom_check "$1"
    • then
    • fatal "LOM $1 is not responding"
    • fi

updatepriv()

  • Function:
    • Update channel 1 access levels
  • Arguments:
    • none
    • LOMHOST - set by lom_check
    • ADMIN - admin user id - set by set_admin_password
    • ADMINPASS - admin password - set by set_admin_password
    • fatal error if passwords or ILOM is offline
  • Depends:
    • common_functions - optional common_vars and common_host
    • set_admin_password, lom_check
  • Example:
    • . ipmifunctions
  • Example:
    • if ! lom_check "$1"
    • then
    • fatal "LOM $1 is not responding"
    • fi
    • set_admin_password
    • updatepriv

listusers()

  • Function:
    • list ILOM users and access levels
  • Arguments:
    • none
  • Notes:
    • used by usermod function to modify ILOM account
    • Does NOT prompt for any variables that are already set
    • LOMHOST - set by lom_check function
    • ADMIN - admin user id - - set by set_admin_password
    • ADMINPASS - admin password -- set by set_admin_password
  • Depends:
    • common_functions - optional common_vars and common_host
    • set_admin_password, lom_check
  • Example:
    • . ipmifunctions
  • Example:
    • if ! lom_check "$1"
    • then
    • fatal "LOM $1 is not responding"
    • fi
    • set_admin_password
    • listusers

usermod()

  • Function:
    • modify and existing, or create a new user and password
  • Arguments:
    • arg#1 - admin name
    • arg#2 - admin password
    • arg#3 - username
    • arg#4 - user password
  • Depends:
    • set_admin_password, set_user_passwords
  • Returns:
    • USERNUM = numeric userid of user
    • USERNEXT = numeric userid of next free unused user slot number
    • USERNAME = username
    • USERPASS = userpass
  • Notes:
    • admin name, admin password, username and user password must exist or fatal exit is raised
  • Depends:
    • common_functions - optional common_vars and common_host
    • set_admin_password, lom_check
  • Example:
    • . ipmifunctions
    • if ! lom_check "$1"
    • then
    • fatal "LOM $1 is not responding"
    • fi
    • set_default_accounts
    • set_admin_password change
    • set_user_passwords
    • if [ -n "$OLDADMINPASS" ]
    • then
    • usermod "$ADMIN" "$OLDADMINPASS" "$ADMIN" "$ADMINPASS"
    • else
    • usermod "$ADMIN" "$ADMINPASS" "$ADMIN" "$ADMINPASS"
    • fi
    • updatepriv

set_admin_password()

  • Function:
    • *prompt for ADMIN account password *
  • Arguments:
    • [change] - optionally prompt for new and old password
  • Notes:
    • used by usermod function to modify ILOM accounts
    • Does NOT prompt for any variables that are already set
  • Vars:
    • ADMIN - Name of default ADMIN user
    • ADMINPASS - Password of Admin user
    • OLDADMINPASS - Original password of Admin user if change option specified
    • Returns
    • ADMIN - Name of default ADMIN user
    • ADMINPASS - Password of Admin user
    • OLDADMINPASS - Original password of Admin user if change option specified
  • Depends:
    • common_functions - optional common_vars and common_host
    • set_admin_password, lom_check
  • Example:
    • . ipmifunctions
    • if ! lom_check "$1"
    • then
    • fatal "LOM $1 is not responding"
    • fi
    • set_admin_password

set_user_passwords()

  • Function:
    • prompt for CSCFADM and OTHER user
  • Arguments:
    • none
  • Notes:
    • Used by usermod function to modify ILOM accounts
    • Does NOT prompt if CSCFADM or OTHERUSER are empty
    • Does NOT prompt for any variables that are already set
  • Vars:
    • CSCFADM - CSCF Admin user - default is: cscf-adm
    • CSCFADMPASS - CSCF Amdin password
    • OTHERUSER - Cluster Admin - if not set or empty the other user is NOT created
    • OTHERPASS - Cluster Admin password
  • Returns:
    • CSCFADM - CSCF Admin user - default is: cscf-adm
    • CSCFADMPASS - CSCF Amdin password
    • OTHERUSER - Cluster Admin - if not set or empty the other user is NOT created
    • OTHERPASS - Cluster Admin password
  • Depends:
    • common_functions - optional common_vars and common_host
    • set_admin_password, lom_check
  • Example:
    • . ipmifunctions
    • if ! lom_check "$1"
    • then
    • fatal "LOM $1 is not responding"
    • fi
    • set_admin_password
    • set_user_passwords
Topic attachments
I Attachment History Action Size Date Who Comment
Unknown file formatext NODES r1 manage 0.1 K 2016-10-28 - 15:08 MikeGore NODES file contains definitions for all nodes and ILOMs in a cluster - example from m160
Unknown file formatext common_functions r1 manage 79.2 K 2016-10-28 - 15:06 MikeGore common shell functions
Unknown file formatext common_host r1 manage 3.5 K 2016-10-28 - 15:07 MikeGore common_host example from m160
Unknown file formatext common_vars r1 manage 6.6 K 2016-10-28 - 15:07 MikeGore common variables - host specific variables to control all scripts
Unknown file formatext ipmibios r2 r1 manage 1.3 K 2016-10-28 - 15:00 MikeGore  
Unknown file formatext ipmibios_nodes r2 r1 manage 1.1 K 2016-10-28 - 15:00 MikeGore  
Unknown file formatext ipmibootnormal r2 r1 manage 1.3 K 2016-11-01 - 11:59 MikeGore boot normally after next restart
Unknown file formatext ipmibootnormal_nodes r1 manage 1.1 K 2016-11-01 - 11:59 MikeGore ipmi boot normally after next restart
Unknown file formatext ipmifunctions r2 r1 manage 11.5 K 2016-11-01 - 11:58 MikeGore ipmifunctions - ipmi shell functions
Unknown file formatext ipmipoweroff r2 r1 manage 1.2 K 2016-10-28 - 15:00 MikeGore  
Unknown file formatext ipmipoweroff_nodes r2 r1 manage 1.1 K 2016-10-28 - 15:01 MikeGore  
Unknown file formatext ipmipoweron r2 r1 manage 1.2 K 2016-10-28 - 15:01 MikeGore  
Unknown file formatext ipmipoweron_nodes r2 r1 manage 1.1 K 2016-10-28 - 15:01 MikeGore  
Unknown file formatext ipmipxeboot r3 r2 r1 manage 1.3 K 2016-11-01 - 12:00 MikeGore PXE boot after next restart
Unknown file formatext ipmipxeboot_nodes r2 r1 manage 1.1 K 2016-10-28 - 15:02 MikeGore  
Unknown file formatext ipmireset r2 r1 manage 1.2 K 2016-10-28 - 15:02 MikeGore  
Unknown file formatext ipmireset_nodes r2 r1 manage 1.1 K 2016-10-28 - 15:03 MikeGore  
Unknown file formatext ipmiuserdel r2 r1 manage 1.8 K 2016-11-01 - 12:00 MikeGore Delete a user by number
Unknown file formatext ipmiuserlist r3 r2 r1 manage 1.3 K 2016-10-28 - 15:03 MikeGore  
Unknown file formatext ipmiuserlist_nodes r2 r1 manage 1.1 K 2016-10-28 - 15:03 MikeGore  
Unknown file formatext ipmiusermod r1 manage 2.2 K 2016-10-28 - 15:03 MikeGore  
Unknown file formatext ipmiusermod_manual r2 r1 manage 2.7 K 2016-11-01 - 12:01 MikeGore Modify user entry with manual number,userid and password
Unknown file formatext ipmiusermod_manual_nodes r1 manage 1.7 K 2016-11-01 - 10:56 MikeGore Modifiy a user using number,name and password on all nodes
Unknown file formatext ipmiusermod_nodes r1 manage 1.9 K 2016-10-28 - 15:04 MikeGore  
Edit | Attach | Watch | Print version | History: r12 < r11 < r10 < r9 < r8 | Backlinks | Raw View | WYSIWYG | More topic actions
Topic revision: r12 - 2018-08-28 - MikeGore
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2024 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback