**
1.ntptrace ***.***.***.***
查詢要對時的伺服器狀態,可以trace到一級時鐘伺服器,
2.ntpq -p 或者 ntpq -pn
顯示當前時鐘伺服器狀態
3.ntpdata ***.***.***.*** 或者 ntpdata -d ***.***.***.*** (debug模式)
與時鐘伺服器對時,著先時鐘伺服器要先對時,才能用來提鍾時鐘服務
4.ntpd
既可以自動對時,又可對外提供時鐘服務,先要配置/etc/ntp.conf
5.開機對時,/etc/rc.conf中新增
ntpdate_enable="yes"
ntpdate_program="/usr/sbin/ntpdate"
ntpdate_flags="-b"
6.每天(好像是每天)對時且對外提供時鐘服務, 在/etc/rc.conf中新增
xntpd_enable="yes"
xntpd_program="/usr/sbin/ntpd"
xntpd_flags="-p /var/run/ntpd.pid"
7.埠
時鐘伺服器端口為123,udp , netstat -an
# we won't allow *anything* from hosts not listed in the configuration/etc/ntp.common.conf# this means you need a restrict line for each server
restrict default ignore
restrict -6 default ignore
# allow just about anything from localhost, ipv4.
restrict 127.0.0.1 mask 255.0.0.0
restrict 127.0.0.1
restrict -6 ::1
driftfile /var/tmp/ntp.drift
logfile /var/log/ntpd.log
# log everything, even from ntpd (which otherwise defaults to "all =sync")
logconfig =all +all
server 127.127.1.0
fudge 127.127.1.0 stratum 5
server 182.92.12.11 minpoll 6 maxpoll 10
restrict 182.92.12.11 nomodify notrap nopeer noquery
# common elements of ntp configuration/etc/ntp.conf## do not edit: changes will be lost following reboot.
# for site-specific ntp configuration, see the instructions in /etc/ntp.conf
## we won't allow *anything* from hosts not listed in the configuration
# this means you need a restrict line for each server
restrict default ignore
restrict -6 default ignore
# allow just about anything from localhost, ipv4.
restrict 127.0.0.1 mask 255.0.0.0
restrict 127.0.0.1
restrict -6 ::1
driftfile /var/tmp/ntp.drift
logfile /var/log/ntpd.log
# log everything, even from ntpd (which otherwise defaults to "all =sync")
logconfig =all +all
server 127.127.1.0
fudge 127.127.1.0 stratum 5
includefile /etc/ntp.common.conf常用的ntp伺服器:server 218.75.4.130 minpoll 6 maxpoll 10
restrict 218.75.4.130 nomodify notrap nopeer noquery
203.107.6.88
ntp.aliyun.com
ntp1.aliyun.com
ntp2.aliyun.com
ntp3.aliyun.com
ntp4.aliyun.com
ntp5.aliyun.com
ntp6.aliyun.com
ntp7.aliyun.com
ntp8.aliyun.com
簡單使用Git
1.登陸伺服器 git 伺服器位址 git xx.yy.zz.com.cn ssh p steven git xx.yy.zz.com.cn 密碼認證後 伺服器控制台下 cd mnt disk1 moblin kernel linux 2.6.29.y.git git branch 列出branch...
vector 簡單使用
vector是c 標準模板庫中的部分內容,它是乙個多功能的,能夠操作多種資料結構和演算法的模板類和函式庫。vector之所以被認為是乙個容器,是因為它能夠像容器一樣存放各種型別的物件,簡單地說,vector是乙個能夠存放任意型別的動態陣列,能夠增加和壓縮資料。為了可以使用vector,必須在你的標頭...
簡單AJAX 使用
初使化集合 floatjson soundjson messagejson if str null js解析xml function jsxml severityvalue,severityquomodo,commonvalue,commonquomodo,promptvalue,promptquo...