from small one page howto to huge articles all in one place

search text in:




Other .linuxhowtos.org sites: www.linuxhowtos.org
toolsntoys.linuxhowtos.org



Last additions:
How to make X listen on port 6000

How to make X listen on port 6000

words:

34

views:

86631

userrating:

average rating: 1.2 (52 votes) (1=very good 6=terrible)


May, 25th 2007:
April, 26th 2007:
Apr, 10th. 2007:
Druckversion . pdf icon
You are here: Tutorials per portage category->net-misc->ntp


ntp is the Network Time Protocol suite.

Installing ntpd

First, make sure ntp/ntpdate are installed. The package is by default installed on Mandrake Linux and Redhat. If you do not have ntp installed you will find packages on your distributions install-cd(s).

On Gentoo Linux, install by typing --- emerge ntp

Configuration files for running ntp as daemon

ntpd manpage

Client Setup

Now, edit the following files:

--- /etc/ntp.conf

The only important thing is that the line contains server some.thing.org.

Example:

--- server ntp.uio.no driftfile /etc/ntp/drift broadcastdelay 0.008 authenticate no ---

Make sure you add ntpd as a boot (init) service.

Gentoo Linux: `rc-update add ntpd default` , `/etc/init.d/ntpd start`

(LAN) Server setup

To run a ntp server to sync the clocks on your lan, edit

--- /etc/ntp.conf

Example:

--- server fartein.ifi.uio.no prefer server ntp.uio.no server ntp.eunet.no

fudge 10.0.0.50 stratum 10

driftfile /etc/ntp/drift broadcastdelay 0.008

authenticate no ---

fudge tells the server to pass on the correct time to the given network interface. stratum is the level of time servers, 10 being the lowest. You only need a higher number if you will be acting as a public internet timeserver with fast bandwidth.

It makes sence to add a few servers. Select the best as prefer

Make sure you add ntpd as a boot (init) service.

Gentoo Linux: `rc-update add ntpd default` , `/etc/init.d/ntpd start`

Firewalls

ntp uses port 123, both UDP and TCP. Make sure this port is not blocked by a firewall.

If you are using iptables, you can open this port with

--- $IPTABLES -A INPUT -j ACCEPT -p tcp --dport 123

Known valid and working ntp servers

server adress Location
ntp.ipv6.viagenie.qc.ca IPV6 ONLY
clock.via.net
server fartein.ifi.uio.no Norway
server ntp.uio.no Norway
server ntp.eunet.no Norway
ntp.demon.co.uk UK
ntp.nasa.gov USA
bigben.cac.washington.edu USA
time-b.nist.gov USA
montpelier.ilan.caltech.edu USA
nist1.aol-ca.truetime.com USA
nist1.datum.com USA
time-a.timefreq.bldrdoc.gov USA
time-b.timefreq.bldrdoc.gov USA
time-c.timefreq.bldrdoc.gov USA
time.nist.gov USA
utcnist.colorado.edu USA
tick.usno.navy.mil USA
tock.usno.navy.mil USA
mizbeaver.udel.edu USA

Server List

Setting the clock at boot or using cron

I good idea is _not_ to run the ntpd daemon on clients as it uses about 1,7 MB memory, unless you are a server or have a box with a broken clock. Many boxes clocks do drift along on their own, a check every hour or day is generally a good idea.

rdate

rdate is a simple 3 kB tool for syncing the system clock to a server. It's options are `-p` to print the date on the given server, `-s` to set the system clock according to it (must be done as root) and `-u` to use the UDP protocol. Example:

`rdate -p sntp.lth.se`

rdate manual page

clockspeed

clockspeed is a very small tool for setting the clock and is, for clients, a much better alternative than installing the 4+ MB ntp package.

cron & ntp

You can simply add ntpdate as a cron job every now and then:

--- echo 'ntpdate -b server.dot.com' > /etc/cron.hourly/time.cron --- chmod a+x /etc/cron.hourly/time.cron

Most distributions come with a cron. dcron and Vixie cron are nice.

Gentoo & ntp-client

You can set the clock using ntp at boot (without starting the daemon) on Gentoo Linux by editing:

--- /etc/conf.d/ntp-client

The file should contain:

--- NTPDATE_CMD="ntpdate" NTPDATE_OPTS="-b your.server.here" ---

Then add ntp-client to the services started at boot:

--- rc-update add ntp-client default

You can check what services are started at boot with `rc-status`.


Page source:

Copyright (c) 2000-2004 Øyvind Sæther. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the section entitled "GNU Free Documentation License".

back



Support us on Content Nation

New Packages

- as rdf newsfeed
- as rss newsfeed
- as Atom newsfeed
2026-07-07
alsa-lib - 1.2.16.1
Ebuild name:

media-libs/alsa-lib-1.2.16.1

Description

Advanced Linux Sound Architecture Library

Added to portage

2026-07-07

amule - 3.0.1
Ebuild name:

net-p2p/amule-3.0.1

Description

aMule, the all-platform eMule p2p client

Added to portage

2026-07-07

libblockdev - 3.5.0
Ebuild name:

sys-libs/libblockdev-3.5.0

