1.  tzselect

[root@xxxx etc]# tzselect     --- 选择时区命令
Please identify a location so that time zone rules can be set correctly.
Please select a continent or ocean.
) Africa
) Americas
) Antarctica
) Arctic Ocean
) Asia
) Atlantic Ocean
) Australia
) Europe
) Indian Ocean
) Pacific Ocean
) none - I want to specify the time zone using the Posix TZ format.
#?
Please select a country.
) Afghanistan ) Israel ) Palestine
) Armenia ) Japan ) Philippines
) Azerbaijan ) Jordan ) Qatar
) Bahrain ) Kazakhstan ) Russia
) Bangladesh ) Korea (North) ) Saudi Arabia
) Bhutan ) Korea (South) ) Singapore
) Brunei ) Kuwait ) Sri Lanka
) Cambodia ) Kyrgyzstan ) Syria
) China ) Laos ) Taiwan
) Cyprus ) Lebanon ) Tajikistan
) East Timor ) Macau ) Thailand
) Georgia ) Malaysia ) Turkmenistan
) Hong Kong ) Mongolia ) United Arab Emirates
) India ) Myanmar (Burma) ) Uzbekistan
) Indonesia ) Nepal ) Vietnam
) Iran ) Oman ) Yemen
) Iraq ) Pakistan
#?
Please select one of the following time zone regions.
) Beijing Time
) Xinjiang Time
Please enter a number in range.
#? The following information has been given: China
Beijing Time Therefore TZ='Asia/Shanghai' will be used.
Local time is now: Thu May :: CST .
Universal Time is now: Thu May :: UTC .
Is the above information OK?
) Yes
) No

    即可重新加载 本地时间

  date  查看本地时间

  

2.    修改本地 localtime 文件

  

查看/usr/share/zoneinfo 文件夹, 发现全部为地区时间文件

故:  

rm -rf /etc/localtime
ln -s /usr/share/zoneinfo/Asia/Shanghai /etc/lcoaltime

date 查看时间, 变为上海  东八区时间

3. ntpdate & ntpd

  yum -y install ntpdate ntp

同步在线网络s

  ntpdate  xxxx

  

crontab: 没十分钟调整一次时间;

*/ * * * * ntpdate time.nist.gov   #域名或IP

  一级时间服务器列表:http://support.ntp.org/bin/view/Servers/StratumOneTimeServers

  二级时间服务器列表:http://support.ntp.org/bin/view/Servers/StratumTwoTimeServers

Linux 修改本地时间 (centos为例)的更多相关文章

  1. Linux修改本地时间

    1.Linux时间调整 1)安装ntp(目的同步时间) yum install ntp 2)修改文件 vi /etc/ntp.conf 添加 server ntp.sjtu.edu.cn perfer ...

  2. linux修改系统时间为北京时间(CentOS)

    删除本地时间 rm -rf /etc/localtime 设置时区为上海 ln -s /usr/share/zoneinfo/Asia/Shanghai /etc/localtime 利用date查看 ...

  3. Linux的本地时间和网络时间同步

    Linux本地时间和网络时间不同步,更新了之后,重启还会变回去.可以通过一下方法修改并保存. 1.  安装ntpdate工具 sudo apt-get install ntpdate 2.  设置系统 ...

  4. linux 修改系统时间

    首先进入/proc/sys/xen,执行以下命令 [root@test]#cd   /proc/sys/xen[root@test]#echo 1 > independent_wallclock ...

  5. linux修改系统时间date命令加clock -w

    http://m.jb51.net/LINUXjishu/117784.html 修改linux系统时间的方法(date命令) 11-18 23:22:27作者:脚本之家 命令格式为: date -s ...

  6. Linux修改系统时间与时区

    GMT  (Greewich Mean Time) 格林威治标准时间:GMT是老的时间计量标准,根据地球的自转和公转来计算时间,也就是太阳每天经过位于英国伦敦郊区的皇家格林尼治天文台的标准时间就是中午 ...

  7. linux修改系统时间和时区

    1.修改系统时间linux系统时钟有两个,一个是硬件时钟,即BIOS时间,就是我们进行CMOS设置时看到的时间,另一个是系统时钟,是linux系统Kernel时间.当Linux启动时,系统Kernel ...

  8. Linux修改系统时间为东八区北京时间(上海时间)

    1. Linux时间   Linux的时间分为 System Clock(系统时间)和 Real Time Clock(硬件时间,简称RTC).   系统时间:指系统内核中的时间.   硬件时间:指主 ...

  9. linux修改系统时间和linux查看时区、修改时区的方法

    一.查看和修改Linux的时区 1. 查看当前时区命令 : "date -R" 2. 修改设置Linux服务器时区方法 A命令 : "tzselect" 方法 ...

随机推荐

  1. Spring Boot 系列总目录

    一.Spring Boot 系列诞生原因 上学那会主要学的是 Java 和 .Net 两种语言,当时对于语言分类这事儿没什么概念,恰好在2009年毕业那会阴差阳错的先找到了 .Net 的工作,此后就开 ...

  2. .net -笔记 简单的操作符重载

    这个操作符重载很有意思 class Program { static void Main(string[] args) { Person person1 = new Person() { Name = ...

  3. finereport报表--动态格间运算 二

    报表输出

  4. git操作+一个本地项目推到github上+注意

    git init 创建新文件夹,打开,然后执行以创建新的 git 仓库. git config --global user.name "xxx" git config --glob ...

  5. SVN上传的时候没法显示文件名,只显示后缀名

    之前在用SVN上传android代码的时候,发现上传列表上的文件没法显示名字,只显示了后缀名,就像这样: 各种疑惑,最终发现解决方法: 右键单击操作栏的status: 然后在出现的选项里面将filen ...

  6. Android获取定位权限,获取设备所在的经纬度

    转载请标明出处:http://www.cnblogs.com/tangZH/p/8969898.html  前言: 有时候我们仅仅是想要获取设备所在的经纬度,那么直接调用Android相关的api就可 ...

  7. 从Linux上传到Git过程

    1.1 实验内容 本次课程讲的是在实验楼的在线环境中,如何使用 Github 去管理在在线环境中使用的代码.配置.资源等实验相关文件,怎样去添加.同步和下拉在远程仓库中的实验文件,以此来维持自身的实验 ...

  8. 【温故而知新】HTTP 报文

    HTTP 报文是在 HTTP 应用程序之间发送的数据块.这些数据块以一些文本形式的元信息开头,这些信息描述了报文的内容及含义. 报文流 报文在客户端.服务器和代理之间的流动称为报文流. HTTP 使用 ...

  9. 关于在Python2中使用列表推导式会遇到的问题

    摘自<流畅的Python>第二部分第二章2.2 Python 2.x 中,在列表推导中 for 关键词之后的赋值操作可能会影响列表推导上下文中的同名变量.像下面这个 Python 2.7 ...

  10. Powershell-获取命令和帮助

    Get-Help 获取命令的帮助文档 Update -Help 更新帮助文档 Save-Help 保存文档 Get-Help Get-VM 加上-Full参数获取详细说明 [-name] <st ...