2015년 3월 27일 금요일

How to kill screen

List screens:
screen -list
Output:
There is a screen on:
23536.pts-0.wdzee       (10/04/2012 08:40:45 AM)        (Detached)
1 Socket in /var/run/screen/S-root.
Kill screen session:
screen -S 23536 -X quit

reference link:



2015년 3월 26일 목요일

How to mount qcow2 images

1. install qemu-utils and enable nbd module

sudo apt-get install qemu-utils
sudo modprobe nbd

2. use any qcow2 image

3. connect the image to the first nbd device

sudo qemu-nbd -c /dev/nbd0 xxx.img

4. Mount the image

sudo mount /dev/nbd0p1 /mnt

5. unmount
sudo umount /mnt

6. disconnect the loopback device
sudo qemu-nbd -d /dev/nbd0


2015년 3월 23일 월요일

hostname 변경하기

1. hostname 명령을 사용해 현재 값 확인

2. /etc/hostname의 값을 변경

3. hostname -F /etc/hostname

4. 새로운 터미널을 열어 확인

2015년 3월 21일 토요일

Install Eclipse on Ubuntu

1. download Eclipse
http://www.eclipse.org/downloads/

2. extract download file
$ tar xvfz eclipse-java-luna-SR2-linux-gtk-x86_64.tar.gz

3. move the "eclipse" entire directory to /opt/
  $ sudo mv ~/down/eclipse /opt/

4. make a script for eclipse
  $sudo vi /usr/bin/eclipse
  input followings into the script file
  
    #!/bin/sh
    export ECLIPSE_HOME=/opt/eclipse
    $ECLIPSE_HOME/eclipse $*
5. change permission to execute
  $ sudo chmod 755 /usr/bin/eclipse

6. run eclipse
  $ eclipse

2015년 3월 20일 금요일

putty + Xming 설정

1. Xming 설치 하면서 디폴트 따라가다가 아래화면에서
select "Multiple windows"


2. select "Start no client"

3.

4.  if needed, save configuration

5. putty  또는 kitty  로 리눅스 접속시 SSH >  X11 메뉴에서 아래 그림과 같이 "Enable X11 forwarding" 에  체크, 

X display location 에 localhost:0  입력하고 저장후 접속하면 된다.

6. putty 에서 xterm 등을 실행해서 잘 되는지 확인하면 된다.

7. Xming 에 실행한 프로그램 폰트를 키우고 싶다면
Xming.exe:0 -clipboard -multiwindow -dpi 96 -ac -lesspointer




WSGI 설명

WSGI 는 server 도 아니고, python moduel 도 아니고, fraemwork 도 아니고, API 나 어떤 종류의 소프트웨어도 아니다.
단지 서버와 어플리케이션이 서로 통신하는 방법에 대한 인터페이스 specification 이다.
따라서 서버와 어플리케이션은 둘 다 서로에 대한 인터페이스가 기술되어 있고 이런 내용은 PEP 3333 에 있다.
만약 어플리케이션 또는 프레임웍이 WSGI spec 에 따라 구현되었다면, 이것은 이 spec 에 따라 구현된 어떤 서버에서도 실행된다.

2015년 3월 19일 목요일

How to install Trove(Juno) using devstack and redstack

1. Install Trove Juno version using devstack and redstack
 : overall install using devstack and use redstack to build and register guest image for trove

2. Ubuntu upgrade
2.1 change package repository
if needed, change as follows

$ sudo sed -i s/kr.archive.ubuntu.com/ftp.jaist.ac.jp/g /etc/apt/sources.list

2.2 Ubuntu upgrade
rebooting may be needed

$ sudo apt-get update

$ sudo apt-get upgrade

$ sudo shutdown -ry 0

3. proxy 환경 설정
3. configuration for proxy
If you are using proxy server,
download your proxy certificate and copy it to following directory

/usr/share/ca-certificates/extra/xxx.crt

after copying and register the certificate as follows:

$ sudo dpkg-reconfigure ca-certificates (yes, select xxx.crt)

Edit /etc/environment as follows for using proxy

$ sudo vi /etc/environment
...
http_proxy="http://a.b.c.d:8080/"
https_proxy="https://a.b.c.d:8080/"
no_proxy="localhost,127.0.0.1,127.0.0.0/8,127.0.1.1,10.0.0.0/8"