Description

Library for manipulating block devices

Added to portage

2026-07-07

libxmlb - 0.3.28
Ebuild name:

dev-libs/libxmlb-0.3.28

Description

Library to help create and query binary XML blobs

Added to portage

2026-07-07

mkvtoolnix - 100.0
Ebuild name:

media-video/mkvtoolnix-100.0

Description

Tools to create, alter, and inspect Matroska files

Added to portage

2026-07-07

restic - 0.19.1
Ebuild name:

app-backup/restic-0.19.1

Description

A backup program that is fast, efficient and secure

Added to portage

2026-07-07

roundcube - 1.6.17
Ebuild name:

mail-client/roundcube-1.6.17

Description

Browser-based multilingual IMAP client with an application-like user i

Added to portage

2026-07-07

strawberry - 1.2.22
Ebuild name:

media-sound/strawberry-1.2.22

Description

Modern music player and library organizer based on Clementine and Qt

Added to portage

2026-07-07

vanilla-sources - 6.12.95
Ebuild name:

sys-kernel/vanilla-sources-6.12.95

Description

Full sources for the Linux kernel

Added to portage

2026-07-07

zbar - 0.23.93-r3
Ebuild name:

media-gfx/zbar-0.23.93-r3

Description

Library and tools for reading barcodes from images or video

Added to portage

2026-07-07

2026-07-06
citus - 12.1.13
Ebuild name:

dev-db/citus-12.1.13

Description

Open-source postgresql extension for clustering/multi-node setups

Added to portage

2026-07-06

cloudflared - 2026.6.1
Ebuild name:

net-vpn/cloudflared-2026.6.1

Description

A command-line client and tunneling daemon for Cloudflare Tunnel

Added to portage

2026-07-06

containerd - 2.2.5-r1
Ebuild name:

app-containers/containerd-2.2.5-r1

Description

A daemon to control runC

Added to portage

2026-07-06

containerd - 2.3.2-r1
Ebuild name:

app-containers/containerd-2.3.2-r1

Description

A daemon to control runC

Added to portage

2026-07-06

dbus-python - 1.4.0-r1
Ebuild name:

dev-python/dbus-python-1.4.0-r1

Description

Python bindings for the D-Bus messagebus

Added to portage

2026-07-06

dulwich - 1.2.8
Ebuild name:

dev-python/dulwich-1.2.8

Description

Pure-Python implementation of the Git file formats and protocols

Added to portage

2026-07-06

dxvk - 3.0.1
Ebuild name:

app-emulation/dxvk-3.0.1

Description

Vulkan-based implementation of D3D9, D3D10 and D3D11 for Linux / Wine

Added to portage

2026-07-06

firecracker-bin - 1.16.0
Ebuild name:

app-emulation/firecracker-bin-1.16.0

Description

