diff --git a/man/rules/meson.build b/man/rules/meson.build index d2818423964..4fe9ca17b83 100644 --- a/man/rules/meson.build +++ b/man/rules/meson.build @@ -1143,7 +1143,8 @@ manpages = [ '8', ['systemd-udevd', 'systemd-udevd-control.socket', - 'systemd-udevd-kernel.socket'], + 'systemd-udevd-kernel.socket', + 'systemd-udevd-varlink.socket'], ''], ['systemd-update-done.service', '8', ['systemd-update-done'], ''], ['systemd-update-utmp.service', diff --git a/man/systemd-udevd.service.xml b/man/systemd-udevd.service.xml index c781765e1cf..ad0be5bdab2 100644 --- a/man/systemd-udevd.service.xml +++ b/man/systemd-udevd.service.xml @@ -20,6 +20,7 @@ systemd-udevd.service systemd-udevd-control.socket systemd-udevd-kernel.socket + systemd-udevd-varlink.socket systemd-udevd Device event managing daemon @@ -28,6 +29,7 @@ systemd-udevd.service systemd-udevd-control.socket systemd-udevd-kernel.socket + systemd-udevd-varlink.socket /usr/lib/systemd/systemd-udevd diff --git a/man/udevadm.xml b/man/udevadm.xml index 8923bc70fe2..13cf106d876 100644 --- a/man/udevadm.xml +++ b/man/udevadm.xml @@ -677,7 +677,7 @@ Note that systemd-udevd.service contains and so as a result, this option restarts systemd-udevd. If you want to stop systemd-udevd.service, please use the following: - systemctl stop systemd-udevd-control.socket systemd-udevd-kernel.socket systemd-udevd.service + systemctl stop systemd-udevd-control.socket systemd-udevd-kernel.socket systemd-udevd-varlink.socket systemd-udevd.service diff --git a/units/initrd-udevadm-cleanup-db.service b/units/initrd-udevadm-cleanup-db.service index bc444736fdf..6c0a1e16ae6 100644 --- a/units/initrd-udevadm-cleanup-db.service +++ b/units/initrd-udevadm-cleanup-db.service @@ -11,8 +11,8 @@ Description=Cleanup udev Database DefaultDependencies=no AssertPathExists=/etc/initrd-release -Conflicts=systemd-udevd.service systemd-udevd-control.socket systemd-udevd-kernel.socket systemd-udev-trigger.service systemd-udev-settle.service -After=systemd-udevd.service systemd-udevd-control.socket systemd-udevd-kernel.socket systemd-udev-trigger.service systemd-udev-settle.service +Conflicts=systemd-udevd.service systemd-udevd-control.socket systemd-udevd-kernel.socket systemd-udevd-varlink.socket systemd-udev-trigger.service systemd-udev-settle.service +After=systemd-udevd.service systemd-udevd-control.socket systemd-udevd-kernel.socket systemd-udevd-varlink.socket systemd-udev-trigger.service systemd-udev-settle.service Before=initrd-switch-root.target [Service] diff --git a/units/meson.build b/units/meson.build index f6d661da975..805991dfe49 100644 --- a/units/meson.build +++ b/units/meson.build @@ -732,6 +732,10 @@ units = [ 'file' : 'systemd-udevd-kernel.socket', 'symlinks' : ['sockets.target.wants/'], }, + { + 'file' : 'systemd-udevd-varlink.socket', + 'symlinks' : ['sockets.target.wants/'], + }, { 'file' : 'systemd-udevd.service.in', 'symlinks' : ['sysinit.target.wants/'], diff --git a/units/systemd-udev-trigger.service b/units/systemd-udev-trigger.service index cb1e4f9fea5..0ea1a4bd49a 100644 --- a/units/systemd-udev-trigger.service +++ b/units/systemd-udev-trigger.service @@ -12,7 +12,7 @@ Description=Coldplug All udev Devices Documentation=man:udev(7) man:systemd-udevd.service(8) DefaultDependencies=no Wants=systemd-udevd.service -After=systemd-udevd-kernel.socket systemd-udevd-control.socket +After=systemd-udevd-kernel.socket systemd-udevd-control.socket systemd-udevd-varlink.socket Before=sysinit.target ConditionPathIsReadWrite=/sys diff --git a/units/systemd-udevd-varlink.socket b/units/systemd-udevd-varlink.socket new file mode 100644 index 00000000000..94fee15b082 --- /dev/null +++ b/units/systemd-udevd-varlink.socket @@ -0,0 +1,22 @@ +# SPDX-License-Identifier: LGPL-2.1-or-later +# +# This file is part of systemd. +# +# systemd is free software; you can redistribute it and/or modify it +# under the terms of the GNU Lesser General Public License as published by +# the Free Software Foundation; either version 2.1 of the License, or +# (at your option) any later version. + +[Unit] +Description=udev Varlink Socket +Documentation=man:systemd-udevd-varlink.socket(8) man:udev(7) +DefaultDependencies=no +Before=sockets.target +ConditionPathIsReadWrite=/sys + +[Socket] +Service=systemd-udevd.service +ListenStream=/run/udev/io.systemd.Udev +FileDescriptorName=varlink +SocketMode=0600 +RemoveOnStop=yes diff --git a/units/systemd-udevd.service.in b/units/systemd-udevd.service.in index f4a44820880..13ec7088daa 100644 --- a/units/systemd-udevd.service.in +++ b/units/systemd-udevd.service.in @@ -23,7 +23,7 @@ DelegateSubgroup=udev Type=notify-reload # Note that udev will reset the value internally for its workers OOMScoreAdjust=-1000 -Sockets=systemd-udevd-control.socket systemd-udevd-kernel.socket +Sockets=systemd-udevd-control.socket systemd-udevd-kernel.socket systemd-udevd-varlink.socket Restart=always RestartSec=0 ExecStart={{LIBEXECDIR}}/systemd-udevd