[libvirt] [PATCH 14/29] storage: introduce virtstoraged daemon

Daniel P. Berrangé berrange at redhat.com
Thu Jul 11 16:05:01 UTC 2019


The virtstoraged daemon will be responsible for providing the storage API
driver functionality. The storage driver is still loaded by the main
libvirtd daemon at this stage, so virtstoraged must not be running at
the same time.

Signed-off-by: Daniel P. Berrangé <berrange at redhat.com>
---
 .gitignore                  |  1 +
 libvirt.spec.in             |  1 +
 src/storage/Makefile.inc.am | 14 ++++++++++++++
 3 files changed, 16 insertions(+)

diff --git a/.gitignore b/.gitignore
index c92400b7d8..4c5c0ba732 100644
--- a/.gitignore
+++ b/.gitignore
@@ -167,6 +167,7 @@
 /src/virtlogd
 /src/virtnetworkd
 /src/virtsecretd
+/src/virtstoraged
 /src/virt-guest-shutdown.target
 /tests/*.log
 /tests/*.pid
diff --git a/libvirt.spec.in b/libvirt.spec.in
index 78a9965b52..453c640b5e 100644
--- a/libvirt.spec.in
+++ b/libvirt.spec.in
@@ -1610,6 +1610,7 @@ exit 0
 %files daemon-driver-storage
 
 %files daemon-driver-storage-core
+%attr(0755, root, root) %{_sbindir}/virtstoraged
 %attr(0755, root, root) %{_libexecdir}/libvirt_parthelper
 %{_libdir}/%{name}/connection-driver/libvirt_driver_storage.so
 %{_libdir}/%{name}/storage-backend/libvirt_storage_backend_fs.so
diff --git a/src/storage/Makefile.inc.am b/src/storage/Makefile.inc.am
index 538709256d..9e58bccbe4 100644
--- a/src/storage/Makefile.inc.am
+++ b/src/storage/Makefile.inc.am
@@ -368,6 +368,20 @@ libvirt_storage_backend_vstorage_la_LIBADD = \
 	$(NULL)
 endif WITH_STORAGE_VSTORAGE
 
+sbin_PROGRAMS += virtstoraged
+
+virtstoraged_SOURCES = $(REMOTE_DAEMON_SOURCES)
+virtstoraged_CFLAGS = \
+       $(REMOTE_DAEMON_CFLAGS) \
+       -DSOCK_NAME="\"virtstoraged-sock\"" \
+       -DSOCK_NAME_RO="\"virtstoraged-sock-ro\"" \
+       -DSOCK_NAME_ADMIN="\"virtstoraged-admin-sock\"" \
+       -DDAEMON_NAME="\"virtstoraged\"" \
+       -DMODULE_NAME="\"storage\"" \
+       $(NULL)
+virtstoraged_LDFLAGS = $(REMOTE_DAEMON_LDFLAGS)
+virtstoraged_LDADD = $(REMOTE_DAEMON_LDADD)
+
 if WITH_STORAGE_DISK
 libexec_PROGRAMS += libvirt_parthelper
 
-- 
2.21.0




More information about the libvir-list mailing list