Blame phc2sys.8

Packit 9c3e7e
.TH PHC2SYS 8 "April 2018" "linuxptp"
Packit 9c3e7e
.SH NAME
Packit 9c3e7e
phc2sys \- synchronize two or more clocks
Packit 9c3e7e
Packit 9c3e7e
.SH SYNOPSIS
Packit 9c3e7e
.B phc2sys \-a
Packit 9c3e7e
[
Packit 9c3e7e
.B \-r
Packit 9c3e7e
] [
Packit 9c3e7e
.B \-r
Packit 9c3e7e
] [
Packit 9c3e7e
.BI \-f " config-file"
Packit 9c3e7e
] [ options ] [
Packit 9c3e7e
.I long-options
Packit 9c3e7e
]
Packit 9c3e7e
.br
Packit 9c3e7e
.B phc2sys
Packit 9c3e7e
[
Packit 9c3e7e
.BI \-f " config-file"
Packit 9c3e7e
] [
Packit 9c3e7e
.BI \-d " pps-device"
Packit 9c3e7e
] [
Packit 9c3e7e
.BI \-s " device"
Packit 9c3e7e
] [
Packit 9c3e7e
.BI \-c " device"
Packit 9c3e7e
] [
Packit 9c3e7e
.BI \-O " offset"
Packit 9c3e7e
] [
Packit 9c3e7e
.BI \-w
Packit 9c3e7e
] [ options ] [
Packit 9c3e7e
.I long-options
Packit 9c3e7e
]
Packit 9c3e7e
.I .\|.\|.
Packit 9c3e7e
Packit 9c3e7e
Packit 9c3e7e
.SH DESCRIPTION
Packit 9c3e7e
.B phc2sys
Packit 9c3e7e
is a program which synchronizes two or more clocks in the system. Typically,
Packit 9c3e7e
it is used to synchronize the system clock to a PTP hardware clock (PHC),
Packit 9c3e7e
which itself is synchronized by the
Packit 9c3e7e
.BR ptp4l (8)
Packit 9c3e7e
program.
Packit 9c3e7e
Packit 9c3e7e
With the
Packit 9c3e7e
.B \-a
Packit 9c3e7e
option, the clocks to synchronize are fetched from the running
Packit 9c3e7e
.B ptp4l
Packit 9c3e7e
daemon and the direction of synchronization automatically follows changes of
Packit 9c3e7e
the PTP port states.
Packit 9c3e7e
Packit 9c3e7e
Manual configuration is also possible. When using manual configuration, two
Packit 9c3e7e
synchronization modes are supported, one uses a pulse per second (PPS)
Packit 9c3e7e
signal provided by the source clock and the other mode reads time from the
Packit 9c3e7e
source clock directly. Some clocks can be used in both modes, the mode which
Packit 9c3e7e
will synchronize the slave clock with better accuracy depends on hardware
Packit 9c3e7e
and driver implementation.
Packit 9c3e7e
Packit 9c3e7e
.SH OPTIONS
Packit 9c3e7e
.TP
Packit 9c3e7e
.BI \-a
Packit 9c3e7e
Read the clocks to synchronize from running
Packit 9c3e7e
.B ptp4l
Packit 9c3e7e
and follow changes in the port states, adjusting the synchronization
Packit 9c3e7e
direction automatically. The system clock (CLOCK_REALTIME) is not
Packit 9c3e7e
synchronized, unless the
Packit 9c3e7e
.B \-r
Packit 9c3e7e
option is also specified.
Packit 9c3e7e
.TP
Packit 9c3e7e
.BI \-r
Packit 9c3e7e
Only valid together with the
Packit 9c3e7e
.B \-a
Packit 9c3e7e
option. Instructs
Packit 9c3e7e
.B phc2sys
Packit 9c3e7e
to also synchronize the system clock (CLOCK_REALTIME). By default, the
Packit 9c3e7e
system clock is not considered as a possible time source. If you want the
Packit 9c3e7e
system clock to be eligible to become a time source, specify the
Packit 9c3e7e
.B \-r
Packit 9c3e7e
option twice.
Packit 9c3e7e
.TP
Packit 9c3e7e
.BI \-f " config"
Packit 9c3e7e
Read configuration from the specified file. No configuration file is read by
Packit 9c3e7e
default.
Packit 9c3e7e
.TP
Packit 9c3e7e
.BI \-d " pps-device"
Packit 9c3e7e
Specify the PPS device of the master clock (e.g. /dev/pps0). With this option
Packit 9c3e7e
the PPS synchronization mode is used instead of the direct mode. As the PPS
Packit 9c3e7e
signal does not specify time and only marks start of a second, the slave clock
Packit 9c3e7e
should be already close to the correct time before
Packit 9c3e7e
.B phc2sys
Packit 9c3e7e
is started or the
Packit 9c3e7e
.B \-s
Packit 9c3e7e
option should be used too. With the
Packit 9c3e7e
.B \-s
Packit 9c3e7e
option the PPS signal of the master clock is enabled automatically, otherwise
Packit 9c3e7e
it has to be enabled before
Packit 9c3e7e
.B phc2sys
Packit 9c3e7e
is started (e.g. by running \f(CWecho 1 > /sys/class/ptp/ptp0/pps_enable\fP).
Packit 9c3e7e
This option can be used only with the system clock as the slave clock. Not
Packit 9c3e7e
compatible with the
Packit 9c3e7e
.B \-a
Packit 9c3e7e
option.
Packit 9c3e7e
.TP
Packit 9c3e7e
.BI \-s " device"
Packit 9c3e7e
Specify the master clock by device (e.g. /dev/ptp0) or interface (e.g. eth0) or
Packit 9c3e7e
by name (e.g. CLOCK_REALTIME for the system clock). When this option is used
Packit 9c3e7e
together with the
Packit 9c3e7e
.B \-d
Packit 9c3e7e
option, the master clock is used only to correct the offset by whole number of
Packit 9c3e7e
seconds, which cannot be fixed with PPS alone. Not compatible with the
Packit 9c3e7e
.B \-a
Packit 9c3e7e
option. This option does not support bonded interface (e.g. bond0). If
Packit 9c3e7e
.B ptp4l
Packit 9c3e7e
has a port on an active-backup bond interface, the
Packit 9c3e7e
.B \-a
Packit 9c3e7e
option can be used to track the active interface.
Packit 9c3e7e
.TP
Packit 9c3e7e
.BI \-i " interface"
Packit 9c3e7e
Performs the exact same function as
Packit 9c3e7e
.B \-s
Packit 9c3e7e
for compatibility reasons. Previously enabled specifying master clock by network
Packit 9c3e7e
interface. However, this can now be done using
Packit 9c3e7e
.B \-s
Packit 9c3e7e
and this option is no longer necessary. As such it has been deprecated, and
Packit 9c3e7e
should no longer be used.
Packit 9c3e7e
.TP
Packit 9c3e7e
.BI \-c " device"
Packit 9c3e7e
Specify the slave clock by device (e.g. /dev/ptp1) or interface (e.g. eth1) or
Packit 9c3e7e
by  name. The default is CLOCK_REALTIME (the system clock). Not compatible
Packit 9c3e7e
with the
Packit 9c3e7e
.B \-a
Packit 9c3e7e
option.
Packit 9c3e7e
.TP
Packit 9c3e7e
.BI \-E " servo"
Packit 9c3e7e
Specify which clock servo should be used. Valid values are pi for a PI
Packit 9c3e7e
controller, linreg for an adaptive controller using linear regression, and
Packit 9c3e7e
ntpshm for the NTP SHM reference clock to allow another process to synchronize
Packit 9c3e7e
the local clock.
Packit 9c3e7e
The default is pi.
Packit 9c3e7e
.TP
Packit 9c3e7e
.BI \-P " kp"
Packit 9c3e7e
Specify the proportional constant of the PI controller. The default is 0.7.
Packit 9c3e7e
.TP
Packit 9c3e7e
.BI \-I " ki"
Packit 9c3e7e
Specify the integral constant of the PI controller. The default is 0.3.
Packit 9c3e7e
.TP
Packit 9c3e7e
.BI \-S " step"
Packit 9c3e7e
Specify the step threshold of the servo. It is the maximum offset that
Packit 9c3e7e
the servo corrects by changing the clock frequency instead of stepping the
Packit 9c3e7e
clock. The clock is stepped on start regardless of the option if the offset is
Packit 9c3e7e
larger than 20 microseconds (unless the
Packit 9c3e7e
.BI \-F
Packit 9c3e7e
option is used). It's specified in seconds. The value of 0.0 disables stepping
Packit 9c3e7e
after the start. The default is 0.0.
Packit 9c3e7e
.TP
Packit 9c3e7e
.BI \-F " step"
Packit 9c3e7e
Specify the step threshold applied only on the first update. It is the maximum
Packit 9c3e7e
offset that is corrected by changing the clock frequency. It's specified in
Packit 9c3e7e
seconds. The value of 0.0 disables stepping on start. The default is 0.00002
Packit 9c3e7e
(20 microseconds).
Packit 9c3e7e
.TP
Packit 9c3e7e
.BI \-R " update-rate"
Packit 9c3e7e
Specify the slave clock update rate when running in the direct synchronization
Packit 9c3e7e
mode. The default is 1 per second.
Packit 9c3e7e
.TP
Packit 9c3e7e
.BI \-N " phc-num"
Packit 9c3e7e
Specify the number of master clock readings per one slave clock update. Only
Packit 9c3e7e
the fastest reading is used to update the slave clock, this is useful to
Packit 9c3e7e
minimize the error caused by random delays in scheduling and bus utilization.
Packit 9c3e7e
The default is 5.
Packit 9c3e7e
.TP
Packit 9c3e7e
.BI \-O " offset"
Packit 9c3e7e
Specify the offset between the slave and master times in seconds. Not
Packit 9c3e7e
compatible with the
Packit 9c3e7e
.B \-a
Packit 9c3e7e
option.  See
Packit 9c3e7e
.SM
Packit 9c3e7e
.B TIME SCALE USAGE
Packit 9c3e7e
below.
Packit 9c3e7e
.TP
Packit 9c3e7e
.BI \-L " freq-limit"
Packit 9c3e7e
The maximum allowed frequency offset between uncorrected clock and the system
Packit 9c3e7e
monotonic clock in parts per billion (ppb). This is used as a sanity check of
Packit 9c3e7e
the synchronized clock. When a larger offset is measured, a warning message
Packit 9c3e7e
will be printed and the servo will be reset. When set to 0, the sanity check is
Packit 9c3e7e
disabled. The default is 200000000 (20%).
Packit 9c3e7e
.TP
Packit 9c3e7e
.BI \-M " segment"
Packit 9c3e7e
The number of the SHM segment used by ntpshm servo.
Packit 9c3e7e
The default is 0.
Packit 9c3e7e
.TP
Packit 9c3e7e
.BI \-u " summary-updates"
Packit 9c3e7e
Specify the number of clock updates included in summary statistics. The
Packit 9c3e7e
statistics include offset root mean square (RMS), maximum absolute offset,
Packit 9c3e7e
frequency offset mean and standard deviation, and mean of the delay in clock
Packit 9c3e7e
readings and standard deviation. The units are nanoseconds and parts per
Packit 9c3e7e
billion (ppb). If zero, the individual samples are printed instead of the
Packit 9c3e7e
statistics. The messages are printed at the LOG_INFO level.
Packit 9c3e7e
The default is 0 (disabled).
Packit 9c3e7e
.TP
Packit 9c3e7e
.B \-w
Packit 9c3e7e
Wait until ptp4l is in a synchronized state. If the
Packit 9c3e7e
.B \-O
Packit 9c3e7e
option is not used, also keep the offset between the slave and master
Packit 9c3e7e
times updated according to the currentUtcOffset value obtained from ptp4l and
Packit 9c3e7e
the direction of the clock synchronization. Not compatible with the
Packit 9c3e7e
.B \-a
Packit 9c3e7e
option.
Packit 9c3e7e
.TP
Packit 9c3e7e
.BI \-n " domain-number"
Packit 9c3e7e
Specify the domain number used by ptp4l. The default is 0.
Packit 9c3e7e
.TP
Packit 9c3e7e
.B \-x
Packit 9c3e7e
When a leap second is announced, don't apply it in the kernel by stepping the
Packit 9c3e7e
clock, but let the servo correct the one-second offset slowly by changing the
Packit 9c3e7e
clock frequency (unless the
Packit 9c3e7e
.B \-S
Packit 9c3e7e
option is used).
Packit 9c3e7e
.TP
Packit 9c3e7e
.BI \-z " uds-address"
Packit 9c3e7e
Specifies the address of the server's UNIX domain socket.
Packit 9c3e7e
The default is /var/run/ptp4l.
Packit 9c3e7e
.TP
Packit 9c3e7e
.BI \-l " print-level"
Packit 9c3e7e
Set the maximum syslog level of messages which should be printed or sent to
Packit 9c3e7e
the system logger. The default is 6 (LOG_INFO).
Packit 9c3e7e
.TP
Packit 9c3e7e
.BI \-t " message-tag"
Packit 9c3e7e
Specify the tag which is added to all messages printed to the standard output
Packit 9c3e7e
or system log. The default is an empty string.
Packit 9c3e7e
.TP
Packit 9c3e7e
.B \-m
Packit 9c3e7e
Print messages to the standard output.
Packit 9c3e7e
.TP
Packit 9c3e7e
.B \-q
Packit 9c3e7e
Don't send messages to the system logger.
Packit 9c3e7e
.TP
Packit 9c3e7e
.BI \-h
Packit 9c3e7e
Display a help message.
Packit 9c3e7e
.TP
Packit 9c3e7e
.B \-v
Packit 9c3e7e
Prints the software version and exits.
Packit 9c3e7e
Packit 9c3e7e
.SH LONG OPTIONS
Packit 9c3e7e
Packit 9c3e7e
Each and every configuration file option (see below in section
Packit 9c3e7e
.BR FILE\ OPTIONS)
Packit 9c3e7e
may also appear
Packit 9c3e7e
as a "long" style command line argument.  For example, the transportSpecific
Packit 9c3e7e
option may be set using either of these two forms:
Packit 9c3e7e
Packit 9c3e7e
.RS
Packit 9c3e7e
\f(CW\-\-transportSpecific 1   \-\-transportSpecific=1\fP
Packit 9c3e7e
.RE
Packit 9c3e7e
Packit 9c3e7e
Option values given on the command line override values in the global
Packit 9c3e7e
section of the configuration file (which, in turn overrides default
Packit 9c3e7e
values).
Packit 9c3e7e
Packit 9c3e7e
.SH CONFIGURATION FILE
Packit 9c3e7e
Packit 9c3e7e
The configuration file is divided into sections. Each section starts with a
Packit 9c3e7e
line containing its name enclosed in brackets and it follows with settings.
Packit 9c3e7e
Each setting is placed on a separate line, it contains the name of the
Packit 9c3e7e
option and the value separated by whitespace characters. Empty lines and lines
Packit 9c3e7e
starting with # are ignored.
Packit 9c3e7e
Packit 9c3e7e
The global section (indicated as
Packit 9c3e7e
.BR [global] )
Packit 9c3e7e
sets the program options. This is the only used option.
Packit 9c3e7e
Packit 9c3e7e
.SH FILE OPTIONS
Packit 9c3e7e
Packit 9c3e7e
.TP
Packit 9c3e7e
.B domainNumber
Packit 9c3e7e
Specify the domain number used by phc2sys. The default is 0. Same as option
Packit 9c3e7e
.B \-n
Packit 9c3e7e
(see above).
Packit 9c3e7e
Packit 9c3e7e
.TP
Packit 9c3e7e
.B kernel_leap
Packit 9c3e7e
When a leap second is announced, let the kernel apply it by stepping the
Packit 9c3e7e
clock instead of correcting the one-second offset with servo, which would
Packit 9c3e7e
correct the one-second offset slowly by changing the clock frequency
Packit 9c3e7e
(unless the step_threshold option is set to correct such offset by
Packit 9c3e7e
stepping). Relevant only with software time stamping. The default is 1
Packit 9c3e7e
(enabled). Same as option
Packit 9c3e7e
.B \-x
Packit 9c3e7e
(see above).
Packit 9c3e7e
Packit 9c3e7e
The maximum logging level of messages which should be printed.
Packit 9c3e7e
The default is 6 (LOG_INFO). Same as option
Packit 9c3e7e
.B \-l
Packit 9c3e7e
(see above).
Packit 9c3e7e
Packit 9c3e7e
.TP
Packit 9c3e7e
.B logging_level
Packit 9c3e7e
The maximum logging level of messages which should be printed.
Packit 9c3e7e
The default is 6 (LOG_INFO). Same as option
Packit 9c3e7e
.B \-l
Packit 9c3e7e
(see above).
Packit 9c3e7e
Packit 9c3e7e
.TP
Packit 9c3e7e
.B message_tag
Packit 9c3e7e
The tag which is added to all messages printed to the standard output
Packit 9c3e7e
or system log. The default is an empty string (which cannot be set in
Packit 9c3e7e
the configuration file as the option requires an argument).
Packit 9c3e7e
Same as option
Packit 9c3e7e
.B \-t
Packit 9c3e7e
(see above).
Packit 9c3e7e
Packit 9c3e7e
.TP
Packit 9c3e7e
.B sanity_freq_limit
Packit 9c3e7e
The maximum allowed frequency offset between uncorrected clock and the
Packit 9c3e7e
system monotonic clock in parts per billion (ppb). This is used as a
Packit 9c3e7e
sanity check of the synchronized clock. When a larger offset is measured,
Packit 9c3e7e
a warning message will be printed and the servo will be reset. When set
Packit 9c3e7e
to 0, the sanity check is disabled. The default is 200000000 (20%).
Packit 9c3e7e
Same as option
Packit 9c3e7e
.B \-L
Packit 9c3e7e
(see above).
Packit 9c3e7e
Packit 9c3e7e
.TP
Packit 9c3e7e
.B clock_servo
Packit 9c3e7e
The servo which is used to synchronize the local clock. Valid values
Packit 9c3e7e
are "pi" for a PI controller, "linreg" for an adaptive controller using
Packit 9c3e7e
linear regression, "ntpshm" for the NTP SHM reference clock to allow
Packit 9c3e7e
another process to synchronize the local clock (the SHM segment number
Packit 9c3e7e
is set to the domain number), and "nullf" for a servo that always dials
Packit 9c3e7e
frequency offset zero (for use in SyncE nodes). The default is "pi."
Packit 9c3e7e
Same as option
Packit 9c3e7e
.B \-E
Packit 9c3e7e
(see above).
Packit 9c3e7e
Packit 9c3e7e
.TP
Packit 9c3e7e
.B transportSpecific
Packit 9c3e7e
The transport specific field. Must be in the range 0 to 255.
Packit 9c3e7e
The default is 0.
Packit 9c3e7e
Packit 9c3e7e
.TP
Packit 9c3e7e
.B use_syslog
Packit 9c3e7e
Print messages to the system log if enabled.  The default is 1 (enabled).
Packit 9c3e7e
Related to option
Packit 9c3e7e
.B \-q
Packit 9c3e7e
(see above).
Packit 9c3e7e
Packit 9c3e7e
.TP
Packit 9c3e7e
.B verbose
Packit 9c3e7e
Print messages to the standard output if enabled.  The default is 0 (disabled).
Packit 9c3e7e
Related to option
Packit 9c3e7e
.B \-m
Packit 9c3e7e
(see above).
Packit 9c3e7e
Packit 9c3e7e
.TP
Packit 9c3e7e
.B pi_proportional_const
Packit 9c3e7e
Specifies the proportional constant of the PI controller.
Packit 9c3e7e
Same as option
Packit 9c3e7e
.B \-P
Packit 9c3e7e
(see above).
Packit 9c3e7e
Packit 9c3e7e
.TP
Packit 9c3e7e
.B pi_integral_const
Packit 9c3e7e
Specifies the integral constant of the PI controller.
Packit 9c3e7e
Same as option
Packit 9c3e7e
.B \-I
Packit 9c3e7e
(see above).
Packit 9c3e7e
Packit 9c3e7e
.TP
Packit 9c3e7e
.B step_threshold
Packit 9c3e7e
Specifies the step threshold of the servo. It is the maximum offset that
Packit 9c3e7e
the servo corrects by changing the clock frequency instead of stepping
Packit 9c3e7e
the clock. The clock is stepped on start regardless of the option if the
Packit 9c3e7e
offset is larger than 20 microseconds (unless the -F option is used).
Packit 9c3e7e
It's  specified  in seconds. The value of 0.0 disables stepping after
Packit 9c3e7e
the start. The default is 0.0.
Packit 9c3e7e
Same as option
Packit 9c3e7e
.B \-S
Packit 9c3e7e
(see above).
Packit 9c3e7e
Packit 9c3e7e
.TP
Packit 9c3e7e
.B first_step_threshold
Packit 9c3e7e
Specify the step threshold applied only on the first update. It is the
Packit 9c3e7e
maximum offset that is corrected by adjusting clock. It's specified in
Packit 9c3e7e
seconds. The value of 0.0 disables stepping on start. The default is
Packit 9c3e7e
0.00002 (20 microseconds).
Packit 9c3e7e
Same as option
Packit 9c3e7e
.B \-F
Packit 9c3e7e
(see above).
Packit 9c3e7e
Packit 9c3e7e
.TP
Packit 9c3e7e
.B ntpshm_segment
Packit 9c3e7e
The number of the SHM segment used by ntpshm servo.  The default is 0.
Packit 9c3e7e
Same as option
Packit 9c3e7e
.B \-M
Packit 9c3e7e
(see above).
Packit 9c3e7e
Packit 9c3e7e
.TP
Packit 9c3e7e
.B uds_address
Packit 9c3e7e
Specifies the address of the server's UNIX domain socket. The default
Packit 9c3e7e
is /var/run/ptp4
Packit 9c3e7e
Same as option
Packit 9c3e7e
.B \-z
Packit 9c3e7e
(see above).
Packit 9c3e7e
Packit 9c3e7e
.SH TIME SCALE USAGE
Packit 9c3e7e
Packit 9c3e7e
.B Ptp4l
Packit 9c3e7e
uses either PTP time scale or UTC (Coordinated Universal Time) time
Packit 9c3e7e
scale.  PTP time scale is continuous and shifted against UTC by a few tens of
Packit 9c3e7e
seconds as PTP time scale does not apply leap seconds.
Packit 9c3e7e
Packit 9c3e7e
In hardware time stamping mode,
Packit 9c3e7e
.B ptp4l
Packit 9c3e7e
announces use of PTP time scale and PHC
Packit 9c3e7e
is used for the stamps.  That means PHC must follow PTP time scale while system
Packit 9c3e7e
clock follows UTC.  Time offset between these two is maintained by
Packit 9c3e7e
.BR phc2sys .
Packit 9c3e7e
Packit 9c3e7e
.B Phc2sys
Packit 9c3e7e
acquires the offset value either by reading it from ptp4l when
Packit 9c3e7e
.B \-a
Packit 9c3e7e
or
Packit 9c3e7e
.B \-w
Packit 9c3e7e
is in effect or from command line when
Packit 9c3e7e
.B \-O
Packit 9c3e7e
is supplied.  Failure to maintain the correct offset can result in local system
Packit 9c3e7e
clock being off some seconds to domain master system clock when in slave mode,
Packit 9c3e7e
or incorect PTP time announced to the network in case the host is the domain
Packit 9c3e7e
master.
Packit 9c3e7e
Packit 9c3e7e
.SH EXAMPLES
Packit 9c3e7e
Packit 9c3e7e
Synchronize time automatically according to the current
Packit 9c3e7e
.B ptp4l
Packit 9c3e7e
state, synchronize the system clock to the remote master.
Packit 9c3e7e
Packit 9c3e7e
.RS
Packit 9c3e7e
\f(CWphc2sys \-a \-r\fP
Packit 9c3e7e
.RE
Packit 9c3e7e
Packit 9c3e7e
Same as above, but when the host becomes the domain master, synchronize time
Packit 9c3e7e
in the domain to its system clock.
Packit 9c3e7e
Packit 9c3e7e
.RS
Packit 9c3e7e
\f(CWphc2sys \-a \-rr\fP
Packit 9c3e7e
.RE
Packit 9c3e7e
Packit 9c3e7e
Same as above, in an IEEE 802.1AS domain.
Packit 9c3e7e
Packit 9c3e7e
.RS
Packit 9c3e7e
\f(CWphc2sys \-a \-rr --transportSpecific=1\fP
Packit 9c3e7e
.RE
Packit 9c3e7e
Packit 9c3e7e
The host is a domain master, PTP clock is synchronized to system clock and the
Packit 9c3e7e
time offset is obtained from
Packit 9c3e7e
.BR ptp4l .
Packit 9c3e7e
.B Phc2sys
Packit 9c3e7e
waits for
Packit 9c3e7e
.B ptp4l
Packit 9c3e7e
to get at least one port in master or slave mode before starting the
Packit 9c3e7e
synchronization.
Packit 9c3e7e
Packit 9c3e7e
.RS
Packit 9c3e7e
\f(CWphc2sys \-c /dev/ptp0 \-s CLOCK_REALTIME \-w\fP
Packit 9c3e7e
.RE
Packit 9c3e7e
Packit 9c3e7e
Same as above, time offset is provided on command line and
Packit 9c3e7e
.B phc2sys
Packit 9c3e7e
does not wait for
Packit 9c3e7e
.BR ptp4l .
Packit 9c3e7e
Packit 9c3e7e
.RS
Packit 9c3e7e
\f(CWphc2sys \-c /dev/ptp0 \-s CLOCK_REALTIME \-O 35\fP
Packit 9c3e7e
.RE
Packit 9c3e7e
Packit 9c3e7e
The host is in slave mode, system clock is synchronized from PTP clock,
Packit 9c3e7e
.B phc2sys
Packit 9c3e7e
waits for
Packit 9c3e7e
.B ptp4l
Packit 9c3e7e
and the offset is set automatically.
Packit 9c3e7e
Packit 9c3e7e
.RS
Packit 9c3e7e
\f(CWphc2sys \-s /dev/ptp0 \-w\fP
Packit 9c3e7e
.RE
Packit 9c3e7e
Packit 9c3e7e
Same as above, PTP clock id is read from the network interface, the offset is
Packit 9c3e7e
provided on command line
Packit 9c3e7e
.B phc2sys
Packit 9c3e7e
does not wait.
Packit 9c3e7e
Packit 9c3e7e
.RS
Packit 9c3e7e
\f(CWphc2sys \-s eth0 \-O \-35\fP
Packit 9c3e7e
.RE
Packit 9c3e7e
Packit 9c3e7e
.SH WARNING
Packit 9c3e7e
Packit 9c3e7e
Be cautious when the same configuration file is used for both ptp4l and phc2sys.
Packit 9c3e7e
Keep in mind, that values specified in the configuration file take precedence
Packit 9c3e7e
over their default values. If a certain option, which is common to ptp4l and
Packit 9c3e7e
phc2sys, is specified to a non-default value in the configuration file
Packit 9c3e7e
(p.e., for ptp4l), then this non-default value applies also for phc2sys. This
Packit 9c3e7e
might be not what is expected.
Packit 9c3e7e
Packit 9c3e7e
It is recommended to use seperate configuration files for ptp4l and
Packit 9c3e7e
phc2sys in order to avoid any unexpected behavior.
Packit 9c3e7e
Packit 9c3e7e
.SH SEE ALSO
Packit 9c3e7e
.BR ptp4l (8)