4. Install devstack
* If you have ever installed devstack, it would be better to cleanup devstack related files.

$ ./unstack.sh
$ ./clean.sh
$ sudo rm -rf /opt/stack

4.1 git, pip install/config

$ sudo apt-get install git python-pip
$ sudo vi ~/.pip/pip.conf

[global]
cert = /usr/share/ca-certificates/extra/xxx.crt

4.2 devstack download

$ git clone http://github.com/openstack-dev/devstack
$ cd ~/devstack
$ git checkout stable/juno

4.3 Edit local.conf 

[[local|localrc]]

# Credentials
DATABASE_PASSWORD=openstack
ADMIN_PASSWORD=openstack
SERVICE_PASSWORD=openstack
SERVICE_TOKEN=openstack
RABBIT_PASSWORD=openstack

# Services
ENABLED_SERVICES=rabbit,mysql,key
ENABLED_SERVICES+=,n-api,n-crt,n-obj,n-cpu,n-cond,n-sch,n-novnc,n-cauth
ENABLED_SERVICES+=,n-net
#ENABLED_SERVICES+=,neutron,q-svc,q-agt,q-dhcp,q-l3,q-meta,q-lbaas
#ENABLED_SERVICES+=,q-svc,q-agt,q-dhcp,q-l3,q-meta,q-lbaas
ENABLED_SERVICES+=,s-proxy,s-object,s-container,s-account
ENABLED_SERVICES+=,g-api,g-reg
ENABLED_SERVICES+=,cinder,c-api,c-vol,c-sch,c-bak
ENABLED_SERVICES+=,heat,h-api,h-api-cfn,h-api-cw,h-eng
ENABLED_SERVICES+=,trove,tr-api,tr-tmgr,tr-cond
ENABLED_SERVICES+=,horizon

# Images
# Use this image when creating test instances
#IMAGE_URLS+=",http://cdn.download.cirros-cloud.net/0.3.2/cirros-0.3.2-x86_64-disk.img"
# Use this image when working with Orchestration (Heat)
#IMAGE_URLS+=",http://fedorapeople.org/groups/heat/prebuilt-jeos-images/F17-x86_64-cfntools.qcow2"
#IMAGE_URLS+=",http://download.fedoraproject.org/pub/fedora/linux/releases/21/Cloud/Images/x86_64/Fedora-Cloud-Base-20141203-21.x86_64.qcow2"

# Branches
KEYSTONE_BRANCH=stable/juno
NOVA_BRANCH=stable/juno
NEUTRON_BRANCH=stable/juno
SWIFT_BRANCH=stable/juno
GLANCE_BRANCH=stable/juno
CINDER_BRANCH=stable/juno
HEAT_BRANCH=stable/juno
TROVE_BRANCH=stable/juno
HORIZON_BRANCH=stable/juno

# Swift Configuration
SWIFT_REPLICAS=1
SWIFT_HASH=66a3d6b56c1f479c8b4e70ab5c2000f5

#[[post-config|$GLANCE_API_CONF]]
#[DEFAULT]
#default_store=file

# Enable Logging
LOGFILE=/opt/stack/logs/stack.sh.log
VERBOSE=True
LOG_COLOR=True
SCREEN_LOGDIR=/opt/stack/logs

4.4 Run stack.sh
$ ./stack.sh

Check whether each service is running properly using "screen -x stack"
You can access Horizon through web browser and test openstack

5. Install redstack
5.1 clone trove-integration

$ git clone https://github.com/openstack/trove-integration.git
$ cd trove-integration/scripts/

change strange passwords to "openstack" in "redstack.rc"
confirm that passwords in ~/devstck/local.conf are already same
(Do NOT run "redstack install")
$./redstack kick-start mysql

or
./redstack test-init
./redstack build-image mysql
./redstack kick-start mysql

5.2 Using postgresql
./redstack kick-start postgresql
or

./redstack build-image postgresql
./redstack kick-start postgresql

6. Trove test
Try to create DB instance using horizon or console


* Troubleshooting

1) Error occurred when redstack build-image mysql

