弄懂了SUN Solaris 9的NTP的配置

 

配置SOLARIS下的NTP服务
1、查看是否安装了NTP软件包(默认是安装的),有下面两行则是已安装
# pkginfo | grep ntp
system SUNWntpr NTP, (Root)
system SUNWntpu NTP, (Usr)

2、编辑配置文件ntp.conf
#vi /etc/inet/ntp.conf
server ip_address prefer
driftfile /var/ntp/ntp.drift
3、创建drift文件
touch /var/ntp/ntp.drift
4、停止、启动NTP服务
/etc/init.d/xntpd start
/etc/init.d/xntpd stop
5、查看服务
ps -ef|grep ntp 查看进程
snoop |grep -i ntp 查看是否存在ntp包
6、查看其他服务器时间
ntpdate -q ip_address

如果没有标准时间源,可以使用下面两个
133.100.11.8
133.100.9.2

检测时间是否同步的脚本:
while true
do date;sleep 1;done;

更改时间
date 041820472005.03;date

系统时钟和NTPserver同步
ntpdate 218.25.39.44

注意主机同步的时候二者的时间不能相差太多,否则会不成功的。

 

For solaris client

cp /etc/inet/ntp.client /etc/inet/ntp.conf

vi /etc/inet/ntp.conf and replace
multicastclient 224.0.1.1
with
server ip-of-your-winntp-server

Then restart ntp
Solaris9
/etc/init.d/xntpd stop
/etc/init.d/xntpd start

Solaris10
scvadm disable ntp
scvadm enable ntp

 

 
   

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值