The serial/telnet/ssh console provides a set of racadm commands. The racadm commands provide access to the text-based features supported by the DRAC 5 Web-based interface.
RACADM enables you to locally or remotely configure and manage your DRAC 5. RACADM runs on the management station and the managed system. RACADM is included on the
Dell Systems Console and Agent CD.
You can use RACADM to write scripts to automatically configure multiple DRAC 5s. For more information about configuring multiple DRAC 5s, see "Configuring Multiple DRAC 5 Cards".
Using the racadm configuration file to configure multiple DRAC 5 cards
Using a Serial or Telnet Console
You can run the serial commands in Table 9-1 remotely using RACADM or from the serial/telnet/ssh console command prompt.
Logging in to the DRAC 5
After you have configured your management station terminal emulator software and managed node BIOS, perform the following steps to log into the DRAC 5:
Connect to the DRAC 5 using your management station terminal
emulation software.
Type your DRAC 5 user name and press <Enter>.
You are logged into the DRAC 5.
Starting a Text Console
After you have logged into the DRAC 5 through your management station terminal software with telnet or SSH, you can redirect the managed system text console by using connect com2, which is a telnet/SSH command. Only one connect com2 client is supported at a time.
To connect to the managed system text console, open a DRAC 5 command prompt (displayed through a telnet or SSH session) and type:
connect com2
From a serial session, you can connect to the managed system's serial console by pressing <Esc><Shift><Q>, which connects the managed system's serial port directly to the servers' COM2 port and bypasses the DRAC 5. To reconnect the DRAC 5 to the serial port, press <Esc><Shift><9>. The managed node COM2 port and the DRAC 5 serial port baud rates must be identical.
The connect -h com2 command displays the contents of the serial history buffer before waiting for input from the keyboard or new characters from the serial port.
NOTE: When using the -h option, the client and server terminal emulation type
(ANSI or VT100) must be identical; otherwise, the output may be garbled.
Additionally, set the client terminal row to 25.
The default (and maximum) size of the history buffer is 8192 characters. You can set this number to a smaller value using the command:
You can run the RACADM commands locally or remotely from the serial or telnet console command prompt or through a normal command prompt.
Use the racadm command to configure DRAC 5 properties, perform remote management tasks, or recover a crashed system.
To display the racadm subcommand list using RACADM, type:
racadm help
The subcommand list includes all commands that are supported by the DRAC 5.
Without options, the racadm commanddisplays general use information. Type racadm help to display a list of all available subcommands. Type racadm help<subcommand> to list any syntax and command-line options for the subcommand.
The following sections provide information about how to use the racadm commands.
Using RACADM Remotely
NOTE: Configure the IP address on your DRAC 5 before using the racadm remote
capability. For more information about setting up your DRAC 5 and a list of related
documents, see "Installing and Setting Up the DRAC 5".
RACADM provides a remote capability option (-r) that allows you to connect to the managed system and execute racadm subcommands from a remote console or management station. To use the remote capability, you need a valid user name (-u option) and password (-p option), and the DRAC 5 IP address.
NOTE: If the system from where you are accessing the remote system does not
have a DRAC certificate in its default certificate store, a message is displayed when
you type a racadm command.
Security Alert: Certificate is invalid - Name on Certificate is invalid or does not match site name
Enter "Y" to continue, or any other key to quit
NOTE: The racadm remote capability is supported only on management stations.
For more information, see the Dell Systems Software Support Matrix on the Dell
Support website at support.dell.com for more information.
NOTE: When using the racadm remote capability, you must have write permissions
on the folders where you are using the racadm subcommands involving file
operations, for example:
racadm -i -r <RAC IP Address>:<port> <subcommand> <subcommand options>
RACADM Options
Table 9-1 lists the options for the racadm command.
Table 9-1. racadm Command Options
Option
Description
-r <racIpAddr>
-r <racIpAddr>:<port number>
Specifies the controller's remote IP address.
Use :<port number> if the DRAC 5 port number is not the default port (443)
-i
Instructs racadm to interactively query the user for user name and password.
-u <usrName>
Specifies the user name that is used to authenticate the command transaction. If the -u option is used, the -p option must be used, and the -i option (interactive) is not allowed.
-p <password>
Specifies the password used to authenticate the command transaction. If the -p option is used, the -i option is not allowed.
Enabling and Disabling the racadm Remote Capability
NOTE: It is recommended that you run these commands on your local system.
The racadm remote capability is enabled by default. If disabled, type the following racadm command to enable:
Table 9-2 provides a description of each racadm subcommand that you can run in RACADM. For a detailed listing of racadm subcommands including syntax and valid entries, see "RACADM Subcommand Overview".
When entering a RACADM subcommand, prefix the command with racadm. For example:
Using RACADM, you can configure one or more DRAC 5 cards with identical properties. When you query a specific DRAC 5 card using its group ID and object ID, RACADM creates the racadm.cfg configuration file from the retrieved information. By exporting the file to one or more DRAC 5 cards, you can configure your controllers with identical properties in a minimal amount of time.
NOTE: Some configuration files contain unique DRAC 5 information (such as the
static IP address) that must be modified before you export the file to other DRAC 5
cards.
To configure multiple DRAC 5 cards, perform the following procedures:
Use RACADM to query the target DRAC 5 that contains the appropriate
configuration.
NOTE: The generated .cfg file does not contain user passwords.
Open a command prompt and type:
racadm getconfig -f myfile.cfg
NOTE: Redirecting the RAC configuration to a file using getconfig -f is only
supported with the local and remote RACADM interfaces.
Modify the configuration file using a simple text editor (optional).
Use the new configuration file to modify a target RAC.
In the command prompt, type:
racadm config -f myfile.cfg
Reset the target RAC that was configured.
In the command prompt, type:
racadm reset
The getconfig -f racadm.cfg subcommand requests the DRAC 5 configuration and generates the racadm.cfg file. If required, you can configure the file with another name.
You can use the getconfig command to enable you to perform the following actions:
Display all configuration properties in a group (specified by group name and index)
Display all configuration properties for a user by user name
The config subcommand loads the information into other DRAC 5s. Use config to synchronize the user and password database with Server Administrator
The initial configuration file, racadm.cfg, is named by the user. In the following example, the configuration file is named myfile.cfg. To create this file, type the following at the command prompt:
racadm getconfig -f myfile.cfg
NOTICE: It is recommended that you edit this file with a simple text editor. The
racadm utility uses an ASCII text parser. Any formatting confuses the parser, which
may corrupt the racadm database.
Creating a DRAC 5 Configuration File
The DRAC 5 configuration file <filename>.cfg is used with the racadm config -f <filename>.cfg command. The configuration file is a simple text file that allows the user to build a configuration file (similar to an .ini file) and configure the DRAC 5 from this file. You may use any file name, and the file does not require a .cfg extension (although it is referred to by that designation in this subsection).
The .cfg file can be:
Created
Obtained from a racadm getconfig -f <filename>.cfg command
Obtained from a racadm getconfig -f <filename>.cfg command, and then edited
NOTE: See "getconfig" for information about the getconfig command.
The .cfg file is first parsed to verify that valid group and object names are present and that some simple syntax rules are being followed. Errors are flagged with the line number that detected the error, and a simple message explains the problem. The entire file is parsed for correctness, and all errors are displayed. Write commands are not transmitted to the DRAC 5 if an error is found in the .cfg file. The user must correct all errors before any configuration can take place. The -c option may be used in the config subcommand, which verifies syntax only and does not perform writes to the DRAC 5.
Use the following guidelines when you create a .cfg file:
If the parser encounters an indexed group, it is the value of the anchored object that differentiates the various indexes.
The parser reads in all of the indexes from the DRAC 5 for that group. Any objects within that group are simple modifications when the DRAC 5 is configured. If a modified object represents a new index, the index is created on the DRAC 5 during configuration.
The user cannot specify a desired index in a .cfg file.
Indexes may be created and deleted, so over time the group may become fragmented with used and unused indexes. If an index is present, it is modified. If an index is not present, the first available index is used. This method allows flexibility when adding indexed entries where the user does not need to make exact index matches between all the RACs being managed. New users are added to the first available index. A .cfg file that parses and runs correctly on one DRAC 5 may not run correctly on another if all indexes are full and you must add a new user.
Use the racresetcfg subcommand to configure all DRAC 5 cards with identical properties.
Use the racresetcfg subcommand to reset the DRAC 5 to original defaults, and then run the racadm config -f <filename>.cfgcommand. Ensure that the .cfg file includes all desired objects, users, indexes, and other parameters.
NOTICE: Use the racresetcfg subcommand to reset the database and the DRAC 5
NIC settings to the original default settings and remove all users and user
configurations. While the root user is available, other users' settings are also reset
to the default settings.
Parsing Rules
All lines that start with '#' are treated as comments.
A comment line must start in column one. A '#' character in any other column is treated as a # character.
Some modem parameters may include # characters in its string. An escape character is not required. You may want to generate a .cfg from a racadm getconfig -f <filename>.cfg command, and then perform a racadm config -f <filename>.cfg command to a different DRAC 5, without adding escape characters.
Example:
#
# This is a comment
[cfgUserAdmin]
cfgUserAdminPageModemInitString=<Modem init # not
a comment>
All group entries must be surrounded by "[" and "]" characters.
The starting "[" character denoting a group name must start in column one. This group name must be specified before any of the objects in that group. Objects that do not include an associated group name generate an error. The configuration data is organized into groups as defined in "DRAC 5 Property Database Group and Object Definitions".
The following example displays a group name, object, and the object's property value.
Example:
[cfgLanNetworking] -{group name}
cfgNicIpAddress=143.154.133.121 {object name}
All parameters are specified as "object=value" pairs with no white space between the object, =, or value.
White spaces that are included after the value are ignored. A white space inside a value string remains unmodified. Any character to the right of the '=' is taken as is (for example, a second '=', or a '#', '[', ']', and so forth). These characters are valid modem chat script characters.
See the example in the previous bullet.
The .cfg parser ignores an index object entry.
The user cannot specify which index is used. If the index already exists, it is either used or the new entry is created in the first available index for that group.
The racadm getconfig -f <filename>.cfg command places a comment in front of index objects, allowing the user to see the included comments.
NOTE: The user may create an indexed group manually using the following
command:
racadm config -g <groupName> -o <anchored object> -i <index 1-16><unique
anchor name>
The line for an indexed group cannot be deleted from a .cfg file.
The user must remove an indexed object manually using the following command:
NOTE: A NULL string (identified by two "" characters) directs the DRAC 5 to delete
the index for the specified group.
To view the contents of an indexed group, use the following command:
racadm getconfig -g <groupName> -i <index 1-16>
For indexed groups the object anchor must be the first object after the "[ ]" pair. The following are examples of the current indexed groups:
[cfgUserAdmin]
cfgUserAdminUserName=<USER_NAME>
If you type racadm getconfig -f <myexample>.cfg, the command builds a .cfg file for the current DRAC 5 configuration. This configuration file can be used as an example and as a starting point for your unique .cfg file.
Modifying the DRAC 5 IP Address
When you modify the DRAC 5 IP address in the configuration file, remove all unnecessary <variable>=value entries. Only the actual variable group's label with "[" and "]" remains, including the two <variable>=value entries pertaining to the IP address change.
For example:
#
# Object Group "cfgLanNetworking"
#
[cfgLanNetworking]
cfgNicIpAddress=10.35.10.110
cfgNicGateway=10.35.10.1
This file will be updated as follows:
#
# Object Group "cfgLanNetworking"
#
[cfgLanNetworking]
cfgNicIpAddress=10.35.9.143
# comment, the rest of this line is ignored
cfgNicGateway=10.35.9.1
The command racadm config -f myfile.cfg parses the file and identifies any errors by line number. A correct file will update the proper entries. Additionally, you can use the same getconfig command from the previous example to confirm the update.
Use this file to download company-wide changes or to configure new systems over the network.
NOTE: "Anchor" is an internal term and should not be used in the file.
Using the RACADM Utility to Configure the DRAC 5
NOTE: You must be logged in as user root to execute RACADM commands on a
remote Linux system.
The DRAC 5 Web-based interface is the quickest way to configure a DRAC 5. If you prefer command-line or script configuration or need to configure multiple DRAC 5s, use RACADM, which is installed with the DRAC 5 agents on the managed system.
To configure multiple DRAC 5s with identical configuration settings, perform one of the following procedures:
Use the RACADM examples in this section as a guide to create a batch file of racadm commands and then execute the batch file on each managed system.
Create the DRAC 5 configuration file as described in "RACADM Subcommand Overview" and execute the racadm config subcommand on each managed system using the same configuration file.
Before You Begin
You can configure up to 16 users in the DRAC 5 property database. Before you manually enable a DRAC 5 user, verify if any current users exist. If you are configuring a new DRAC 5 or you ran the racadm racresetcfg command, the only current user is root with the password calvin. The racresetcfg subcommand resets the DRAC 5 back to the original defaults.
NOTICE: Use caution when using the racresetcfg command, as all configuration
parameters are reset to the original defaults. Any previous changes are lost.
NOTE: Users can be enabled and disabled over time. As a result, a user may have a
different index number on each DRAC 5.
To verify if a user exists, type the following command at the command prompt:
racadm getconfig -u <username>
OR
type the following command once for each index of 116:
racadm getconfig -g cfgUserAdmin -i <index>
NOTE: You can also type racadm getconfig -f <myfile.cfg> and view
or edit the myfile.cfg file, which includes all DRAC 5 configuration parameters.
Several parameters and object IDs are displayed with their current values. Two objects of interest are:
# cfgUserAdminIndex=XX
cfgUserAdminUserName=
If the cfgUserAdminUserName object has no value, that index number, which is indicated by the cfgUserAdminIndex object, is available for use. If a name appears after the "=", that index is taken by that user name.
NOTE: When you manually enable or disable a user with the racadm config
subcommand, you must specify the index with the -i option. Observe that the
cfgUserAdminIndex object displayed in the previous example contains a '#'
character. Also, if you use the racadm config -f racadm.cfg command to specify any
number of groups/objects to write, the index cannot be specified. A new user is
added to the first available index. This behavior allows more flexibility in configuring
multiple DRAC 5s with the same settings.
Adding a DRAC 5 User
To add a new user to the RAC configuration, a few basic commands can be used. In general, perform the following procedures:
Set the user name.
Set the password.
Set the user privileges.
Enable the user.
Example
The following example describes how to add a new user named "John" with a "123456" password and LOGIN privileges to the RAC.
racadm config -g cfgUserAdmin -o cfgUserAdminUserName -i 2 john
A null string of double quote characters ("") instructs the DRAC 5 to remove the user configuration at the specified index and reset the user configuration to the original factory defaults.
Testing e-mail Alerting
The RAC e-mail alerting feature allows users to receive e-mail alerts when a
critical event occurs on the managed system. The following example shows
how to test the e-mail alerting feature to ensure that the RAC can properly
send out e-mail alerts across the network.
racadm testemail -i 2
NOTE: Ensure that the SMTP and Email Alert settings are configured before testing
the e-mail alerting feature. See "Configuring E-Mail Alerts" for more
information.
Testing the RAC SNMP Trap Alert Feature
The RAC SNMP trap alerting feature allows SNMP trap listener configurations to receive traps for system events that occur on the managed system.
The following example shows how a user can test the SNMP trap alert feature of the RAC.
racadm testtrap -i 2
Before you test the RAC SNMP trap alerting feature, ensure that the SNMP and trap settings are configured correctly. See "testtrap" and "testemail" subcommand descriptions to configure these settings.
Enabling a DRAC 5 User With Permissions
To enable a user with specific administrative permissions (role-based authority), first locate an available user index by performing the steps in "Before You Begin". Next, type the following command lines with the new user name and password.
NOTE: See Table B-2 for a list of valid bit mask values for specific user privileges.
The default privilege value is 0, which indicates the user has no privileges enabled.
The commands provide the same configuration functionality as the option ROM at boot-up when you are prompted to type <Ctrl><e>. For more information about configuring network properties with the option ROM, see "Configuring DRAC 5 Network Properties".
The following is an example of how the command may be used to configure desired LAN network properties.
The DRAC uses its own NIC (RJ-45 connector) and the BMC MAC address for network traffic.
Shared
The DRAC uses Broadcom LOM1 on the planar.
Shared with failover
The DRAC uses Broadcom LOM1 and LOM2 as a team for failover. The team uses the BMC MAC address.
Frequently Asked Questions
Table 9-4 lists the frequently asked questions and answers.
Table 9-4. Using the serial and racadm Commands: Frequently Asked Questions
Question
Answer
After performing a DRAC 5 reset (using the racadm racreset command), I issue a command and the following message is displayed:
racadm <command name> Transport: ERROR: (RC=-1)
What does this message mean?
You must wait until the DRAC 5 completes the reset before issuing another command.
When I use the racadm commands and subcommands, I get errors that I don't understand.
You may encounter one or more of the following errors when using the racadm commands and subcommands:
Local error messages Problems such as syntax, typographical errors, and incorrect names.
Example:
ERROR: <message>
When I ping the DRAC IP address from my system and then switch my DRAC 5 card between Dedicated and Shared modes during the ping response, I do not receive a response.