+ mkdir -p /home/ubuntu/.gnupg
+ apt-key adv --keyserver hkp://keys.gnupg.net --recv-keys 1C4CBDCDCD2EFD2A
Executing: gpg --ignore-time-conflict --no-options --no-default-keyring --secret-keyring /tmp/tmp.mcS9MWYPD8 --trustdb-name /etc/apt/trustdb.gpg --keyring /etc/apt/trusted.gpg --primary-keyring /etc/apt/trusted.gpg --keyserver hkp://keys.gnupg.net --recv-keys 1C4CBDCDCD2EFD2A
gpg: requesting key CD2EFD2A from hkp server keys.gnupg.net
gpg: keyserver timed out
gpg: keyserver receive failed: keyserver error
++ check_break after-error run_in_target bash
++ echo ''
++ egrep -e '(,|^)after-error(,|$)' -q
+ trap_cleanup
+ exitval=2
+ cleanup
+ unmount_image
+ sync
+ unmount_dir /tmp/image.37GDumKD/mnt
+ local pattern=/tmp/image.37GDumKD/mnt mnts=
+ '[' -n /tmp/image.37GDumKD/mnt ']'
++ awk '{print $2}'
++ sort -r
++ grep '^/tmp/image.37GDumKD/mnt'
+ mnts='/tmp/image.37GDumKD/mnt/var/cache/apt/archives
/tmp/image.37GDumKD/mnt/tmp/in_target.d
/tmp/image.37GDumKD/mnt/tmp/ccache
/tmp/image.37GDumKD/mnt/sys
/tmp/image.37GDumKD/mnt/proc
/tmp/image.37GDumKD/mnt/dev/pts
/tmp/image.37GDumKD/mnt/dev'
+ '[' -n '/tmp/image.37GDumKD/mnt/var/cache/apt/archives
/tmp/image.37GDumKD/mnt/tmp/in_target.d
/tmp/image.37GDumKD/mnt/tmp/ccache
/tmp/image.37GDumKD/mnt/sys
/tmp/image.37GDumKD/mnt/proc
/tmp/image.37GDumKD/mnt/dev/pts
/tmp/image.37GDumKD/mnt/dev' ']'
+ sudo umount -fl /tmp/image.37GDumKD/mnt/var/cache/apt/archives /tmp/image.37GDumKD/mnt/tmp/in_target.d /tmp/image.37GDumKD/mnt/tmp/ccache /tmp/image.37GDumKD/mnt/sys /tmp/image.37GDumKD/mnt/proc /tmp/image.37GDumKD/mnt/dev/pts /tmp/image.37GDumKD/mnt/dev
+ '[' -n '' ']'
+ cleanup_dirs
+ sudo rm -rf /tmp/image.37GDumKD/built
+ sudo rm -rf /tmp/image.37GDumKD/mnt
+ sudo umount -f /tmp/image.37GDumKD /tmp/image.N9h32DDz
+ rm -rf --one-file-system /tmp/image.37GDumKD /tmp/image.N9h32DDz
+ exit 2

-> refer to following link
http://unix.stackexchange.com/questions/138517/debian-gpg-cannot-fetch-linux-kernel-key
-> It seems that hkp port 11371 is blocked.
-> Due to googling, it could be resolved using 80 port.
-> grep -R "keys.gnupg.net" ~/trove-integration/scripts and in the result files, specify 80 port
-> When retrying, following error maybe occurs, but continue to retry, finally resolved.
+ apt-key adv --keyserver hkp://keys.gnupg.net:80 --recv-keys 1C4CBDCDCD2EFD2A
Executing: gpg --ignore-time-conflict --no-options --no-default-keyring --secret-keyring /tmp/tmp.nMgJNOMIVX --trustdb-name /etc/apt/trustdb.gpg --keyring /etc/apt/trusted.gpg --primary-keyring /etc/apt/trusted.gpg --keyserver hkp://keys.gnupg.net:80 --recv-keys 1C4CBDCDCD2EFD2A
gpg: requesting key CD2EFD2A from hkp server keys.gnupg.net
gpgkeys: key 1C4CBDCDCD2EFD2A not found on keyserver
gpg: no valid OpenPGP data found.
gpg: Total number processed: 0

2) Error occurred when creating DB instance
ERROR trove.instance.models [-] An error occurred communicating with the guest: Timeout while waiting on RPC response - topic: "guestagent.8024bcd5-3192-40eb-8d60-249767338375", RPC method: "get_filesystem_stats" info: "<unknown>".

