三、Keyston-认证服务
3.1 Keyston介绍
补充
3.2 安装时间同步器
----------------------------------------------------使用chrony安装-------------------------------------------------
####所有节点
#下载安装chrony
yum -y install chrony
#修改配置文件/etc/chrony.conf
vim /etc/chrony.conf
#修改第三行
server time1.aliyun.com iburst##只在controller节点配置,其他节点引用控制节点
#修改allow
allow 10.0.0.0/24 #其他节点配置通用网段
#启动并加入开机自启
systemctl enable chronyd.service
systemctl start chronyd.service
ntp时间同步器介绍可以不看
-------------------------------------------------------------NTP操作可以不用----------------------------------------------------
yum -y install ntp
vim /etc/ntp.conf
修改成自己的IP网段或者指定ip
16 # Hosts on local network are less restricted.
17 restrict 192.168.8.0 mask 255.255.255.0 nomodify notrap
18
注释掉公网时间服务器
19 # Use public servers from the pool.ntp.org project.
20 # Please consider joining the pool (http://www.pool.ntp.org/join.html).
21 #server 0.centos.pool.ntp.org iburst
22 #server 1.centos.pool.ntp.org iburst
23 #server 2.centos.pool.ntp.org iburst
24 #server 3.centos.pool.ntp.org iburst
添加:
server 127.127.1.0
fudge 127.127.1.0 stratum 10
表示:当外部时间不可用时(指公网网络时间),以本地(本机)时间作为服务时间
本地时间以 127.127.1.0 表示 级别为10
systemctl start ntpd
systemctl enable ntpd
ntp 检测拓展可以不看
[root@controller ~]# ntpstat
synchronised to local net (127.127.1.0) at stratum 11
time correct to within 7948 ms
polling server every 64 s
[root@controller ~]# ntptrace -n 127.0.0.1
bash: ntptrace: command not found...
[root@controller ~]# ntpq -p
remote refid st t when poll reach delay offset jitter
==============================