master
md 148 lines 3.9 KB
Rendered Raw
1 <!--startmeta
2 custom_edit_url: "https://github.com/netdata/netdata/edit/master/src/collectors/timex.plugin/README.md"
3 meta_yaml: "https://github.com/netdata/netdata/edit/master/src/collectors/timex.plugin/metadata.yaml"
4 sidebar_label: "Timex"
5 learn_status: "Published"
6 learn_rel_path: "Collecting Metrics/Collectors/Networking"
7 message: "DO NOT EDIT THIS FILE DIRECTLY, IT IS GENERATED BY THE COLLECTOR'S metadata.yaml FILE"
8 endmeta-->
9
10 # Timex
11
12
13 <img src="https://netdata.cloud/img/syslog.png" width="150"/>
14
15
16 Plugin: timex.plugin
17 Module: timex.plugin
18
19 <img src="https://img.shields.io/badge/maintained%20by-Netdata-%2300ab44" />
20
21 ## Overview
22
23 Examine Timex metrics to gain insights into system clock operations. Study time sync status, clock drift, and adjustments to ensure accurate system timekeeping.
24
25 It uses system call adjtimex on Linux and ntp_adjtime on FreeBSD or Mac to monitor the system kernel clock synchronization state.
26
27 This collector is supported on all platforms.
28
29 This collector supports collecting metrics from multiple instances of this integration, including remote instances.
30
31
32 ### Default Behavior
33
34 #### Auto-Detection
35
36 This integration doesn't support auto-detection.
37
38 #### Limits
39
40 The default configuration for this integration does not impose any limits on data collection.
41
42 #### Performance Impact
43
44 The default configuration for this integration is not expected to impose a significant performance impact on the system.
45
46 ## Setup
47
48
49 ### Prerequisites
50
51 No action required.
52
53 ### Configuration
54
55 #### Options
56
57 At least one option ('clock synchronization state', 'time offset') needs to be enabled for this collector to run.
58
59 <details open><summary>Config options</summary>
60
61
62
63 | Option | Description | Default | Required |
64 |:-----|:------------|:--------|:---------:|
65 | update every | Data collection frequency. | 1 | no |
66 | clock synchronization state | Make chart showing system clock synchronization state. | yes | yes |
67 | time offset | Make chart showing computed time offset between local system and reference clock | yes | yes |
68
69
70 </details>
71
72
73
74 #### via File
75
76 The configuration file name for this integration is `netdata.conf`.
77 Configuration for this specific integration is located in the `[plugin:timex]` section within that file.
78
79 The file format is a modified INI syntax. The general structure is:
80
81 ```ini
82 [section1]
83 option1 = some value
84 option2 = some other value
85
86 [section2]
87 option3 = some third value
88 ```
89 You can edit the configuration file using the [`edit-config`](https://github.com/netdata/netdata/blob/master/docs/netdata-agent/configuration/README.md#edit-configuration-files) script from the
90 Netdata [config directory](https://github.com/netdata/netdata/blob/master/docs/netdata-agent/configuration/README.md#locate-your-config-directory).
91
92 ```bash
93 cd /etc/netdata 2>/dev/null || cd /opt/netdata/etc/netdata
94 sudo ./edit-config netdata.conf
95 ```
96
97 ##### Examples
98
99 ###### Basic
100
101 A basic configuration example.
102
103 <details open><summary>Config</summary>
104
105 ```yaml
106 [plugin:timex]
107 update every = 1
108 clock synchronization state = yes
109 time offset = yes
110
111 ```
112 </details>
113
114
115
116 ## Alerts
117
118
119 The following alerts are available:
120
121 | Alert name | On metric | Description |
122 |:------------|:----------|:------------|
123 | [ system_clock_sync_state ](https://github.com/netdata/netdata/blob/master/src/health/health.d/timex.conf) | system.clock_sync_state | when set to 0, the system kernel believes the system clock is not properly synchronized to a reliable server |
124
125
126 ## Metrics
127
128 Metrics grouped by *scope*.
129
130 The scope defines the instance that the metric belongs to. An instance is uniquely identified by a set of labels.
131
132
133
134 ### Per Timex instance
135
136 These metrics refer to the entire monitored application.
137
138 This scope has no labels.
139
140 Metrics:
141
142 | Metric | Dimensions | Unit |
143 |:------|:----------|:----|
144 | system.clock_sync_state | state | state |
145 | system.clock_status | unsync, clockerr | status |
146 | system.clock_sync_offset | offset | milliseconds |
147
148