Last active
December 21, 2015 07:46
-
-
Save azusanakano/9963930 to your computer and use it in GitHub Desktop.
【Linux】タイムゾーン(Timezone)の変更 ref: http://qiita.com/azusanakano/items/b39bd22504313884a7c3
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
UTC=false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# date | |
Thu May 31 16:25:06 UTC 2012 | |
# strings /etc/localtime | |
TZif2 | |
TZif2 | |
UTC0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### オリジナルをバックアップ | |
cp /etc/localtime /etc/localtime.org | |
### タイムゾーンファイルの変更 | |
ln -sf /usr/share/zoneinfo/Asia/Tokyo /etc/localtime |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# 一応、バックアップを取ります | |
cp /etc/sysconfig/clock /etc/sysconfig/clock.org |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
UTC=true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
UTC=false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### 確認 | |
# strings /etc/localtime | |
TZif2 | |
TZif2 | |
JST-9 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### 確認 | |
strings /etc/localtime | |
TZif2 | |
TZif2 | |
JST-9 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
date | |
Fri Jun 1 01:27:56 JST 2012 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# 一応、バックアップを取ります | |
cp /etc/sysconfig/clock /etc/sysconfig/clock.org | |
# viなどで編集してもよし | |
echo -e 'ZONE="Asia/Tokyo"\nUTC=false' > /etc/sysconfig/clock | |
# 一応、バックアップを取ります | |
cp /etc/localtime /etc/localtime.org | |
# timezoneファイル差し替え | |
ln -sf /usr/share/zoneinfo/Asia/Tokyo /etc/localtime |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# 変更前、表示 | |
date | |
strings /etc/localtime | |
# 一応、バックアップを取ります | |
cp /etc/sysconfig/clock /etc/sysconfig/clock.org | |
# viなどで編集してもよし | |
echo -e 'ZONE="Asia/Tokyo"\nUTC=false' > /etc/sysconfig/clock | |
# 一応、バックアップを取ります | |
cp /etc/localtime /etc/localtime.org | |
# timezoneファイル差し替え | |
ln -sf /usr/share/zoneinfo/Asia/Tokyo /etc/localtime | |
# 変更後、表示 | |
date | |
strings /etc/localtime |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment