国产一级a片免费看高清,亚洲熟女中文字幕在线视频,黄三级高清在线播放,免费黄色视频在线看

打開(kāi)APP
userphoto
未登錄

開(kāi)通VIP,暢享免費(fèi)電子書(shū)等14項(xiàng)超值服

開(kāi)通VIP
Debian/Ubuntu 時(shí)區(qū)和自動(dòng)校時(shí)設(shè)置

Debian/Ubuntu 時(shí)區(qū)和自動(dòng)校時(shí)設(shè)置

NTP 是通過(guò)網(wǎng)絡(luò)自動(dòng)校時(shí)的一種 TCP/IP 協(xié)議。Debian/Ubuntu 中有兩種方式實(shí)現(xiàn)時(shí)間同步:ntpdate 和 ntpd,前者為一天調(diào)整一次時(shí)間,后者 ntpd 為守護(hù)進(jìn)程,可以持續(xù)不斷地調(diào)整時(shí)間。個(gè)人推薦使用 ntpd,它實(shí)際占用資源是很小的。

一、設(shè)置服務(wù)器時(shí)區(qū)

如果是美國(guó)VPS,那么時(shí)區(qū)要首先設(shè)置,不然哪怕再精準(zhǔn)的時(shí)間也是白搭。我一般使用 tzconfig 或 tzselect 工具來(lái)設(shè)置時(shí)區(qū)。

1
tzselect
123
cat >>~/.profile<<EOFTZ='Asia/Shanghai'; export TZEOF
12
rm -rf /etc/localtimecp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime

二、設(shè)置時(shí)間同步服務(wù)器

方法一:ntpdate 方式

12345
apt-get install -y ntpdate #安裝vim /etc/cron.daily/ntpdate #添加下面一行,每天同步。ntpdate ntp.ubuntu.com cn.pool.ntp.orgchmod 755 /etc/cron.daily/ntpdate #修改權(quán)限ntpdate -d cn.pool.ntp.org #立即同步時(shí)間

方法二:ntpd 方式

1234
apt-get install -y ntpd #安裝vim /etc/ntp.conf #添加下面一行server cn.pool.ntp.org/etc/init.d/ntp restart #重啟

以下適用于 debian

1234567
apt-get install -y ntpvim /etc/ntp.conf #修改為下面幾行server 0.debian.pool.ntp.org iburst dynamicserver 1.debian.pool.ntp.org iburst dynamicserver 2.debian.pool.ntp.org iburst dynamicserver 3.debian.pool.ntp.org iburst dynamic/etc/init.d/ntp restart #重啟

參考資料:

1. http://people.ubuntu.com/~happyaron/ubuntu-docs-test/lucid/serverguide/zh_CN/NTP.html
2. http://www.cyberciti.biz/faq/debian-ubuntu-linux-install-ntpd/
3. http://e-boy.cn/artical/view/84303/

本站僅提供存儲(chǔ)服務(wù),所有內(nèi)容均由用戶發(fā)布,如發(fā)現(xiàn)有害或侵權(quán)內(nèi)容,請(qǐng)點(diǎn)擊舉報(bào)
打開(kāi)APP,閱讀全文并永久保存 查看更多類似文章
猜你喜歡
類似文章
大數(shù)據(jù)技術(shù)學(xué)習(xí)分享:Hadoop集群同步
linux同步時(shí)間的三種方法
centos7配置NTP時(shí)間服務(wù)器
Linux的NTP配置總結(jié)
網(wǎng)絡(luò)時(shí)間服務(wù)和chrony
ntpd時(shí)鐘同步服務(wù)
更多類似文章 >>
生活服務(wù)
分享 收藏 導(dǎo)長(zhǎng)圖 關(guān)注 下載文章
綁定賬號(hào)成功
后續(xù)可登錄賬號(hào)暢享VIP特權(quán)!
如果VIP功能使用有故障,
可點(diǎn)擊這里聯(lián)系客服!

聯(lián)系客服