From owner-freebsd-questions@FreeBSD.ORG Thu Apr 15 20:58:08 2004 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 997BE16A4CE for ; Thu, 15 Apr 2004 20:58:08 -0700 (PDT) Received: from ozlabs.org (ozlabs.org [203.10.76.45]) by mx1.FreeBSD.org (Postfix) with ESMTP id 14BEA43D45 for ; Thu, 15 Apr 2004 20:58:08 -0700 (PDT) (envelope-from grog@lemis.com) Received: from blackwater.lemis.com (blackwater.lemis.com [192.109.197.80]) by ozlabs.org (Postfix) with ESMTP id 7DBBD2BD81 for ; Fri, 16 Apr 2004 13:58:05 +1000 (EST) Received: by blackwater.lemis.com (Postfix, from userid 1004) id 847E151225; Fri, 16 Apr 2004 13:28:02 +0930 (CST) Date: Fri, 16 Apr 2004 13:28:02 +0930 From: Greg 'groggy' Lehey To: JJB Message-ID: <20040416035802.GM24048@wantadilla.lemis.com> References: Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="sMkrXc3gAYLRVOjR" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.1i Organization: The FreeBSD Project Phone: +61-8-8388-8286 Fax: +61-8-8388-8725 Mobile: +61-418-838-708 WWW-Home-Page: http://www.FreeBSD.org/ X-PGP-Fingerprint: 9A1B 8202 BCCE B846 F92F 09AC 22E6 F290 507A 4223 cc: "freebsd-questions@FreeBSD. ORG" Subject: Re: timezone command X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Apr 2004 03:58:08 -0000 --sMkrXc3gAYLRVOjR Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thursday, 15 April 2004 at 22:15:06 -0400, JJB wrote: > Time zone has been set during sysinstall. > Is there an console command to display my configured time zone like > format +05:00? Not quite like that (are you in Pakistan?). The problem is that time zones aren't that simple: they contain information about daylight savings time, as well as implicit historical information that gets lost when you reduce it to a number. Admittedly, Pakistan doesn't seem to have DST, but that's the way it is. In general, the system time zone is stored in the file /etc/localtime. You can set it with: # cp /usr/share/zoneinfo/Asia/Karachi /etc/localtime=20 # date Fri Apr 16 08:55:27 PKT 2004 If you remove it, it defaults to "GMT" (really UTC): # rm /etc/localtime # date Fri Apr 16 03:55:37 GMT 2004 Even then, you can specify the time zone explicitly with the TZ environment variable: # TZ=3DAsia/Karachi date Fri Apr 16 08:55:45 PKT 2004 Greg -- When replying to this message, please copy the original recipients. If you don't, I may ignore the reply or reply to the original recipients. For more information, see http://www.lemis.com/questions.html Note: I discard all HTML mail unseen. Finger grog@FreeBSD.org for PGP public key. See complete headers for address and phone numbers. --sMkrXc3gAYLRVOjR Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.0 (FreeBSD) iD8DBQFAf1nKIubykFB6QiMRAkXCAJ0XcsTgxl4btyVEy0CXklfSd5KiagCgjljZ 06pAs4AWQ+bODOBZOyGa1uU= =C3de -----END PGP SIGNATURE----- --sMkrXc3gAYLRVOjR--