Skip to main content

cluster date modify

Contributors
Suggest changes

Modify the current date and time for the nodes in the cluster

Availability: This command is available to cluster administrators at the admin privilege level.

Description

The cluster date modify command sets the time zone, date, and time on every node in the cluster.

Parameters

[-timezone <Area/Location Timezone>] - Time Zone

This parameter sets the timezone, specified in the Olson format.

{ [-date {MM/DD/YYYY HH:MM:SS [{+|-}hh:mm]}] - Date and Time

This parameter sets the date and time, in the format MM/DD/YYYY HH:MM:SS.

| [-dateandtime <[[[[[cc]yy]mm]dd]hhmm[.ss]]>] - Date and Time

This parameter sets the date and time information, in the format [[[[[cc]yy]mm]dd]hhmm[.ss]]. The argument for setting the date and time is interpreted as follows:

  • cc First 2 digits of the year (e.g., 20 for 2011).

  • yy Last 2 digits of year (e.g., 10 for 2010).

  • mm Numeric month, a number from 01 to 12.

  • dd Day, a number from 01 to 31.

  • hh Hour, a number from 00 to 23.

  • mm Minute, a number from 00 to 59.

  • ss Second, a number from 00 to 59.

If the first two digits of the year are omitted, and the last two digits are greater than 68, a date in the 1900s is used. Otherwise, a date in the 2000s is used. If all four digits of the year are omitted, the default is the current year. If the month or day is omitted, the default is the current month or day, respectively. If the seconds are omitted, the default is set to 00. The system automatically handles the time changes for Daylight Saving and Standard time, and for leap seconds and years.

| [-u, -utcdateandtime <[[[[[cc]yy]mm]dd]hhmm[.ss]]>] - UTC Date and Time }

This parameter sets the date and time information in Coordinated Universal Time (UTC), in the format [[[[[cc]yy]mm]dd]hhmm[.ss]]. -u is an alias for -utcdateandtime. The argument for setting the date and time is interpreted as follows:

  • cc First 2 digits of the year (e.g., 20 for 2011).

  • yy Last 2 digits of year (e.g., 10 for 2010).

  • mm Numeric month, a number from 01 to 12.

  • dd Day, a number from 01 to 31.

  • hh Hour, a number from 00 to 23.

  • mm Minute, a number from 00 to 59.

  • ss Second, a number from 00 to 59.

If the first two digits of the year are omitted, and the last two digits are greater than 68, a date in the 1900s is used. Otherwise, a date in the 2000s is used. If all four digits of the year are omitted, the default is the current year. If the month or day is omitted, the default is the current month or day, respectively. If the seconds are omitted, the default is set to 00. Time changes for Daylight Saving and Standard time, and for leap seconds and years, are handled automatically.

Examples

The following example sets the date and time to January 1 2011, at 1:00 a.m.:

cluster1::> cluster date modify -date "01/01/2011 01:00:00"

The following example sets the date and time in the UTC format to May 22, 2011, at 09:25:00 a.m.:

cluster1::> cluster date modify -u 201105220925.00.