4.3BSD-Reno/share/man/cat1/date.0

Compare this file to the similar file:
Show the results in this format:

DATE(1)                     UNIX Reference Manual		       DATE(1)

NNAAMMEE
     ddaattee - Display or set date and time

SSYYNNOOPPSSIISS
     ddaattee [--nnuu] [--dd _d_s_t] [--tt _m_i_n_u_t_e_s__w_e_s_t] [yymmddhhmm [.ss]]

DDEESSCCRRIIPPTTIIOONN
     DDaattee displays today's date and time when invoked without arguments.  Pro-
     viding an argument will set the desired date; only the superuser can set
     the date.

     Options are:

     --dd    Set the kernel's values for daylight savings time.  If _d_s_t is non-
	   zero, future calls to gettimeofday(2) will return a non-zero
	   `tz_dsttime'.

     --tt    Set the kernel's values for minutes west of GMT.  _M_i_n_u_t_e_s__w_e_s_t pro-
	   vides the number of minutes returned by future calls to gettimeof-
	   day(2) in `tz_minuteswest'.

     --uu    Display or set the date in GMT (universal) time.

     The canonical representation for setting the date and time:

	   _y_y	 Year in abbreviated form (.e.g 89 for 1989).
	   _m_m	 Numeric month.  A number from 01 to 12.
	   _d_d	 Day, a number from 01 to 31.
	   _h_h	 Hour, a number from 00 to 24.
	   _m_m	 Minutes, a number from 00 to 60.
	   ._s_s	 Seconds, a number from 00 to 60.

     The command:

	   date 8506131627

     sets the date to June 13 1985, 4:27 PM.

     To reset today's time, the incantation can be shortened to just the hours
     and minutes:

	   date 1432

     sets the time to 2:32 PM, unaffecting the date.

     Providing a system stays running, date will handle time changes for
     daylight/standards savings time and leap times.

     If timed(8) is running to synchronize the clocks of machines in a local
     area network, ddaattee sets the time globally on all those machines unless
     the --nn option is given.

FFIILLEESS
     /_v_a_r/_l_o_g/_w_t_m_p	 A record of date resets and time changes.
     /_v_a_r/_l_o_g/_m_e_s_s_a_g_e_s	 A record of the name of the user setting the time.

SSEEEE AALLSSOO
     gettimeofday(2), utmp(5), timed(8)
     _T_S_P: _T_h_e _T_i_m_e _S_y_n_c_h_r_o_n_i_z_a_t_i_o_n _P_r_o_t_o_c_o_l _f_o_r _U_N_I_X _4._3_B_S_D, R. Gusella
     and S. Zatti

HHIISSTTOORRYY
     DDaattee appeared in Version 6 AT&T UNIX.

DDIIAAGGNNOOSSTTIICCSS
     Exit status is 0 on success, 1 on complete failure to set the date, and 2
     on successfully setting the local date but failing globally.

     Occasionally, when timed synchronizes the time on many hosts, the setting
     of a new time value may require more than a few seconds.  On these occa-
     sions, ddaattee prints: `Network time being set'.  The message `Communication
     error with timed' occurs when the communication between ddaattee and timed
     fails.

BBUUGGSS
     The system attempts to keep the date in a format closely compatible with
     VMS.  VMS, however, uses local time (rather than GMT) and does not under-
     stand daylight-saving time.  Thus, if you use both UNIX and VMS, VMS will
     be running on GMT.