linux:ntp
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| linux:ntp [2025/03/03 18:48] – [Befehle] gsys | linux:ntp [2025/11/06 12:26] (current) – [chrony] gsys | ||
|---|---|---|---|
| Line 5: | Line 5: | ||
| <code bash> | <code bash> | ||
| rcntp ntptimeset | rcntp ntptimeset | ||
| + | ntpq -p #show peers | ||
| timedatectl | timedatectl | ||
| sudo timedatectl set-ntp true | sudo timedatectl set-ntp true | ||
| Line 18: | Line 19: | ||
| timedatectl list-timezones | egrep -o " | timedatectl list-timezones | egrep -o " | ||
| sudo timedatectl set-timezone " | sudo timedatectl set-timezone " | ||
| + | </ | ||
| + | |||
| + | ===== chrony ===== | ||
| + | |||
| + | '' | ||
| + | < | ||
| + | server 192.168.1.1 | ||
| + | allow 10.1.0.0/16 | ||
| + | allow 192.168.1.0/ | ||
| + | </ | ||
| + | |||
| + | restart chrony service | ||
| + | < | ||
| + | systemctl restart chronyd | ||
| + | </ | ||
| + | |||
| + | check if new ntp server is used | ||
| + | < | ||
| + | journalctl --since -1h -u chronyd | ||
| + | </ | ||
| + | ==== client ==== | ||
| + | < | ||
| + | chronyc activity | ||
| + | chronyc 'burst 4/ | ||
| + | chronyc -N sources | ||
| </ | </ | ||
linux/ntp.1741024082.txt.gz · Last modified: by gsys