|
|
|
System Administration | setdate(1m) |
| setdate - set the date and time for
the system controller (SC) or a domain |
SYNOPSIS
| setdate [-d domain_indicator ] [-u] [-q] [mmdd]HHMM|mmddHHMM[cc]yy[.SS] |
|
setdate(1M) enables the SC platform administrator to set the SC or optionally set a domain date and time values. Enables domain administrators to set the date and time values for their domains. After the date and time are set setdate(1M) displays the current date and time.
|
|
The following options are supported:
- -d domain_indicator
- Specifies the domain using one of the following:
domain_id -ID for a domain. Valid domain_ids are A-R and are not case sensitive.
domain_tag - Name assigned to a domain using addtag(1M).
Sets the domain time of day (TOD) when the domain keyswitch is in the OFF or STANDBY position. This option is not the primary use of setdate. Normally, setdate is used without this option to set the SC TOD.
- -h
- Help. Displays usage descriptions. Note Use alone. Any option specified in addition to -h is ignored.
- -q
- Does not display current date and time after you set the new value.
- -u
- Interprets and displays the time using Greenwich Mean Time (GMT). The default is the local time zone.
|
|
The following operands are supported:
-
[mmdd]HHMM[.SS]
- Date and time format. mm is the month (1-12), dd is the day of the month (1-31), HH is the hour (0-23), MM is the minute (0-59), and SS is the second (0-59).
-
mmddHHMM[cc]yy[.SS]
- Date and time format. mm is the month (1-12), dd is the day of the month (1-31), HH is the hour (0-23), MM is the minute (0-59), cc is century minus one, yy is the two-digit year, and SS is the second (0-59).
|
|
Group Privileges Required
|
You must have platform or domain administrator privileges to run this command. If you have domain administrator privileges you can run this command only for your domain.
Refer to Chapter 2, "SMS Security Options and Administrative Privileges" in the System Management Services (SMS) 1.4 Administrator Guide for more information.
|
|
| Example 1. Setting the Local Date in Pacific Standard Time
|
|
sc0:sms-user:> setdate 020210302002.00
System Controller: Sat Feb 2 10:30:00 PST 2002
|
|
Example 2. Setting the Date Using GMT
|
|
sc0:sms-user:> setdate -u 020218302002.00
System Controller: Sat Feb 2 18:30:00 GMT 2002
|
|
Example 3. Setting the Local Time in Pacific Standard Time for Domain A
|
|
sc0:sms-user:> setdate -d a 020210302002.00
Domain a: Sat Feb 2 10:30:00 PST 2002
|
|
Example 4. Setting the Date for Domain A Using GMT
|
|
sc0:sms-user:> setdate -d a -u 020218302002.00
Domain a: Sat Feb 2 18:30:00 GMT 2002
|
|
|
|
The following exit values are returned:
-
0
- Successful completion.
- >0
- An error occurred.
|
|
See attributes(5) for descriptions of the following attributes.
Attribute Types | Attribute Values |
Availability | SUNWSMSop |
|
|
addtag(1m), setkeyswitch(1m), showdate(1m)
|
SMS 1.4 | Go To Top | Last Changed 19 September 2003 |
Company Info
|
Contact
|
Copyright 2003 Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, CA 95054 USA. All rights reserved.
|