-> DB 인스턴스가 생성되는 VM 에 trove-guestagent 데몬에 에러가 발생한 경우이므로, 직접 VM 에 접속해서 아래 명령어를 실행해서 소스 레벨에서 원인 파악한다.

/usr/bin/python /home/ubuntu/trove/contrib/trove-guestagent --config-file=/etc/guest_info --config-file=/etc/trove/trove-guestagent.conf

2015년 3월 9일 월요일

Ubuntu 14.04 에 devstack 으로 Trove Juno 버전 설치하기

1. Ubuntu 14.04 에 devstack 으로 Trove Juno 버전 설치하기
: 전체적으로 devstack 으로 설치하고, trove 위한 guest image 만 redstack 이용

2. Ubuntu upgrade
2.1 package repository 변경
필요시 아래와 같이 변경

$ sudo sed -i s/kr.archive.ubuntu.com/ftp.jaist.ac.jp/g /etc/apt/sources.list

2.2 Ubuntu upgrade
최신 패키지로 업그레이드함
필요시 재부팅

$ sudo apt-get update

$ sudo apt-get upgrade

$ sudo shutdown -ry 0

3. proxy 환경 설정
사내 등에서 proxy 서버가 있는 환경인 경우 proxy 인증서(xxx.crt) 를 다운받아서 아래 위치에 복사함
/usr/share/ca-certificates/extra/xxx.crt
인증서 복사 후 아래 명령어로 인증서를 시스템에 등록함

$ sudo dpkg-reconfigure ca-certificates (yes, xxx.crt 선택)

Proxy 세팅을 위해 /etc/environment 파일에 아래 내용을 추가합니다. Virtual box 는 10.0.0.0/8 subnet 을 기본으로 사용함

$ sudo vi /etc/environment
...
http_proxy="http://a.b.c.d:8080/"
https_proxy="https://a.b.c.d:8080/"
no_proxy="localhost,127.0.0.1,127.0.0.0/8,127.0.1.1,10.0.0.0/8"

4. devstack 설치
* 이전에 설치한 흔적이 있는 경우 아래 순서로 깔끔하게 지운 상태에서 하는 것이 좋다.

$ ./unstack.sh
$ ./clean.sh
$ sudo rm -rf /opt/stack

4.1 git, pip 설치/설정
Python Package 관리 도구인 PIP 와 형상관리도구 Git 을 설치합니다.

ubuntu@ubuntu:~$ sudo apt-get install git python-pip
ubuntu@ubuntu:~$ sudo vi ~/.pip/pip.conf

[global]
cert = /usr/share/ca-certificates/extra/xxx.crt

4.2 devstack download
$ git clone http://github.com/openstack-dev/devstack
$ cd ~/devstack
$ git checkout stable/juno

4.3 local.conf 편집

[[local|localrc]]

# Credentials
DATABASE_PASSWORD=openstack
ADMIN_PASSWORD=openstack
SERVICE_PASSWORD=openstack
SERVICE_TOKEN=openstack
RABBIT_PASSWORD=openstack

# Services
ENABLED_SERVICES=rabbit,mysql,key
ENABLED_SERVICES+=,n-api,n-crt,n-obj,n-cpu,n-cond,n-sch,n-novnc,n-cauth
ENABLED_SERVICES+=,n-net
#ENABLED_SERVICES+=,neutron,q-svc,q-agt,q-dhcp,q-l3,q-meta,q-lbaas
#ENABLED_SERVICES+=,q-svc,q-agt,q-dhcp,q-l3,q-meta,q-lbaas
ENABLED_SERVICES+=,s-proxy,s-object,s-container,s-account
ENABLED_SERVICES+=,g-api,g-reg
ENABLED_SERVICES+=,cinder,c-api,c-vol,c-sch,c-bak
ENABLED_SERVICES+=,heat,h-api,h-api-cfn,h-api-cw,h-eng
ENABLED_SERVICES+=,trove,tr-api,tr-tmgr,tr-cond
ENABLED_SERVICES+=,horizon

# Images
# Use this image when creating test instances
#IMAGE_URLS+=",http://cdn.download.cirros-cloud.net/0.3.2/cirros-0.3.2-x86_64-disk.img"
# Use this image when working with Orchestration (Heat)
#IMAGE_URLS+=",http://fedorapeople.org/groups/heat/prebuilt-jeos-images/F17-x86_64-cfntools.qcow2"
#IMAGE_URLS+=",http://download.fedoraproject.org/pub/fedora/linux/releases/21/Cloud/Images/x86_64/Fedora-Cloud-Base-20141203-21.x86_64.qcow2"

