When configuring multiple servers, you often need to synchronize the time between each server. if the server has an Internet environment, you can directly update the time at the same time as the external server. you can use the rdate command to update the time: rdate-s & #65279; tick.greyware.com can write a script to put it in/etc/cron. in hourly, time is corrected every hour. In an intranet environment, you can configure a time server by yourself. when you configure multiple servers using CentOS as an example, you often need to synchronize the time between servers. if the server has an Internet environment, the update time can be directly the same as the external time server. you can use the rdate command to update the time:
- Rdate-s required tick.greyware.com
You can write a script and place it in/etc/cron. hourly to correct the time every hour. In an intranet environment, you can configure a time server by yourself. for example, you can use CentOS to configure the time server as follows: 1. install xinetd first.
- Yum install-y xinetd rdate
2. modify/etc/xinetd. d/time-stream and change disable = yes to disable = no 3. start xinetd.
- Service xinetd start
In this way, other machines can synchronize time with the machine through rdate-s ip address