<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://aznot.com/index.php?action=history&amp;feed=atom&amp;title=Linux%2FTime</id>
	<title>Linux/Time - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://aznot.com/index.php?action=history&amp;feed=atom&amp;title=Linux%2FTime"/>
	<link rel="alternate" type="text/html" href="https://aznot.com/index.php?title=Linux/Time&amp;action=history"/>
	<updated>2026-05-07T03:46:27Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.41.0</generator>
	<entry>
		<id>https://aznot.com/index.php?title=Linux/Time&amp;diff=5770&amp;oldid=prev</id>
		<title>Kenneth: /* Time Zones */</title>
		<link rel="alternate" type="text/html" href="https://aznot.com/index.php?title=Linux/Time&amp;diff=5770&amp;oldid=prev"/>
		<updated>2020-11-25T22:55:05Z</updated>

		<summary type="html">&lt;p&gt;&lt;span dir=&quot;auto&quot;&gt;&lt;span class=&quot;autocomment&quot;&gt;Time Zones&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;== Time Zones ==&lt;br /&gt;
&lt;br /&gt;
See current timezone setting:&lt;br /&gt;
 sudo zdump /etc/localtime   # /etc/localtime  Wed Mar 14 09:46:46 2012 MDT&lt;br /&gt;
 strings /etc/localtime      # MST7MDT,M3.2.0,M11.1.0  (and other garbage)&lt;br /&gt;
&lt;br /&gt;
Set timezone for all users:&lt;br /&gt;
 mv /etc/localtime /etc/localtime.original&lt;br /&gt;
 # cp /usr/share/zoneinfo/America/Boise /etc/localtime&lt;br /&gt;
 ln -sfn /usr/share/zoneinfo/America/Denver /etc/localtime&lt;br /&gt;
 ln -sfn /usr/share/zoneinfo/America/Los_Angeles /etc/localtime&lt;br /&gt;
&lt;br /&gt;
Set time zone for current user:&lt;br /&gt;
 export TZ=America/Denver&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In Linux, most timezone information is controlled by GLIBC, which relies on the file /etc/localtime. Different distributions do different things with this file; some have it as a symbolic link to the proper timezone definition file (usually in /usr/share/zoneinfo), but most have it as an actual, explicit file.&lt;br /&gt;
&lt;br /&gt;
Verifying the Timezone File [http://www.grok.lsu.edu/Article.aspx?articleId=2926]&lt;br /&gt;
&lt;br /&gt;
zdump is a small program that is part of GLIBC. It dumps the information about a given timezone file. If you want to verify what the Daylight Savings times are for a given year with a given file, you can do something like this:&lt;br /&gt;
&lt;br /&gt;
$ zdump -v /etc/localtime | grep 2007&lt;br /&gt;
&lt;br /&gt;
The -v tells zdump to display timezone information for all transitions rather than just the current date.&lt;br /&gt;
&lt;br /&gt;
date:&lt;br /&gt;
 date&lt;br /&gt;
   Sun May  2 15:49:55 MDT 2010&lt;br /&gt;
&lt;br /&gt;
Time Zone:&lt;br /&gt;
 ENVIRONMENT&lt;br /&gt;
   TZ  Specifies the timezone, unless overridden by command line parameters.&lt;br /&gt;
       If neither is specified, the setting from /etc/localtime is used.&lt;br /&gt;
&lt;br /&gt;
Time zones are kept here:&lt;br /&gt;
 /usr/share/zoneinfo/&lt;br /&gt;
&lt;br /&gt;
== NTP ==&lt;br /&gt;
&lt;br /&gt;
See [[NTP]]&lt;br /&gt;
&lt;br /&gt;
== File Time ==&lt;br /&gt;
&lt;br /&gt;
Files have access, modify and change times.&lt;br /&gt;
&lt;br /&gt;
* access time (atime): time the file was last accessed&lt;br /&gt;
* modify time (mtime): file modification times&lt;br /&gt;
* change time (ctime): status change times&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$ stat test/&lt;br /&gt;
  File: `test/&amp;#039;&lt;br /&gt;
  Size: 4096            Blocks: 8          IO Block: 4096   directory&lt;br /&gt;
Device: 900h/2304d      Inode: 20987905    Links: 2&lt;br /&gt;
Access: (0700/drwx------)  Uid: ( 1068/ kenneth)   Gid: ( 1068/ kenneth)&lt;br /&gt;
Access: 2010-09-20 11:30:01.000000000 -0600&lt;br /&gt;
Modify: 2010-09-20 11:14:45.000000000 -0600&lt;br /&gt;
Change: 2010-09-20 11:14:45.000000000 -0600&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
List file times:&lt;br /&gt;
 $ ls -lt&lt;br /&gt;
 $ ls -ltr  # reverse&lt;br /&gt;
&lt;br /&gt;
Modifiers:&lt;br /&gt;
 -t mtime - modification time&lt;br /&gt;
 -u atime - access time&lt;br /&gt;
 -c ctime - change time&lt;br /&gt;
&lt;br /&gt;
== America Time Zones ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# cat /etc/timezone&lt;br /&gt;
Etc/UTC&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Universal&lt;br /&gt;
UTC&lt;br /&gt;
Zulu&lt;br /&gt;
Etc/UTC&lt;br /&gt;
&lt;br /&gt;
US/Central&lt;br /&gt;
America/Chicago&lt;br /&gt;
&lt;br /&gt;
US/Eastern&lt;br /&gt;
America/New_York&lt;br /&gt;
&lt;br /&gt;
US/Hawaii&lt;br /&gt;
Pacific/Honolulu&lt;br /&gt;
&lt;br /&gt;
US/Mountain&lt;br /&gt;
America/Denver&lt;br /&gt;
&lt;br /&gt;
US/Pacific&lt;br /&gt;
America/Los_Angeles&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
https://en.wikipedia.org/wiki/List_of_tz_database_time_zones&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# date&lt;br /&gt;
Sat 16 Feb 15:46:56 UTC 2019&lt;br /&gt;
&lt;br /&gt;
# TZ=America/Denver date&lt;br /&gt;
Sat 16 Feb 08:47:01 MST 2019&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== keywords ==&lt;br /&gt;
&lt;br /&gt;
Linux date time timezone&lt;br /&gt;
&lt;br /&gt;
[[Category:Linux]]&lt;/div&gt;</summary>
		<author><name>Kenneth</name></author>
	</entry>
</feed>