# Branches
KEYSTONE_BRANCH=stable/juno
NOVA_BRANCH=stable/juno
NEUTRON_BRANCH=stable/juno
SWIFT_BRANCH=stable/juno
GLANCE_BRANCH=stable/juno
CINDER_BRANCH=stable/juno
HEAT_BRANCH=stable/juno
TROVE_BRANCH=stable/juno
HORIZON_BRANCH=stable/juno

# Swift Configuration
SWIFT_REPLICAS=1
SWIFT_HASH=66a3d6b56c1f479c8b4e70ab5c2000f5

#[[post-config|$GLANCE_API_CONF]]
#[DEFAULT]
#default_store=file

# Enable Logging
LOGFILE=/opt/stack/logs/stack.sh.log
VERBOSE=True
LOG_COLOR=True
SCREEN_LOGDIR=/opt/stack/logs

4.4 stack.sh 실행
ubuntu@ubuntu:~/devstack$ ./stack.sh

screen -x stack 을 통해 각 데몬들이 정상인지 확인
웹브라우저를 통해 Horizon 에 접속해서 테스트 가능

5. redstack 설치
5.1 Git 으로 trove-integration 받음
$ git clone https://github.com/openstack/trove-integration.git
$ cd trove-integration/scripts/

redstack.rc 에 있는 이상한 password 를 openstack 으로 수정
~/devstack/local.conf 도 동일한 password 로 이미 했음을 확인한다.
(redstack install 은 절대 하지 않는다)
./redstack kick-start mysql
or
./redstack test-init
./redstack build-image mysql
./redstack kick-start mysql

5.2 postgresql 사용
./redstack kick-start postgresql
or
에러 발생시
./redstack build-image postgresql
./redstack kick-start postgresql

6. Trove test
horizon 또는 console 로 db instance 생성해본다.


* Troubleshooting

1) redstack build-image mysql 시에 다음 에러 발생

+ mkdir -p /home/ubuntu/.gnupg
+ apt-key adv --keyserver hkp://keys.gnupg.net --recv-keys 1C4CBDCDCD2EFD2A
Executing: gpg --ignore-time-conflict --no-options --no-default-keyring --secret-keyring /tmp/tmp.mcS9MWYPD8 --trustdb-name /etc/apt/trustdb.gpg --keyring /etc/apt/trusted.gpg --primary-keyring /etc/apt/trusted.gpg --keyserver hkp://keys.gnupg.net --recv-keys 1C4CBDCDCD2EFD2A
gpg: requesting key CD2EFD2A from hkp server keys.gnupg.net
gpg: keyserver timed out
gpg: keyserver receive failed: keyserver error
++ check_break after-error run_in_target bash
++ echo ''
++ egrep -e '(,|^)after-error(,|$)' -q
+ trap_cleanup
+ exitval=2
+ cleanup
+ unmount_image
+ sync
+ unmount_dir /tmp/image.37GDumKD/mnt
+ local pattern=/tmp/image.37GDumKD/mnt mnts=
+ '[' -n /tmp/image.37GDumKD/mnt ']'
++ awk '{print $2}'
++ sort -r
++ grep '^/tmp/image.37GDumKD/mnt'
+ mnts='/tmp/image.37GDumKD/mnt/var/cache/apt/archives
/tmp/image.37GDumKD/mnt/tmp/in_target.d
/tmp/image.37GDumKD/mnt/tmp/ccache
/tmp/image.37GDumKD/mnt/sys
/tmp/image.37GDumKD/mnt/proc
/tmp/image.37GDumKD/mnt/dev/pts
/tmp/image.37GDumKD/mnt/dev'
+ '[' -n '/tmp/image.37GDumKD/mnt/var/cache/apt/archives
/tmp/image.37GDumKD/mnt/tmp/in_target.d
/tmp/image.37GDumKD/mnt/tmp/ccache
/tmp/image.37GDumKD/mnt/sys
/tmp/image.37GDumKD/mnt/proc
/tmp/image.37GDumKD/mnt/dev/pts
/tmp/image.37GDumKD/mnt/dev' ']'
+ sudo umount -fl /tmp/image.37GDumKD/mnt/var/cache/apt/archives /tmp/image.37GDumKD/mnt/tmp/in_target.d /tmp/image.37GDumKD/mnt/tmp/ccache /tmp/image.37GDumKD/mnt/sys /tmp/image.37GDumKD/mnt/proc /tmp/image.37GDumKD/mnt/dev/pts /tmp/image.37GDumKD/mnt/dev
+ '[' -n '' ']'
+ cleanup_dirs
+ sudo rm -rf /tmp/image.37GDumKD/built
+ sudo rm -rf /tmp/image.37GDumKD/mnt
+ sudo umount -f /tmp/image.37GDumKD /tmp/image.N9h32DDz
+ rm -rf --one-file-system /tmp/image.37GDumKD /tmp/image.N9h32DDz
+ exit 2

