On Tue, Feb 9, 2021 at 12:09 AM Jim Fehlig <jfehlig(a)suse.com> wrote:
Hi All,
I received a report [1] and verified that virtproxyd*.socket files have broken
syntax. E.g. from virtproxyd.socket
[Unit]
Description=Libvirt proxy local socket
Before=virtproxyd.service
libvirtd.socket libvirtd-ro.socket libvirtd-admin.socket libvirtd-tcp.socket
libvirtd-tls.socket
virtproxyd.socket should 'Conflicts' with the libvirtd sockets. I suspect this
regressed in the switch to meson. I checked a libvirt 6.0.0 installation and
indeed it has
Conflicts=libvirtd.socket libvirtd-ro.socket libvirtd-admin.socket
libvirtd-tcp.socket libvirtd-tls.socket
I blame it on Monday and my mind stuck in the weekend, but I spent too much time
trying to figure out how those socket files are generated before writing this
mail. It would be much appreciated if someone can give me a nudge in the right
direction :-).
*point*
-> src/remote/meson.build
227 virt_daemon_units += {
228 'service': 'virtproxyd',
229 'service_in': files('virtproxyd.service.in'),
230 'name': 'Libvirt proxy',
231 'sockprefix': 'libvirt',
232 'sockets': [ 'main', 'ro', 'admin',
'tcp', 'tls' ],
233 'deps': libvirtd_socket_conflicts,
234 }
-> src/meson.build
195 # virt_daemon_units:
196 # generate libvirt daemon systemd unit files
197 # * service - name of the service (required)
198 # * service_in - service source file (required)
199 # * name - socket description (required)
200 # * sockprefix - socket prefix name (required)
201 # * sockets - array of additional sockets (optional, default [
'main', 'ro', 'admin' ])
202 # * socket_$name_in - additional socket source files (optional,
default remote/libvirtd.socket.in )
203 # * deps - socket dependencies (optional, default '')
204 # * conflicts - if the service conflicts with libvirtd
(optional, true)
205 virt_daemon_units = []
...
792 foreach unit : virt_daemon_units
793 unit_conf = configuration_data()
794 unit_conf.set('runstatedir', runstatedir)
795 unit_conf.set('sbindir', sbindir)
796 unit_conf.set('sysconfdir', sysconfdir)
797 unit_conf.set('name', unit['name'])
798 unit_conf.set('service', unit['service'])
799 unit_conf.set('sockprefix', unit['sockprefix'])
800 unit_conf.set('deps', unit.get('deps', ''))
801 if conf.has('WITH_POLKIT')
802 unit_conf.set('mode', '0666')
803 else
804 unit_conf.set('mode', '0600')
805 endif
...
Also see:
https://gitlab.com/libvirt/libvirt/-/commit/dd4f2c73ad7f9fc0eae5325d5bf57...
So if not just an error/mistake somewhere, then setting
socket_$name_in and providing such a file with your needs could be a
start
--
Christian Ehrhardt
Staff Engineer, Ubuntu Server
Canonical Ltd