RHEL7 CENTOS7

一、chrony

時間同步服務器,與老版本的ntp不能共存,只能使用其中的一種。

配置如下:

# systemctl mask ntpd
# yum install chrony
# systemctl start chronyd
# systemctl enable chronyd
# vi /etc/chrony.conf

Please consider joining the pool (http://www.pool.ntp.org/join.html).

server 192.168.5.1 iburst

# chronyc sources -v
210 Number of sources = 1


  .-- Source mode  '^' = server, '=' = peer, '#' = local clock.
 / .- Source state '*' = current synced, '+' = combined , '-' = not combined,
| /   '?' = unreachable, 'x' = time may be in error, '~' = time too variable.
||                                                 .- xxxx [ yyyy ] +/- zzzz
||                                                /   xxxx = adjusted offset,
||         Log2(Polling interval) -.             |    yyyy = measured offset,
||                                  \            |    zzzz = estimated error.
||                                   |           |                         
MS Name/IP address         Stratum Poll Reach LastRx Last sample
===============================================================================
^* 192.168.5.1         8   6   377     3    +10us[  +29us] +/-  104us

常用命令:

# rpm -qc chrony   檢查chrony服務配置文件所在
# timedatectl status   查看日期時間及NTP狀態
# timedatectl set-time 2015-09-22   設置日期
# timedatectl set-time 11:50:00   設置時間


二、firewalld

# systemctl mask iptables
# systemctl mask ip6tables
# systemctl mask ebptables
# systemctl start firewalld
# systemctl status firewalld
# firewall-cmd --list-all   列出防火牆的配置
# firewall-cmd --add-service=ftp --permanent   添加ftp服務




發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章