Skip to main content

date command

This command configures and displays the CMM date settings.

Note
The date command replaces the clock command that was used in previous CMM firmware versions.

If command syntax is not correctly entered, or if a command fails to run, an error message is returned. See Common errors for a list of error messages that apply to all commands or date command errors for a list of error messages that are specific to the date command.

Table 1. date command.

The command table is a multi-row, four-column table where each row describes a CMM CLI command option: column one lists command function, column two provides a detailed command description, column three shows command-option syntax, and column four lists valid command targets.

FunctionWhat it doesCommandTarget (see paths in Command targets)
Display CMM clock informationDisplays the following information for the CMM clock:
  • current date and time
  • GMT (Greenwich-Mean Time) offset
  • daylight-savings time setting
date
Primary CMM:
  • mm[p]
  • mm[P]
  • mm[x]
  • where x is the primary CMM bay number.
Display valid timezone settingsDisplays list of available timezone settings for the CMM clock, with limited information about each time zone. The CMM supports more than 400 geography-based timezone settings.date -tz all
Primary CMM:
  • mm[p]
  • mm[P]
  • mm[x]
  • where x is the primary CMM bay number.
Display valid timezone settings (verbose)Displays list of available timezone settings for the CMM clock, with detailed information about each time zone. The CMM supports more than 400 geography-based timezone settings.
Note
The -v command option must be used with the date -tz all command option.
date -tz all -v
Primary CMM:
  • mm[p]
  • mm[P]
  • mm[x]
  • where x is the primary CMM bay number.
Set CMM dateSets the date for the CMM clock.date -d date

where date is the current calendar date in mm/dd/yyyy format.

The month and day can be input as single digits. The year must be a four-digit number between 1970 and 2037 inclusive.

This command can only be run by users who have the following command authorities:
  • Supervisor
  • Chassis configuration
See Commands and user authority for additional information.
Primary CMM:
  • mm[p]
  • mm[P]
  • mm[x]
  • where x is the primary CMM bay number.
Set CMM timeSets the time for the CMM clock.date -t time

where time is the current time in 24-hour hh:mm:ss format.

The hours, minutes, and seconds can all be input as single digits.

This command can only be run by users who have one or more of the following command authorities:
  • Supervisor
  • Chassis configuration
See Commands and user authority for additional information.
Primary CMM:
  • mm[p]
  • mm[P]
  • mm[x]
  • where x is the primary CMM bay number.
Set CMM clock time zoneSets the time zone for the CMM clock.
Note
The daylight-savings time setting for your time zone is set automatically.
date -tz timezone

where timezone is one of the valid time zone values listed by the date -tz all command.

This command can only be run by users who have the following command authorities:
  • Supervisor
  • Chassis configuration
See Commands and user authority for additional information.
Primary CMM:
  • mm[p]
  • mm[P]
  • mm[x]
  • where x is the primary CMM bay number.
Example: To set the primary CMM for operation in the US Eastern time zone, with a current date of 08/15/2015 and time of 10:38:00, while the Lenovo Flex System chassis is set as the persistent command environment, at the system> prompt, type
date -T mm[p] -tz America/New_York -t 10:38:00 -d 08/15/2015
To display the clock information for the primary CMM, while the Lenovo Flex System chassis is set as the persistent command environment, at the system> prompt, type
date -T mm[p]
To display detailed time zone information for the Abidjan time zone in Africa, while the Lenovo Flex System chassis is set as the persistent command environment, at the system> prompt, type
date -T mm[p] -tz Africa/Abidjan -v

The following example shows the information that is returned from these commands:

system> date -T mm[p] -tz America/New_York -t 10:38:00 -d 08/15/2015
OK
system> date -T mm[p]
08/15/2015 10:38:03 America/New_York (Eastern Time) DST is currently being observed
system> date -T mm[p] -tz Africa/Abidjan -v

Timezone name: Africa/Abidjan
Timezone Standard name: Africa/Abidjan Time
Timezone standard caption: GMT
Timezone CMM offset: UTC
No daylight saving time in 2015
system>