-> 아래 링크 참고
http://unix.stackexchange.com/questions/138517/debian-gpg-cannot-fetch-linux-kernel-key
-> VM 에서 hkp 포트인 11371 인 막혀서 발생하는 문제로 추정
-> 검색하면 80 포트로 하는 방법이 있다고 함
-> grep -R "keys.gnupg.net" ~/trove-integration/scripts 해서 나오는 파일에서 80 포트로 명시해줌
-> 재시도 시 아래와 같은 에러가 일시적으로 발생할 수 있으나 계속 재시도 하면 넘어감
+ apt-key adv --keyserver hkp://keys.gnupg.net:80 --recv-keys 1C4CBDCDCD2EFD2A
Executing: gpg --ignore-time-conflict --no-options --no-default-keyring --secret-keyring /tmp/tmp.nMgJNOMIVX --trustdb-name /etc/apt/trustdb.gpg --keyring /etc/apt/trusted.gpg --primary-keyring /etc/apt/trusted.gpg --keyserver hkp://keys.gnupg.net:80 --recv-keys 1C4CBDCDCD2EFD2A
gpg: requesting key CD2EFD2A from hkp server keys.gnupg.net
gpgkeys: key 1C4CBDCDCD2EFD2A not found on keyserver
gpg: no valid OpenPGP data found.
gpg: Total number processed: 0

2) DB 인스턴스 생성 시 아래와 같은 에러가 발생하는 경우 
ERROR trove.instance.models [-] An error occurred communicating with the guest: Timeout while waiting on RPC response - topic: "guestagent.8024bcd5-3192-40eb-8d60-249767338375", RPC method: "get_filesystem_stats" info: "<unknown>".

-> DB 인스턴스가 생성되는 VM 에 trove-guestagent 데몬에 에러가 발생한 경우이므로, 직접 VM 에 접속해서 아래 명령어를 실행해서 소스 레벨에서 원인 파악한다.
/usr/bin/python /home/ubuntu/trove/contrib/trove-guestagent --config-file=/etc/guest_info --config-file=/etc/trove/trove-guestagent.conf

7. Trove cluster 기능 테스트
$ trove cluster-create products mongodb "2.6" \ --instance flavor_id=7,volume=2 --instance flavor_id=7,volume=2 --instance flavor_id=7,volume=2

2015년 3월 7일 토요일

KT 홈허브 와이피이 속도 증가 시키기

아래 링크 대로 해보니 속도가 증가하는 것 같음

http://blog.daum.net/comet1983/7628741


2015년 3월 4일 수요일

Ubuntu 12.04 에서 14.04 로 업그레이드 하기

아래 링크 참조
https://www.linode.com/docs/security/upgrading/how-to-upgrade-to-ubuntu-14-04-lts

필요시 아래와 같이 변경하고 시작
sudo sed -i s/xxx.clouds.archive.ubuntu.com/ftp.jaist.ac.jp/g /etc/apt/sources.list

Ubuntu, CentOS 에서 timezone 변경

date
타임존 확인
more /etc/timezone
타임존이 원하는 타임존이 아니라면, 아래 명령어로 타임존 변경
sudo dpkg-reconfigure tzdata
인터렉티브 화면이 나오면, 원하는 대륙과 도시를 선택하시면 됨

* CentOS 6
cp /etc/localtime /root/old.timezone
rm /etc/localtime
ln -s /usr/share/zoneinfo/America/Chicago /etc/localtime

확인
date
ls -l /etc/localtime