]> git.ipfire.org Git - thirdparty/systemd.git/blame - man/udevadm.xml
sd-device: add API for triggering synthetic uevents with UUID
[thirdparty/systemd.git] / man / udevadm.xml
CommitLineData
514094f9 1<?xml version='1.0'?>
3a54a157 2<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
12b42c76 3 "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
db9ecf05 4<!-- SPDX-License-Identifier: LGPL-2.1-or-later -->
f48f7543 5
c94c581c
YW
6<refentry id="udevadm"
7 xmlns:xi="http://www.w3.org/2001/XInclude">
8
63749b1a 9 <refentryinfo>
225cb03b 10 <title>udevadm</title>
d3a2386d 11 <productname>systemd</productname>
63749b1a 12 </refentryinfo>
225cb03b 13
63749b1a
KS
14 <refmeta>
15 <refentrytitle>udevadm</refentrytitle>
16 <manvolnum>8</manvolnum>
63749b1a 17 </refmeta>
225cb03b 18
63749b1a
KS
19 <refnamediv>
20 <refname>udevadm</refname><refpurpose>udev management tool</refpurpose>
21 </refnamediv>
225cb03b 22
63749b1a
KS
23 <refsynopsisdiv>
24 <cmdsynopsis>
25 <command>udevadm</command>
26 <arg><option>--debug</option></arg>
27 <arg><option>--version</option></arg>
28 <arg><option>--help</option></arg>
29 </cmdsynopsis>
30 <cmdsynopsis>
c94c581c 31 <command>udevadm info <optional>options</optional> <optional>devpath</optional></command>
63749b1a
KS
32 </cmdsynopsis>
33 <cmdsynopsis>
c94c581c 34 <command>udevadm trigger <optional>options</optional> <optional>devpath</optional></command>
63749b1a
KS
35 </cmdsynopsis>
36 <cmdsynopsis>
37 <command>udevadm settle <optional>options</optional></command>
38 </cmdsynopsis>
39 <cmdsynopsis>
c94c581c 40 <command>udevadm control <replaceable>option</replaceable></command>
63749b1a
KS
41 </cmdsynopsis>
42 <cmdsynopsis>
43 <command>udevadm monitor <optional>options</optional></command>
44 </cmdsynopsis>
45 <cmdsynopsis>
46 <command>udevadm test <optional>options</optional> <replaceable>devpath</replaceable></command>
47 </cmdsynopsis>
d7867b31
KS
48 <cmdsynopsis>
49 <command>udevadm test-builtin <optional>options</optional> <replaceable>command</replaceable> <replaceable>devpath</replaceable></command>
50 </cmdsynopsis>
63749b1a 51 </refsynopsisdiv>
225cb03b 52
63749b1a 53 <refsect1><title>Description</title>
124b48b0
ZJS
54 <para><command>udevadm</command> expects a command and command
55 specific options. It controls the runtime behavior of
56 <command>systemd-udevd</command>, requests kernel events, manages
57 the event queue, and provides simple debugging mechanisms.</para>
63749b1a 58 </refsect1>
225cb03b 59
80877656 60 <refsect1><title>Options</title>
63749b1a
KS
61 <variablelist>
62 <varlistentry>
c94c581c 63 <term><option>-d</option></term>
63749b1a
KS
64 <term><option>--debug</option></term>
65 <listitem>
35a44646
YW
66 <para>Print debug messages to standard error. This option is implied in <command>udevadm test</command> and
67 <command>udevadm test-builtin</command> commands.</para>
63749b1a
KS
68 </listitem>
69 </varlistentry>
c94c581c 70
c94c581c 71 <xi:include href="standard-options.xml" xpointer="help" />
63749b1a 72 </variablelist>
225cb03b 73
80877656
ZJS
74 <refsect2><title>udevadm info
75 <arg choice="opt"><replaceable>options</replaceable></arg>
3c79311a 76 <arg choice="opt" rep="repeat"><replaceable>devpath</replaceable>|<replaceable>file</replaceable>|<replaceable>unit</replaceable></arg>
80877656
ZJS
77 </title>
78
b6854081
ZJS
79 <para>Query the udev database for device information.</para>
80
3c79311a
ZJS
81 <para>Positional arguments should be used to specify one or more devices. Each one may be a device name
82 (in which case it must start with <filename>/dev/</filename>), a sys path (in which case it must start
83 with <filename>/sys/</filename>), or a systemd device unit name (in which case it must end with
b6854081
ZJS
84 <literal>.device</literal>, see
85 <citerefentry><refentrytitle>systemd.device</refentrytitle><manvolnum>5</manvolnum></citerefentry>).
86 </para>
87
63749b1a
KS
88 <variablelist>
89 <varlistentry>
7643ac9a
ZJS
90 <term><option>-q</option></term>
91 <term><option>--query=<replaceable>TYPE</replaceable></option></term>
63749b1a 92 <listitem>
b6854081 93 <para>Query the database for the specified type of device data.
7643ac9a
ZJS
94 Valid <replaceable>TYPE</replaceable>s are:
95 <constant>name</constant>, <constant>symlink</constant>,
96 <constant>path</constant>, <constant>property</constant>,
124b48b0 97 <constant>all</constant>.</para>
63749b1a
KS
98 </listitem>
99 </varlistentry>
b6854081 100
63749b1a 101 <varlistentry>
7643ac9a
ZJS
102 <term><option>-p</option></term>
103 <term><option>--path=<replaceable>DEVPATH</replaceable></option></term>
63749b1a 104 <listitem>
3b121157
ZJS
105 <para>The <filename>/sys/</filename> path of the device to query, e.g.
106 <filename><optional>/sys/</optional>/class/block/sda</filename>. This option is an alternative to
b6854081
ZJS
107 the positional argument with a <filename>/sys/</filename> prefix. <command>udevadm info
108 --path=/class/block/sda</command> is equivalent to <command>udevadm info
109 /sys/class/block/sda</command>.</para>
63749b1a
KS
110 </listitem>
111 </varlistentry>
112 <varlistentry>
7643ac9a
ZJS
113 <term><option>-n</option></term>
114 <term><option>--name=<replaceable>FILE</replaceable></option></term>
63749b1a 115 <listitem>
124b48b0 116 <para>The name of the device node or a symlink to query,
3b121157 117 e.g. <filename><optional>/dev/</optional>/sda</filename>. This option is an alternative to the
b6854081
ZJS
118 positional argument with a <filename>/dev/</filename> prefix. <command>udevadm info
119 --name=sda</command> is equivalent to <command>udevadm info /dev/sda</command>.</para>
63749b1a
KS
120 </listitem>
121 </varlistentry>
122 <varlistentry>
7643ac9a 123 <term><option>-r</option></term>
63749b1a
KS
124 <term><option>--root</option></term>
125 <listitem>
4f5d327a
KS
126 <para>Print absolute paths in <command>name</command> or <command>symlink</command>
127 query.</para>
4ec9c3e7
KS
128 </listitem>
129 </varlistentry>
63749b1a 130 <varlistentry>
7643ac9a 131 <term><option>-a</option></term>
63749b1a
KS
132 <term><option>--attribute-walk</option></term>
133 <listitem>
134 <para>Print all sysfs properties of the specified device that can be used
135 in udev rules to match the specified device. It prints all devices
136 along the chain, up to the root of sysfs that can be used in udev rules.</para>
137 </listitem>
138 </varlistentry>
dc1791a9 139 <varlistentry>
7643ac9a 140 <term><option>-x</option></term>
dc1791a9
KS
141 <term><option>--export</option></term>
142 <listitem>
f0c29bbf
YW
143 <para>Print output as key/value pairs. Values are enclosed in single quotes.
144 This takes effects only when <option>--query=property</option> or
145 <option>--device-id-of-file=<replaceable>FILE</replaceable></option> is specified.</para>
dc1791a9
KS
146 </listitem>
147 </varlistentry>
148 <varlistentry>
7643ac9a
ZJS
149 <term><option>-P</option></term>
150 <term><option>--export-prefix=<replaceable>NAME</replaceable></option></term>
dc1791a9 151 <listitem>
f0c29bbf
YW
152 <para>Add a prefix to the key name of exported values.
153 This implies <option>--export</option>.</para>
dc1791a9
KS
154 </listitem>
155 </varlistentry>
63749b1a 156 <varlistentry>
7643ac9a
ZJS
157 <term><option>-d</option></term>
158 <term><option>--device-id-of-file=<replaceable>FILE</replaceable></option></term>
63749b1a 159 <listitem>
f0c29bbf
YW
160 <para>Print major/minor numbers of the underlying device, where the file lives on.
161 If this is specified, all positional arguments are ignored.</para>
63749b1a
KS
162 </listitem>
163 </varlistentry>
164 <varlistentry>
7643ac9a 165 <term><option>-e</option></term>
63749b1a
KS
166 <term><option>--export-db</option></term>
167 <listitem>
168 <para>Export the content of the udev database.</para>
169 </listitem>
170 </varlistentry>
9ead6627 171 <varlistentry>
7643ac9a 172 <term><option>-c</option></term>
9ead6627
KS
173 <term><option>--cleanup-db</option></term>
174 <listitem>
175 <para>Cleanup the udev database.</para>
176 </listitem>
177 </varlistentry>
ae760f4b
YW
178 <varlistentry>
179 <term><option>-w<optional>SECONDS</optional></option></term>
180 <term><option>--wait-for-initialization<optional>=SECONDS</optional></option></term>
181 <listitem>
182 <para>Wait for device to be initialized. If argument <replaceable>SECONDS</replaceable>
183 is not specified, the default is to wait forever.</para>
184 </listitem>
185 </varlistentry>
c94c581c 186
c94c581c 187 <xi:include href="standard-options.xml" xpointer="help" />
63749b1a 188 </variablelist>
205013c8
LP
189
190 <para>The generated output shows the current device database entry in a terse format. Each line shown
191 is prefixed with one of the following characters:</para>
192
193 <table>
194 <title><command>udevadm info</command> output prefixes</title>
195 <tgroup cols='2' align='left' colsep='1' rowsep='1'>
196 <colspec colname="prefix" />
197 <colspec colname="meaning" />
198 <thead>
199 <row>
200 <entry>Prefix</entry>
201 <entry>Meaning</entry>
202 </row>
203 </thead>
204 <tbody>
205 <row>
206 <entry><literal>P:</literal></entry>
207 <entry>Device path in <filename>/sys/</filename></entry>
208 </row>
209 <row>
210 <entry><literal>N:</literal></entry>
211 <entry>Kernel device node name</entry>
212 </row>
213 <row>
214 <entry><literal>L:</literal></entry>
215 <entry>Device node symlink priority</entry>
216 </row>
217 <row>
218 <entry><literal>S:</literal></entry>
219 <entry>Device node symlink</entry>
220 </row>
221 <row>
222 <entry><literal>E:</literal></entry>
223 <entry>Device property</entry>
224 </row>
225 </tbody>
226 </tgroup>
227 </table>
63749b1a 228 </refsect2>
225cb03b 229
80877656
ZJS
230 <refsect2><title>udevadm trigger
231 <arg choice="opt"><replaceable>options</replaceable></arg>
a9bc94e5 232 <arg choice="opt"><replaceable>devpath</replaceable>|<replaceable>file</replaceable>|<replaceable>unit</replaceable></arg>
b6854081 233 </title>
63749b1a 234 <para>Request device events from the kernel. Primarily used to replay events at system coldplug time.</para>
b6854081 235
5b3b0733 236 <para>Takes device specifications as positional arguments. See the description of <command>info</command>
b6854081
ZJS
237 above.</para>
238
63749b1a
KS
239 <variablelist>
240 <varlistentry>
7643ac9a 241 <term><option>-v</option></term>
63749b1a
KS
242 <term><option>--verbose</option></term>
243 <listitem>
244 <para>Print the list of devices which will be triggered.</para>
245 </listitem>
246 </varlistentry>
247 <varlistentry>
7643ac9a 248 <term><option>-n</option></term>
63749b1a
KS
249 <term><option>--dry-run</option></term>
250 <listitem>
251 <para>Do not actually trigger the event.</para>
252 </listitem>
253 </varlistentry>
6c99c265
YW
254 <varlistentry>
255 <term><option>-q</option></term>
256 <term><option>--quiet</option></term>
257 <listitem>
258 <para>Suppress error logging in triggering events.</para>
259 </listitem>
260 </varlistentry>
63749b1a 261 <varlistentry>
7643ac9a
ZJS
262 <term><option>-t</option></term>
263 <term><option>--type=<replaceable>TYPE</replaceable></option></term>
63749b1a
KS
264 <listitem>
265 <para>Trigger a specific type of devices. Valid types are:
864fde8a 266 <command>devices</command>, <command>subsystems</command>.
63749b1a
KS
267 The default value is <command>devices</command>.</para>
268 </listitem>
269 </varlistentry>
270 <varlistentry>
7643ac9a
ZJS
271 <term><option>-c</option></term>
272 <term><option>--action=<replaceable>ACTION</replaceable></option></term>
63749b1a 273 <listitem>
cd648ae1
YW
274 <para>Type of event to be triggered. Possible actions are <literal>add</literal>,
275 <literal>remove</literal>, <literal>change</literal>, <literal>move</literal>,
276 <literal>online</literal>, <literal>offline</literal>, <literal>bind</literal>,
6d22bd87
YW
277 and <literal>unbind</literal>. Also, the special value <literal>help</literal> can be used
278 to list the possible actions. The default value is <literal>change</literal>.
279 </para>
63749b1a
KS
280 </listitem>
281 </varlistentry>
282 <varlistentry>
7643ac9a
ZJS
283 <term><option>-s</option></term>
284 <term><option>--subsystem-match=<replaceable>SUBSYSTEM</replaceable></option></term>
63749b1a 285 <listitem>
7643ac9a 286 <para>Trigger events for devices which belong to a
a9bc94e5
YW
287 matching subsystem. This option supports shell style pattern matching.
288 When this option is specified more than once, then each matching result is ORed, that is,
289 all the devices in each subsystem are triggered.</para>
63749b1a
KS
290 </listitem>
291 </varlistentry>
292 <varlistentry>
7643ac9a
ZJS
293 <term><option>-S</option></term>
294 <term><option>--subsystem-nomatch=<replaceable>SUBSYSTEM</replaceable></option></term>
63749b1a
KS
295 <listitem>
296 <para>Do not trigger events for devices which belong to a matching subsystem. This option
a9bc94e5
YW
297 supports shell style pattern matching. When this option is specified more than once,
298 then each matching result is ANDed, that is, devices which do not match all specified
299 subsystems are triggered.</para>
63749b1a
KS
300 </listitem>
301 </varlistentry>
302 <varlistentry>
7643ac9a
ZJS
303 <term><option>-a</option></term>
304 <term><option>--attr-match=<replaceable>ATTRIBUTE</replaceable>=<replaceable>VALUE</replaceable></option></term>
63749b1a 305 <listitem>
a9bc94e5
YW
306 <para>Trigger events for devices with a matching sysfs attribute. If a value is specified along
307 with the attribute name, the content of the attribute is matched against the given value using
308 shell style pattern matching. If no value is specified, the existence of the sysfs attribute is
309 checked. When this option is specified multiple times, then each matching result is ANDed,
310 that is, only devices which have all specified attributes are triggered.</para>
63749b1a
KS
311 </listitem>
312 </varlistentry>
313 <varlistentry>
7643ac9a
ZJS
314 <term><option>-A</option></term>
315 <term><option>--attr-nomatch=<replaceable>ATTRIBUTE</replaceable>=<replaceable>VALUE</replaceable></option></term>
63749b1a 316 <listitem>
a9bc94e5
YW
317 <para>Do not trigger events for devices with a matching sysfs attribute. If a value is specified
318 along with the attribute name, the content of the attribute is matched against the given value
319 using shell style pattern matching. If no value is specified, the existence of the sysfs attribute
320 is checked. When this option is specified multiple times, then each matching result is ANDed,
321 that is, only devices which have none of the specified attributes are triggered.</para>
63749b1a
KS
322 </listitem>
323 </varlistentry>
324 <varlistentry>
7643ac9a
ZJS
325 <term><option>-p</option></term>
326 <term><option>--property-match=<replaceable>PROPERTY</replaceable>=<replaceable>VALUE</replaceable></option></term>
63749b1a 327 <listitem>
a9bc94e5
YW
328 <para>Trigger events for devices with a matching property value. This option supports shell style
329 pattern matching. When this option is specified more than once, then each matching result is ORed,
330 that is, devices which have one of the specified properties are triggered.</para>
63749b1a
KS
331 </listitem>
332 </varlistentry>
333 <varlistentry>
7643ac9a
ZJS
334 <term><option>-g</option></term>
335 <term><option>--tag-match=<replaceable>PROPERTY</replaceable></option></term>
63749b1a 336 <listitem>
a9bc94e5
YW
337 <para>Trigger events for devices with a matching tag. When this option is specified multiple times,
338 then each matching result is ANDed, that is, devices which have all specified tags are triggered.</para>
63749b1a
KS
339 </listitem>
340 </varlistentry>
341 <varlistentry>
7643ac9a 342 <term><option>-y</option></term>
a9bc94e5 343 <term><option>--sysname-match=<replaceable>NAME</replaceable></option></term>
63749b1a 344 <listitem>
a9bc94e5 345 <para>Trigger events for devices for which the last component (i.e. the filename) of the
3b121157 346 <filename>/sys/</filename> path matches the specified <replaceable>PATH</replaceable>. This option
a9bc94e5
YW
347 supports shell style pattern matching. When this option is specified more than once, then each
348 matching result is ORed, that is, all devices which have any of the specified
349 <replaceable>NAME</replaceable> are triggered.</para>
63749b1a
KS
350 </listitem>
351 </varlistentry>
80877656
ZJS
352 <varlistentry>
353 <term><option>--name-match=<replaceable>NAME</replaceable></option></term>
354 <listitem>
a9bc94e5 355 <para>Trigger events for devices with a matching device path. When this option is specified more than once,
5b3b0733 356 then each matching result is ORed, that is, all specified devices are triggered.</para>
80877656
ZJS
357 </listitem>
358 </varlistentry>
b05211fa 359 <varlistentry>
7643ac9a
ZJS
360 <term><option>-b</option></term>
361 <term><option>--parent-match=<replaceable>SYSPATH</replaceable></option></term>
b05211fa 362 <listitem>
a9bc94e5 363 <para>Trigger events for all children of a given device. When this option is specified more than once,
5b3b0733 364 then each matching result is ORed, that is, all children of each specified device are triggered.</para>
7643ac9a 365 </listitem>
792cc203
MH
366 </varlistentry>
367 <varlistentry>
368 <term><option>-w</option></term>
369 <term><option>--settle</option></term>
370 <listitem>
371 <para>Apart from triggering events, also waits for those events to
372 finish. Note that this is different from calling <command>udevadm
373 settle</command>. <command>udevadm settle</command> waits for all
374 events to finish. This option only waits for events triggered by
375 the same command to finish.</para>
376 </listitem>
7643ac9a 377 </varlistentry>
2001622c
YW
378 <varlistentry>
379 <term><option>--wait-daemon[=<replaceable>SECONDS</replaceable>]</option></term>
380 <listitem>
381 <para>Before triggering uevents, wait for systemd-udevd daemon to be initialized.
382 Optionally takes timeout value. Default timeout is 5 seconds. This is equivalent to invoke
383 invoking <command>udevadm control --ping</command> before <command>udevadm trigger</command>.</para>
384 </listitem>
385 </varlistentry>
c94c581c 386
c94c581c 387 <xi:include href="standard-options.xml" xpointer="help" />
63749b1a 388 </variablelist>
80877656 389
5b3b0733
YW
390 <para>In addition, optional positional arguments can be used
391 to specify device names or sys paths. They must start with
3b121157 392 <filename>/dev/</filename> or <filename>/sys/</filename>
80877656 393 respectively.</para>
63749b1a 394 </refsect2>
225cb03b 395
80877656
ZJS
396 <refsect2><title>udevadm settle
397 <arg choice="opt"><replaceable>options</replaceable></arg>
398 </title>
63749b1a
KS
399 <para>Watches the udev event queue, and exits if all current events are handled.</para>
400 <variablelist>
401 <varlistentry>
7643ac9a
ZJS
402 <term><option>-t</option></term>
403 <term><option>--timeout=<replaceable>SECONDS</replaceable></option></term>
63749b1a 404 <listitem>
7643ac9a
ZJS
405 <para>Maximum number of seconds to wait for the event
406 queue to become empty. The default value is 120 seconds. A
407 value of 0 will check if the queue is empty and always
2233c270
YK
408 return immediately. A non-zero value will return an exit
409 code of 0 if queue became empty before timeout was reached,
410 non-zero otherwise.</para>
63749b1a
KS
411 </listitem>
412 </varlistentry>
63749b1a 413 <varlistentry>
7643ac9a
ZJS
414 <term><option>-E</option></term>
415 <term><option>--exit-if-exists=<replaceable>FILE</replaceable></option></term>
63749b1a
KS
416 <listitem>
417 <para>Stop waiting if file exists.</para>
418 </listitem>
419 </varlistentry>
c94c581c 420
c94c581c 421 <xi:include href="standard-options.xml" xpointer="help" />
63749b1a 422 </variablelist>
18a38822
ZJS
423
424 <para>See
425 <citerefentry><refentrytitle>systemd-udev-settle.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>
426 for more information.</para>
63749b1a 427 </refsect2>
225cb03b 428
c94c581c 429 <refsect2><title>udevadm control <replaceable>option</replaceable></title>
63749b1a
KS
430 <para>Modify the internal state of the running udev daemon.</para>
431 <variablelist>
ff2c503d 432 <varlistentry>
bd8420c5 433 <term><option>-e</option></term>
ff2c503d
KS
434 <term><option>--exit</option></term>
435 <listitem>
6371db93
YW
436 <para>Signal and wait for systemd-udevd to exit. No option except for
437 <option>--timeout</option> can be specified after this option.
438 Note that <filename>systemd-udevd.service</filename> contains
439 <option>Restart=always</option> and so as a result, this option restarts systemd-udevd.
d0d7e102
YW
440 If you want to stop <filename>systemd-udevd.service</filename>, please use the following:
441 <programlisting>systemctl stop systemd-udevd-control.socket systemd-udevd-kernel.socket systemd-udevd.service</programlisting>
442 </para>
ff2c503d
KS
443 </listitem>
444 </varlistentry>
63749b1a 445 <varlistentry>
7643ac9a 446 <term><option>-l</option></term>
027f96c8 447 <term><option>--log-level=<replaceable>value</replaceable></option></term>
63749b1a 448 <listitem>
e03234a1
ZJS
449 <para>Set the internal log level of
450 <filename>systemd-udevd</filename>. Valid values are the
451 numerical syslog priorities or their textual
452 representations: <option>emerg</option>,
453 <option>alert</option>, <option>crit</option>,
454 <option>err</option>, <option>warning</option>,
455 <option>notice</option>, <option>info</option>, and
456 <option>debug</option>.</para>
63749b1a
KS
457 </listitem>
458 </varlistentry>
459 <varlistentry>
7643ac9a 460 <term><option>-s</option></term>
63749b1a
KS
461 <term><option>--stop-exec-queue</option></term>
462 <listitem>
f13b388f 463 <para>Signal systemd-udevd to stop executing new events. Incoming events
63749b1a
KS
464 will be queued.</para>
465 </listitem>
466 </varlistentry>
467 <varlistentry>
7643ac9a 468 <term><option>-S</option></term>
63749b1a
KS
469 <term><option>--start-exec-queue</option></term>
470 <listitem>
f13b388f 471 <para>Signal systemd-udevd to enable the execution of events.</para>
63749b1a
KS
472 </listitem>
473 </varlistentry>
474 <varlistentry>
7643ac9a 475 <term><option>-R</option></term>
7c85d636 476 <term><option>--reload</option></term>
63749b1a 477 <listitem>
f13b388f 478 <para>Signal systemd-udevd to reload the rules files and other databases like the kernel
7c85d636
KS
479 module index. Reloading rules and databases does not apply any changes to already
480 existing devices; the new configuration will only be applied to new events.</para>
63749b1a
KS
481 </listitem>
482 </varlistentry>
483 <varlistentry>
7643ac9a 484 <term><option>-p</option></term>
63749b1a
KS
485 <term><option>--property=<replaceable>KEY</replaceable>=<replaceable>value</replaceable></option></term>
486 <listitem>
487 <para>Set a global property for all events.</para>
488 </listitem>
489 </varlistentry>
490 <varlistentry>
7643ac9a 491 <term><option>-m</option></term>
87d55ff6 492 <term><option>--children-max=</option><replaceable>value</replaceable></term>
63749b1a 493 <listitem>
f13b388f 494 <para>Set the maximum number of events, systemd-udevd will handle at the
63749b1a
KS
495 same time.</para>
496 </listitem>
497 </varlistentry>
a82340cc
YW
498 <varlistentry>
499 <term><option>--ping</option></term>
500 <listitem>
501 <para>Send a ping message to systemd-udevd and wait for the reply. This may be useful to check that
502 systemd-udevd daemon is running.</para>
503 </listitem>
504 </varlistentry>
ff2c503d 505 <varlistentry>
c94c581c 506 <term><option>-t</option></term>
ff2c503d
KS
507 <term><option>--timeout=</option><replaceable>seconds</replaceable></term>
508 <listitem>
7e505069 509 <para>The maximum number of seconds to wait for a reply from systemd-udevd.</para>
ff2c503d
KS
510 </listitem>
511 </varlistentry>
c94c581c 512
c94c581c 513 <xi:include href="standard-options.xml" xpointer="help" />
63749b1a
KS
514 </variablelist>
515 </refsect2>
225cb03b 516
80877656
ZJS
517 <refsect2><title>udevadm monitor
518 <arg choice="opt"><replaceable>options</replaceable></arg>
519 </title>
63749b1a
KS
520 <para>Listens to the kernel uevents and events sent out by a udev rule
521 and prints the devpath of the event to the console. It can be used to analyze the
522 event timing, by comparing the timestamps of the kernel uevent and the udev event.
523 </para>
524 <variablelist>
525 <varlistentry>
7643ac9a 526 <term><option>-k</option></term>
63749b1a
KS
527 <term><option>--kernel</option></term>
528 <listitem>
529 <para>Print the kernel uevents.</para>
530 </listitem>
531 </varlistentry>
532 <varlistentry>
7643ac9a 533 <term><option>-u</option></term>
63749b1a
KS
534 <term><option>--udev</option></term>
535 <listitem>
536 <para>Print the udev event after the rule processing.</para>
537 </listitem>
538 </varlistentry>
539 <varlistentry>
7643ac9a 540 <term><option>-p</option></term>
63749b1a
KS
541 <term><option>--property</option></term>
542 <listitem>
543 <para>Also print the properties of the event.</para>
544 </listitem>
545 </varlistentry>
546 <varlistentry>
7643ac9a 547 <term><option>-s</option></term>
63749b1a
KS
548 <term><option>--subsystem-match=<replaceable>string[/string]</replaceable></option></term>
549 <listitem>
a9bc94e5
YW
550 <para>Filter kernel uevents and udev events by subsystem[/devtype]. Only events with a matching subsystem value will pass.
551 When this option is specified more than once, then each matching result is ORed, that is, all devices in the specified
552 subsystems are monitored.</para>
63749b1a
KS
553 </listitem>
554 </varlistentry>
555 <varlistentry>
7643ac9a 556 <term><option>-t</option></term>
63749b1a
KS
557 <term><option>--tag-match=<replaceable>string</replaceable></option></term>
558 <listitem>
a9bc94e5
YW
559 <para>Filter udev events by tag. Only udev events with a given tag attached will pass.
560 When this option is specified more than once, then each matching result is ORed, that is, devices which have one of the
561 specified tags are monitored.</para>
63749b1a
KS
562 </listitem>
563 </varlistentry>
c94c581c 564
c94c581c 565 <xi:include href="standard-options.xml" xpointer="help" />
63749b1a
KS
566 </variablelist>
567 </refsect2>
225cb03b 568
80877656
ZJS
569 <refsect2><title>udevadm test
570 <arg choice="opt"><replaceable>options</replaceable></arg>
571 <arg><replaceable>devpath</replaceable></arg>
572 </title>
63749b1a
KS
573 <para>Simulate a udev event run for the given device, and print debug output.</para>
574 <variablelist>
575 <varlistentry>
7643ac9a 576 <term><option>-a</option></term>
6d22bd87 577 <term><option>--action=<replaceable>ACTION</replaceable></option></term>
63749b1a 578 <listitem>
e148cbc5
YW
579 <para>Type of event to be simulated. Possible actions are <literal>add</literal>,
580 <literal>remove</literal>, <literal>change</literal>, <literal>move</literal>,
581 <literal>online</literal>, <literal>offline</literal>, <literal>bind</literal>,
582 and <literal>unbind</literal>. Also, the special value <literal>help</literal> can be used
583 to list the possible actions. The default value is <literal>add</literal>.</para>
63749b1a
KS
584 </listitem>
585 </varlistentry>
586 <varlistentry>
7643ac9a 587 <term><option>-N</option></term>
124b48b0 588 <term><option>--resolve-names=<constant>early</constant>|<constant>late</constant>|<constant>never</constant></option></term>
63749b1a 589 <listitem>
124b48b0
ZJS
590 <para>Specify when udevadm should resolve names of users
591 and groups. When set to <constant>early</constant> (the
72f4d966
JE
592 default), names will be resolved when the rules are
593 parsed. When set to <constant>late</constant>, names will
124b48b0 594 be resolved for every event. When set to
72f4d966 595 <constant>never</constant>, names will never be resolved
124b48b0 596 and all devices will be owned by root.</para>
63749b1a
KS
597 </listitem>
598 </varlistentry>
c94c581c 599
c94c581c 600 <xi:include href="standard-options.xml" xpointer="help" />
63749b1a
KS
601 </variablelist>
602 </refsect2>
d7867b31 603
80877656
ZJS
604 <refsect2><title>udevadm test-builtin
605 <arg choice="opt"><replaceable>options</replaceable></arg>
606 <arg><replaceable>command</replaceable></arg>
607 <arg><replaceable>devpath</replaceable></arg>
608 </title>
7643ac9a
ZJS
609 <para>Run a built-in command <replaceable>COMMAND</replaceable>
610 for device <replaceable>DEVPATH</replaceable>, and print debug
611 output.</para>
d7867b31 612 <variablelist>
c94c581c 613 <xi:include href="standard-options.xml" xpointer="help" />
d7867b31
KS
614 </variablelist>
615 </refsect2>
63749b1a 616 </refsect1>
225cb03b 617
63749b1a
KS
618 <refsect1>
619 <title>See Also</title>
620 <para><citerefentry>
621 <refentrytitle>udev</refentrytitle><manvolnum>7</manvolnum>
7d06ef0a 622 </citerefentry>,
63749b1a 623 <citerefentry>
b79f817b 624 <refentrytitle>systemd-udevd.service</refentrytitle><manvolnum>8</manvolnum>
63749b1a
KS
625 </citerefentry></para>
626 </refsect1>
627</refentry>