Linux Slackware

Linux Slackware 15.0 comes with the “NTPD” daemon as standard, which is a full-featured client and server for time synchronization.

By default, it is not enabled, our task is to configure “NTPD” and provide autorun

To do this, on the desktop, at the bottom left, click “Kmenu”

slackware15_RU_01

Menu will appear

slackware15_EN_02

Go to the “System” section, then “Konsole”

slackware15_EN_03

Launching the terminal

slackware15_EN_04

We see a black screen and the command interpreter “Bash”

A prompt ending with a “$” means that we are in the console as a user with limited rights

You need to elevate your privileges in order to be able to edit system files

To do this, execute the command “su”, and enter the password of the superuser “root”

slackware15_EN_05

After successfully changing the user, the prompt icon will change to “#”, which means we have superuser rights

slackware15_EN_06

Run the file manager “Midnight Commander” with the command “mc”

slackware15_EN_07

In the program that opens, write the command to go to the directory with the settings files

We enter the command cd /etc

After executing the command, look for the file ntp.conf

slackware15_EN_08

Rename the original file with a keyboard shortcut SHIFT+F6

slackware15_EN_09

as a result:

slackware15_EN_10

Open a new empty file with the command mcedit ntp.conf

slackware15_EN_11

After executing the command, the editor window will open

slackware15_EN_12

We enter lines with parameters:
server pool1.ntp.od.ua
tinker panic 0
restrct default noquery nomodify
restrict 127.0.0.1
restrict pool1.ntp.od.ua

slackware15_EN_13

After completion, press the button on the keyboard “F2” and agree to save the file “Save”

slackware15_EN_14

Next, we will return to the file manager again.

slackware15_EN_15

writing a command cd rc.d

In the rc.d directory we find the file inet1.conf

slackware15_EN_16

Open it in edit mode with the key F4

slackware15_EN_17

Assuming you are using a DHCP client and getting network settings from a DHCP server

You may also be given the settings of the time server of your network, so that these settings do not overlap your changes in the file, you must prohibit modifying them

To do this, in the file for the “eth0” network card, add the line ” DHCP_KEEPNTP[0]=”yes” “ if your network card has a different name, then take this into account when changing

slackware15_EN_18

Save the changes with “F2” and confirm with “Save”

slackware15_EN_19

Next, in the file manager in the same directory, we find the file rc.ntpd

It currently does not have the execute bit set, which means it will not run when the system is turned on.

slackware15_EN_20

We fix this behavior with the command chmod 755 rc.ntpd

slackware15_EN_21

After executing the command, the file will change color and will have a symbol at the beginning * звездочки

slackware15_EN_22

Exit the file manager with the keyboard key F10

slackware15_EN_23

At the command line, enter the command to start the time synchronization daemon /etc/rc.d/rc.ntpd start

slackware15_EN_24

The completed launch looks like this

slackware15_EN_25

Checking the synchronization status with the command ntpq -pn 127.0.0.1

Execution result shown pool as time source

slackware15_EN_26

After a while, an IP address from the pool will be added

slackware15_EN_27

After another time against the selected time source, “* asterisk” will appear

slackware15_EN_28

Setup completed.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

This site uses Akismet to reduce spam. Learn how your comment data is processed.