Secure and fast microVMs for serverless computing (static buil

Added to portage

2026-07-06

gawk - 5.4.0e
Ebuild name:

sys-apps/gawk-5.4.0e

Description

GNU awk pattern-matching language

Added to portage

2026-07-06

gcc - 17.0.0_p20260705
Ebuild name:

sys-devel/gcc-17.0.0_p20260705

Description

The GNU Compiler Collection

Added to portage

2026-07-06

getmail - 6.20.00
Ebuild name:

net-mail/getmail-6.20.00

Description

A mail retriever with reliable Maildir and mbox delivery

Added to portage

2026-07-06

ggml - 0.15.3-r1
Ebuild name:

sci-ml/ggml-0.15.3-r1

Description

Tensor library for machine learning

Added to portage

2026-07-06

git-sources - 7.2_rc2
Ebuild name:

sys-kernel/git-sources-7.2_rc2

Description

The very latest -git version of the Linux kernel

Added to portage

2026-07-06

gst-plugins-sndio - 1.24.0
Ebuild name:

media-plugins/gst-plugins-sndio-1.24.0

Description

Sndio audio sink and source for GStreamer

Added to portage

2026-07-06

haproxy - 3.0.25
Ebuild name:

net-proxy/haproxy-3.0.25

Description

A TCP/HTTP reverse proxy for high availability environments

Added to portage

2026-07-06

haproxy - 3.2.21
Ebuild name:

net-proxy/haproxy-3.2.21

Description

A TCP/HTTP reverse proxy for high availability environments

Added to portage

2026-07-06

haproxy - 3.3.12
Ebuild name:

net-proxy/haproxy-3.3.12

Description

A TCP/HTTP reverse proxy for high availability environments

Added to portage

2026-07-06

haproxy - 3.4.2
Ebuild name:

net-proxy/haproxy-3.4.2

Description

A TCP/HTTP reverse proxy for high availability environments

Added to portage

2026-07-06

khard - 0.21.0
Ebuild name:

app-misc/khard-0.21.0

Description

Console vCard address book

Added to portage

2026-07-06

lmdb - 1.0.0
Ebuild name:

dev-db/lmdb-1.0.0

Description

An ultra-fast, ultra-compact key-value embedded data store

Added to portage

2026-07-06

mcrypt - 2.6.8-r3
Ebuild name:

app-crypt/mcrypt-2.6.8-r3

Description

Replacement of the old unix crypt(1)

Added to portage

2026-07-06

md5deep - 4.4
Ebuild name:

app-crypt/md5deep-4.4

Description

Expanded md5sum program with recursive and comparison options

Added to portage

2026-07-06

md6sum - 1.0-r3
Ebuild name:

app-crypt/md6sum-1.0-r3

Description

A C implementation of MD6

Added to portage

2026-07-06

mhash - 0.9.9.9-r4
Ebuild name:

app-crypt/mhash-0.9.9.9-r4

Description

Library providing a uniform interface to a large number of hash algorith

Added to portage

2026-07-06

micawber - 0.7.0
Ebuild name:

dev-python/micawber-0.7.0

Description

A small library for extracting rich content from urls

Added to portage

2026-07-06

minisign - 0.12
Ebuild name:

app-crypt/minisign-0.12

Description

Dead simple tool to sign files and verify signatures

Added to portage

2026-07-06

mit-krb5 - 1.22.2-r2
Ebuild name:

app-crypt/mit-krb5-1.22.2-r2

Description

MIT Kerberos V

Added to portage

2026-07-06

mit-krb5-appl - 1.0.3-r4
Ebuild name:

app-crypt/mit-krb5-appl-1.0.3-r4

Description

Kerberized applications split from the main MIT Kerberos V distrib

Added to portage

2026-07-06

mit-krb5-appl - 1.0.3-r5
Ebuild name:

app-crypt/mit-krb5-appl-1.0.3-r5

Description

Kerberized applications split from the main MIT Kerberos V distrib

Added to portage

2026-07-06

mkp224o - 1.7.0
Ebuild name:

app-crypt/mkp224o-1.7.0

Description

Vanity address generator for v3 Tor hidden service addresses

Added to portage

2026-07-06

munt-mt32emu - 2.8.3
Ebuild name:

media-libs/munt-mt32emu-2.8.3

Description

Library for emulating the Roland MT-32, CM-32L, CM-64 and LAPC-I

Added to portage

2026-07-06

nnn - 5.2
Ebuild name:

app-misc/nnn-5.2

Description

The missing terminal file browser for X

Added to portage

2026-07-06

ollama - 0
Ebuild name:

acct-group/ollama-0

Description

A group for ollama

Added to portage

2026-07-06

ollama - 0
Ebuild name:

acct-user/ollama-0

Description

A user for ollama

Added to portage

2026-07-06

ollama - 0.31.1-r1
Ebuild name:

sci-ml/ollama-0.31.1-r1

Description

Get up and running with Llama 3, Mistral, Gemma, and other language models.

Added to portage

2026-07-06

packer - 1.15.4
Ebuild name:

dev-util/packer-1.15.4

Description

A tool to create identical machine images for multiple platforms

Added to portage

2026-07-06

pip - 26.1.2-r1
Ebuild name:

dev-python/pip-26.1.2-r1

Description

The PyPA recommended tool for installing Python packages

Added to portage

2026-07-06

portage - 3.0.81.1
Ebuild name:

sys-apps/portage-3.0.81.1

Description

The package management and distribution system for Gentoo

Added to portage

2026-07-06

roundcube - 1.7.2
Ebuild name:

mail-client/roundcube-1.7.2

Description

A browser-based multilingual IMAP client with an application-like user

Added to portage

2026-07-06

runc - 1.3.6
Ebuild name:

app-containers/runc-1.3.6

Description

runc container cli tools

Added to portage

2026-07-06

rust - 1.96.1
Ebuild name:

dev-lang/rust-1.96.1

Description

Systems programming language originally developed by Mozilla

Added to portage

2026-07-06

rust-bin - 1.96.1
Ebuild name:

dev-lang/rust-bin-1.96.1

Description

Added to portage

2026-07-06

rust-common - 1.96.1
Ebuild name:

dev-lang/rust-common-1.96.1

Description

Common files shared between multiple slots of Rust

Added to portage

2026-07-06

rust-std - 1.96.1
Ebuild name:

sys-devel/rust-std-1.96.1

Description

Rust standard library, standalone (for crossdev)

Added to portage

2026-07-06

seedfiles - 1.7
Ebuild name:

sys-apps/seedfiles-1.7

Description

Portable drop-in reimplementation of systemd-tmpfiles

Added to portage

2026-07-06

signxml - 5.1.0
Ebuild name:

dev-python/signxml-5.1.0

Description

Python XML Signature and XAdES library

Added to portage

2026-07-06

telegram-desktop-bin - 6.9.3
Ebuild name:

net-im/telegram-desktop-bin-6.9.3

Description

Official desktop client for Telegram (binary package)

Added to portage

2026-07-06

tibs - 0.12.0
Ebuild name:

dev-python/tibs-0.12.0

Description

A sleek Python library for your binary data

Added to portage

2026-07-06

rdf newsfeed | rss newsfeed | Atom newsfeed
Copyright 2004-2025 Sascha Nitsch Unternehmensberatung GmbH
- Copyright and legal notices -
Time to create this page: 19.5 ms