-diff -urp LVM2.2.02.179.orig/tools/dmsetup.c LVM2.2.02.179/tools/dmsetup.c
---- LVM2.2.02.179.orig/tools/dmsetup.c 2018-06-26 11:46:19.185819536 +0000
-+++ LVM2.2.02.179/tools/dmsetup.c 2018-06-26 11:48:27.746811873 +0000
-@@ -2579,6 +2579,7 @@ static int _export(CMD_ARGS)
+diff -urp LVM2.2.03.00.orig/libdm/dm-tools/dmsetup.c LVM2.2.03.00/libdm/dm-tools/dmsetup.c
+--- LVM2.2.03.00.orig/libdm/dm-tools/dmsetup.c 2018-10-21 14:36:09.255416609 +0000
++++ LVM2.2.03.00/libdm/dm-tools/dmsetup.c 2018-10-21 14:37:55.506416609 +0000
+@@ -2568,6 +2568,7 @@ static int _export(CMD_ARGS)
const char *name = NULL;
const char *uuid = NULL;
struct dm_info info;
if (names)
name = names->name;
-@@ -2648,6 +2649,28 @@ static int _export(CMD_ARGS)
+@@ -2637,6 +2638,28 @@ static int _export(CMD_ARGS)
printf("\n");
}
-diff -urp LVM2.2.02.179.orig/man/dmsetup.8_main LVM2.2.02.179/man/dmsetup.8_main
---- LVM2.2.02.179.orig/man/dmsetup.8_main 2018-06-26 11:40:19.080841000 +0000
-+++ LVM2.2.02.179/man/dmsetup.8_main 2018-06-26 11:46:19.184819536 +0000
-@@ -59,6 +59,14 @@ dmsetup \(em low level logical volume ma
- .
- .HP
- .B dmsetup
-+.de CMD_EXPORT
-+. BR export
-+. RI [ device_name ]
-+..
-+.CMD_EXPORT
-+.
-+.HP
-+.B dmsetup
- .de CMD_HELP
- . BR help
- . RB [ -c | -C | --columns ]
-@@ -651,6 +659,9 @@ device. Device names on output can be cu
- \fBdevname\fP (map name for device-mapper devices, equal to blkdevname otherwise).
- .
- .HP
-+.CMD_EXPORT
-+Outputs information in key/value format to be imported by other programs.
-+.HP
- .CMD_HELP
- .br
- Outputs a summary of the commands available, optionally including
-diff -urp LVM2.2.02.179.orig/tools/dmsetup.c LVM2.2.02.179/tools/dmsetup.c
---- LVM2.2.02.179.orig/tools/dmsetup.c 2018-06-26 11:40:23.358840745 +0000
-+++ LVM2.2.02.179/tools/dmsetup.c 2018-06-26 11:46:19.185819536 +0000
-@@ -2568,6 +2568,93 @@ out:
+diff -urp LVM2.2.03.00.orig/libdm/dm-tools/dmsetup.c LVM2.2.03.00/libdm/dm-tools/dmsetup.c
+--- LVM2.2.03.00.orig/libdm/dm-tools/dmsetup.c 2018-10-21 13:36:20.379416609 +0000
++++ LVM2.2.03.00/libdm/dm-tools/dmsetup.c 2018-10-21 14:20:38.626416609 +0000
+@@ -2557,6 +2557,93 @@ out:
return r;
}
/* Show target names and their version numbers */
static int _targets(CMD_ARGS)
{
-@@ -6243,6 +6330,7 @@ static struct command _dmsetup_commands[
+@@ -6232,6 +6319,7 @@ static struct command _dmsetup_commands[
{"stats", "<command> [<options>] [<device>...]", 1, -1, 1, 1, _stats},
{"status", "[<device>...] [--noflush] [--target <target_type>]", 0, -1, 2, 0, _status},
{"table", "[<device>...] [--concise] [--target <target_type>] [--showkeys]", 0, -1, 2, 0, _status},
{"wait", "<device> [<event_nr>] [--noflush]", 0, 2, 0, 0, _wait},
{"mknodes", "[<device>...]", 0, -1, 1, 0, _mknodes},
{"mangle", "[<device>...]", 0, -1, 1, 0, _mangle},
+diff -urp LVM2.2.03.00.orig/man/dmsetup.8_main LVM2.2.03.00/man/dmsetup.8_main
+--- LVM2.2.03.00.orig/man/dmsetup.8_main 2018-10-21 13:36:20.380416609 +0000
++++ LVM2.2.03.00/man/dmsetup.8_main 2018-10-21 14:20:38.625416609 +0000
+@@ -59,6 +59,14 @@ dmsetup \(em low level logical volume ma
+ .
+ .HP
+ .B dmsetup
++.de CMD_EXPORT
++. BR export
++. RI [ device_name ]
++..
++.CMD_EXPORT
++.
++.HP
++.B dmsetup
+ .de CMD_HELP
+ . BR help
+ . RB [ -c | -C | --columns ]
+@@ -651,6 +659,9 @@ device. Device names on output can be cu
+ \fBdevname\fP (map name for device-mapper devices, equal to blkdevname otherwise).
+ .
+ .HP
++.CMD_EXPORT
++Outputs information in key/value format to be imported by other programs.
++.HP
+ .CMD_HELP
+ .br
+ Outputs a summary of the commands available, optionally including
-diff -urp LVM2.2.02.179.orig/lib/commands/toolcontext.c LVM2.2.02.179/lib/commands/toolcontext.c
---- LVM2.2.02.179.orig/lib/commands/toolcontext.c 2018-06-26 11:40:23.355840745 +0000
-+++ LVM2.2.02.179/lib/commands/toolcontext.c 2018-06-26 11:47:16.136816141 +0000
-@@ -1438,6 +1438,7 @@ int lvm_register_segtype(struct segtype_
+diff -urp LVM2.2.03.00.orig/lib/commands/toolcontext.c LVM2.2.03.00/lib/commands/toolcontext.c
+--- LVM2.2.03.00.orig/lib/commands/toolcontext.c 2018-10-21 14:34:49.832416609 +0000
++++ LVM2.2.03.00/lib/commands/toolcontext.c 2018-10-21 14:34:56.826416609 +0000
+@@ -1298,6 +1298,7 @@ int lvm_register_segtype(struct segtype_
return 1;
}
static int _init_single_segtype(struct cmd_context *cmd,
struct segtype_library *seglib)
{
-@@ -1455,6 +1456,7 @@ static int _init_single_segtype(struct c
+@@ -1315,6 +1316,7 @@ static int _init_single_segtype(struct c
return lvm_register_segtype(seglib, segtype);
}
+++ /dev/null
-diff -urp LVM2.2.02.177.orig/daemons/clvmd/clvmd.c LVM2.2.02.177/daemons/clvmd/clvmd.c
---- LVM2.2.02.177.orig/daemons/clvmd/clvmd.c 2017-12-18 20:44:34.000000000 +0000
-+++ LVM2.2.02.177/daemons/clvmd/clvmd.c 2018-01-26 16:40:07.504228217 +0000
-@@ -992,8 +992,8 @@ static void main_loop(int cmd_timeout)
- }
- }
-
-- /* Select timed out. Check for clients that have been waiting too long for a response */
-- if (select_status == 0) {
-+ /* Check for clients that have been waiting too long for a response */
-+ if (select_status >= 0) {
- time_t the_time = time(NULL);
-
- for (thisfd = &local_client_head; thisfd; thisfd = thisfd->next) {
+++ /dev/null
-diff -urp LVM2.2.02.179.orig/lib/commands/toolcontext.c LVM2.2.02.179/lib/commands/toolcontext.c
---- LVM2.2.02.179.orig/lib/commands/toolcontext.c 2018-06-18 05:24:22.000000000 +0000
-+++ LVM2.2.02.179/lib/commands/toolcontext.c 2018-06-26 11:40:23.355840745 +0000
-@@ -1827,10 +1827,10 @@ struct cmd_context *create_toolcontext(u
- #ifdef M_MMAP_MAX
- mallopt(M_MMAP_MAX, 0);
- #endif
--
-+#ifdef __dietlibc__
- if (!setlocale(LC_ALL, ""))
- log_very_verbose("setlocale failed");
--
-+#endif
- #ifdef INTL_PACKAGE
- bindtextdomain(INTL_PACKAGE, LOCALEDIR);
- #endif
-diff -urp LVM2.2.02.179.orig/lib/config/config.c LVM2.2.02.179/lib/config/config.c
---- LVM2.2.02.179.orig/lib/config/config.c 2018-06-18 05:24:22.000000000 +0000
-+++ LVM2.2.02.179/lib/config/config.c 2018-06-26 11:40:23.356840745 +0000
-@@ -44,6 +44,10 @@ static const char *_config_source_names[
- [CONFIG_FILE_SPECIAL] = "special purpose"
- };
-
-+#ifdef __dietlibc__
-+typedef char* caddr_t __attribute_dontuse__;
-+#endif
-+
- struct config_file {
- off_t st_size;
- char *filename;
-diff -urp LVM2.2.02.179.orig/lib/metadata/pv.c LVM2.2.02.179/lib/metadata/pv.c
---- LVM2.2.02.179.orig/lib/metadata/pv.c 2018-06-18 05:24:22.000000000 +0000
-+++ LVM2.2.02.179/lib/metadata/pv.c 2018-06-26 11:40:23.356840745 +0000
-@@ -17,6 +17,12 @@
- #include "metadata.h"
- #include "lvmcache.h"
-
-+#ifdef __dietlibc__
-+# ifndef UINT64_MAX
-+# define UINT64_MAX __UINT64_MAX__
-+# endif
-+#endif
-+
- /*
- * FIXME: Check for valid handle before dereferencing field or log error?
- */
-diff -urp LVM2.2.02.179.orig/lib/misc/lib.h LVM2.2.02.179/lib/misc/lib.h
---- LVM2.2.02.179.orig/lib/misc/lib.h 2018-06-18 05:24:22.000000000 +0000
-+++ LVM2.2.02.179/lib/misc/lib.h 2018-06-26 11:40:23.356840745 +0000
-@@ -93,4 +93,20 @@
-
- #include <unistd.h>
-
-+#ifdef __dietlibc__
-+# include <strings.h>
-+# include <limits.h>
-+# if __WORDSIZE == 64
-+# define INT64_C(c) c ## L
-+# else
-+# define INT64_C(c) c ## LL
-+# endif
-+# define UINT32_C(c) c ## U
-+# if __WORDSIZE == 64
-+# define UINT64_C(c) c ## UL
-+# else
-+# define UINT64_C(c) c ## ULL
-+# endif
-+#endif
-+
- #endif
-diff -urp LVM2.2.02.179.orig/lib/report/report.c LVM2.2.02.179/lib/report/report.c
---- LVM2.2.02.179.orig/lib/report/report.c 2018-06-18 05:24:22.000000000 +0000
-+++ LVM2.2.02.179/lib/report/report.c 2018-06-26 11:40:23.357840745 +0000
-@@ -29,6 +29,11 @@
- #include <float.h> /* DBL_MAX */
- #include <time.h>
-
-+#ifdef __dietlibc__
-+#define __UINT64_C(c) c ## ULL
-+# define UINT64_MAX (__UINT64_C(18446744073709551615))
-+#endif
-+
- struct lvm_report_object {
- struct volume_group *vg;
- struct lv_with_info_and_seg_status *lvdm;
-diff -urp LVM2.2.02.179.orig/libdm/libdevmapper.h LVM2.2.02.179/libdm/libdevmapper.h
---- LVM2.2.02.179.orig/libdm/libdevmapper.h 2018-06-18 05:24:22.000000000 +0000
-+++ LVM2.2.02.179/libdm/libdevmapper.h 2018-06-26 11:40:23.357840745 +0000
-@@ -251,6 +251,10 @@ int dm_task_set_add_node(struct dm_task
- /*
- * Control read_ahead.
- */
-+#ifdef __dietlibc__
-+# define UINT32_MAX (4294967295U)
-+#endif
-+
- #define DM_READ_AHEAD_AUTO UINT32_MAX /* Use kernel default readahead */
- #define DM_READ_AHEAD_NONE 0 /* Disable readahead */
-
-diff -urp LVM2.2.02.179.orig/tools/dmsetup.c LVM2.2.02.179/tools/dmsetup.c
---- LVM2.2.02.179.orig/tools/dmsetup.c 2018-06-18 05:24:22.000000000 +0000
-+++ LVM2.2.02.179/tools/dmsetup.c 2018-06-26 11:40:23.358840745 +0000
-@@ -37,6 +37,23 @@
- # include <libudev.h>
- #endif
-
-+#ifdef __dietlibc__
-+# include <limits.h>
-+# if __WORDSIZE == 64
-+# define INT64_C(c) c ## L
-+# else
-+# define INT64_C(c) c ## LL
-+# endif
-+# define UINT32_C(c) c ## U
-+# if __WORDSIZE == 64
-+# define UINT64_C(c) c ## UL
-+# else
-+# define UINT64_C(c) c ## ULL
-+# endif
-+#define canonicalize_file_name(x) realpath(x, NULL)
-+#endif
-+#include <strings.h>
-+
- /* FIXME Unused so far */
- #undef HAVE_SYS_STATVFS_H
-
-diff -urp LVM2.2.02.179.orig/tools/Makefile.in LVM2.2.02.179/tools/Makefile.in
---- LVM2.2.02.179.orig/tools/Makefile.in 2018-06-26 11:33:19.629866001 +0000
-+++ LVM2.2.02.179/tools/Makefile.in 2018-06-26 11:44:55.383824531 +0000
-@@ -127,13 +127,14 @@ CFLAGS_dmsetup.o += $(UDEV_CFLAGS) $(EXT
-
- dmsetup: dmsetup.o $(top_builddir)/libdm/libdevmapper.$(LIB_SUFFIX)
- @echo " [CC] $@"
-- $(Q) $(CC) $(CFLAGS) $(LDFLAGS) $(EXTRA_EXEC_LDFLAGS) $(ELDFLAGS) \
-+ $(Q) $(CC) $(CFLAGS) -L$(interfacebuilddir) -L$(top_builddir)/libdm \
-+ $(LDFLAGS) $(EXTRA_EXEC_LDFLAGS) $(ELDFLAGS) \
- -o $@ dmsetup.o -ldevmapper $(LIBS)
-
- dmsetup.static: dmsetup.o $(interfacebuilddir)/libdevmapper.a
- @echo " [CC] $@"
-- $(Q) $(CC) $(CFLAGS) $(LDFLAGS) -static -L$(interfacebuilddir) \
-- -o $@ dmsetup.o -ldevmapper $(M_LIBS) $(PTHREAD_LIBS) $(STATIC_LIBS) $(LIBS)
-+ $(Q) $(CC) $(CFLAGS) -static -L$(interfacebuilddir) $(LDFLAGS) \
-+ -o $@ dmsetup.o -ldevmapper $(M_LIBS) $(PTHREAD_LIBS) $(STATIC_LIBS) $(LIBS) $(DIETLIBC_LIBS)
-
- all: device-mapper
-
-@@ -143,7 +144,7 @@ INCLUDES += -I$(top_builddir)/tools
-
- lvm: $(OBJECTS) lvm.o $(top_builddir)/lib/liblvm-internal.a
- @echo " [CC] $@"
-- $(Q) $(CC) $(CFLAGS) $(LDFLAGS) $(EXTRA_EXEC_LDFLAGS) $(ELDFLAGS) -o $@ $(OBJECTS) lvm.o \
-+ $(Q) $(CC) $(CFLAGS) -L$(interfacebuilddir) $(LDFLAGS) $(EXTRA_EXEC_LDFLAGS) $(ELDFLAGS) -o $@ $(OBJECTS) lvm.o \
- $(LVMLIBS) $(READLINE_LIBS) $(LIBS)
-
- DEFS_man-generator.o += -DMAN_PAGE_GENERATOR
-@@ -163,7 +164,7 @@ endif
- lvm.static: $(OBJECTS) lvm-static.o $(top_builddir)/lib/liblvm-internal.a $(interfacebuilddir)/libdevmapper.a
- @echo " [CC] $@"
- $(Q) $(CC) $(CFLAGS) $(LDFLAGS) -static -L$(interfacebuilddir) -o $@ \
-- $(OBJECTS) lvm-static.o $(LVMLIBS) $(STATIC_LIBS) $(LIBS)
-+ $(OBJECTS) lvm-static.o $(LVMLIBS) $(STATIC_LIBS) $(LIBS) $(PTHREAD_LIBS) $(DIETLIBC_LIBS)
-
- liblvm2cmd.a: $(top_builddir)/lib/liblvm-internal.a $(OBJECTS) lvmcmdlib.o lvm2cmd.o
- @echo " [AR] $@"
-diff -urp LVM2.2.02.179.orig/tools/tools.h LVM2.2.02.179/tools/tools.h
---- LVM2.2.02.179.orig/tools/tools.h 2018-06-18 05:24:22.000000000 +0000
-+++ LVM2.2.02.179/tools/tools.h 2018-06-26 11:40:23.359840745 +0000
-@@ -47,6 +47,21 @@
- #include <ctype.h>
- #include <sys/types.h>
-
-+#ifdef __dietlibc__
-+# include <limits.h>
-+# if __WORDSIZE == 64
-+# define INT64_C(c) c ## L
-+# else
-+# define INT64_C(c) c ## LL
-+# endif
-+# define UINT32_C(c) c ## U
-+# if __WORDSIZE == 64
-+# define UINT64_C(c) c ## UL
-+# else
-+# define UINT64_C(c) c ## ULL
-+# endif
-+#endif
-+
- #define CMD_LEN 256
- #define MAX_ARGS 64
-
--- /dev/null
+diff -urp LVM2.2.03.00.orig/daemons/lvmlockd/Makefile.in LVM2.2.03.00/daemons/lvmlockd/Makefile.in
+--- LVM2.2.03.00.orig/daemons/lvmlockd/Makefile.in 2018-10-21 15:23:18.299416609 +0000
++++ LVM2.2.03.00/daemons/lvmlockd/Makefile.in 2018-10-21 15:23:35.952416609 +0000
+@@ -15,7 +15,7 @@ srcdir = @srcdir@
+ top_srcdir = @top_srcdir@
+ top_builddir = @top_builddir@
+
+-USE_SD_NOTIFY=yes
++USE_SD_NOTIFY=no
+
+ SOURCES = lvmlockd-core.c
+
-diff -ur LVM2.2.02.179.orig/configure.ac LVM2.2.02.179/configure.ac
---- LVM2.2.02.179.orig/configure.ac 2018-06-18 05:24:22.000000000 +0000
-+++ LVM2.2.02.179/configure.ac 2018-07-11 15:49:58.540700530 +0000
-@@ -643,8 +643,7 @@
+diff -urp LVM2.2.03.00.orig/configure.ac LVM2.2.03.00/configure.ac
+--- LVM2.2.03.00.orig/configure.ac 2018-10-21 14:35:34.502416609 +0000
++++ LVM2.2.03.00/configure.ac 2018-10-21 14:35:49.006416609 +0000
+@@ -681,8 +681,7 @@ pkg_config_init() {
################################################################################
AC_MSG_CHECKING(for default run directory)
-diff -urp LVM2.2.02.179.orig/tools/Makefile.in LVM2.2.02.179/tools/Makefile.in
---- LVM2.2.02.179.orig/tools/Makefile.in 2018-06-18 05:24:22.000000000 +0000
-+++ LVM2.2.02.179/tools/Makefile.in 2018-06-26 11:33:19.629866001 +0000
-@@ -97,6 +97,9 @@ endif
+diff -urp LVM2.2.03.00.orig/tools/Makefile.in LVM2.2.03.00/tools/Makefile.in
+--- LVM2.2.03.00.orig/tools/Makefile.in 2018-10-10 10:11:03.000000000 +0000
++++ LVM2.2.03.00/tools/Makefile.in 2018-10-21 13:35:25.885416609 +0000
+@@ -91,6 +91,9 @@ endif
- LVMLIBS = $(LVMINTERNAL_LIBS) -ldevmapper -laio
+ LVMLIBS = $(LVMINTERNAL_LIBS) -laio
LIB_VERSION = $(LIB_VERSION_LVM)
+ifneq ("@STATIC_LINK@", "yes")
+ LVMLIBS += -lselinux -lsepol
-diff -urp LVM2.2.02.179.orig/configure.ac LVM2.2.02.179/configure.ac
---- LVM2.2.02.179.orig/configure.ac 2018-06-26 11:40:19.088840999 +0000
-+++ LVM2.2.02.179/configure.ac 2018-06-26 11:51:45.460800089 +0000
-@@ -397,7 +397,7 @@ dnl -- thin_check needs-check flag
+diff -urp LVM2.2.03.00.orig/configure.ac LVM2.2.03.00/configure.ac
+--- LVM2.2.03.00.orig/configure.ac 2018-10-21 14:38:26.196416609 +0000
++++ LVM2.2.03.00/configure.ac 2018-10-21 14:38:47.235416609 +0000
+@@ -388,7 +388,7 @@ dnl -- thin_check needs-check flag
AC_ARG_ENABLE(thin_check_needs_check,
AC_HELP_STRING([--disable-thin_check_needs_check],
[required if thin_check version is < 0.3.0]),
# Test if necessary thin tools are available
# if not - use plain defaults and warn user
-@@ -412,7 +412,7 @@ case "$THIN" in
+@@ -403,7 +403,7 @@ case "$THIN" in
THIN_CONFIGURE_WARN=y
fi
fi
THIN_CHECK_VSN=`"$THIN_CHECK_CMD" -V 2>/dev/null`
THIN_CHECK_VSN_MAJOR=`echo "$THIN_CHECK_VSN" | $AWK -F '.' '{print $1}'`
THIN_CHECK_VSN_MINOR=`echo "$THIN_CHECK_VSN" | $AWK -F '.' '{print $2}'`
-@@ -425,6 +425,8 @@ case "$THIN" in
+@@ -416,6 +416,8 @@ case "$THIN" in
AC_MSG_WARN([$THIN_CHECK_CMD: Old version "$THIN_CHECK_VSN" found])
THIN_CHECK_VERSION_WARN=y
THIN_CHECK_NEEDS_CHECK=no
fi
fi
# Empty means a config way to ignore thin dumping
-@@ -511,7 +513,7 @@ dnl -- cache_check needs-check flag
+@@ -502,7 +504,7 @@ dnl -- cache_check needs-check flag
AC_ARG_ENABLE(cache_check_needs_check,
AC_HELP_STRING([--disable-cache_check_needs_check],
[required if cache_check version is < 0.5]),
# Test if necessary cache tools are available
# if not - use plain defaults and warn user
-@@ -526,7 +528,7 @@ case "$CACHE" in
+@@ -517,7 +519,7 @@ case "$CACHE" in
CACHE_CONFIGURE_WARN=y
fi
fi
$CACHE_CHECK_CMD -V 2>/dev/null >conftest.tmp
read -r CACHE_CHECK_VSN < conftest.tmp
IFS=.- read -r CACHE_CHECK_VSN_MAJOR CACHE_CHECK_VSN_MINOR CACHE_CHECK_VSN_PATCH LEFTOVER < conftest.tmp
-@@ -550,6 +552,8 @@ case "$CACHE" in
+@@ -541,6 +543,8 @@ case "$CACHE" in
AC_MSG_WARN([$CACHE_CHECK_CMD: Old version "$CACHE_CHECK_VSN" does not support new cache format V2])
CACHE_CHECK_VERSION_WARN=y
fi
-diff -urp LVM2.2.02.177.orig/scripts/blk_availability_init_red_hat.in LVM2.2.02.177/scripts/blk_availability_init_red_hat.in
---- LVM2.2.02.177.orig/scripts/blk_availability_init_red_hat.in 2017-12-18 20:44:35.000000000 +0000
-+++ LVM2.2.02.177/scripts/blk_availability_init_red_hat.in 2018-01-29 11:24:46.012906501 +0000
+diff -urp LVM2.2.03.00.orig/scripts/blk_availability_init_red_hat.in LVM2.2.03.00/scripts/blk_availability_init_red_hat.in
+--- LVM2.2.03.00.orig/scripts/blk_availability_init_red_hat.in 2018-10-21 14:21:38.112416609 +0000
++++ LVM2.2.03.00/scripts/blk_availability_init_red_hat.in 2018-10-21 14:21:53.152416609 +0000
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
+ exit 3
;;
esac
-diff -urp LVM2.2.02.177.orig/scripts/clvmd_init_red_hat.in LVM2.2.02.177/scripts/clvmd_init_red_hat.in
---- LVM2.2.02.177.orig/scripts/clvmd_init_red_hat.in 2017-12-18 20:44:35.000000000 +0000
-+++ LVM2.2.02.177/scripts/clvmd_init_red_hat.in 2018-01-29 12:54:59.156583852 +0000
-@@ -4,7 +4,7 @@
- #
- # chkconfig: - 24 76
- # description: Cluster daemon for userland logical volume management tools.
--# pidfile: @CLVMD_PIDFILE@
-+# pidfile: /var/run/clvmd.pid
- #
- # For Red-Hat-based distributions such as Fedora, RHEL, CentOS.
- #
-@@ -18,15 +18,12 @@
-
- . /etc/rc.d/init.d/functions
-
--DAEMON=clvmd
-+DAEMON="clvmd"
-
--sbindir="@SBINDIR@"
--usrsbindir="@USRSBINDIR@"
--
--lvm_vgchange="$sbindir/vgchange"
--lvm_vgs="$sbindir/vgs"
--lvm_vgscan="$sbindir/vgscan"
--lvm_lvs="$sbindir/lvs"
-+lvm_vgchange="/sbin/vgchange"
-+lvm_vgs="/sbin/vgs"
-+lvm_vgscan="/sbin/vgscan"
-+lvm_lvs="/sbin/lvs"
-
- CLVMDOPTS="-T30"
-
-@@ -50,20 +47,11 @@ clustered_active_lvs() {
- "$lvm_lvs" --noheadings -o lv_name -S 'vg_clustered=1 && lv_active!=""' 2>/dev/null
- }
-
--rh_status() {
-- status "$DAEMON"
--}
--
--rh_status_q() {
-- rh_status >/dev/null 2>&1
--}
--
- start()
- {
-- if ! rh_status_q; then
-- echo -n "Starting $DAEMON: "
-- "$usrsbindir/$DAEMON" $CLVMDOPTS || return $?
-- echo
-+ if ! status $DAEMON 1>/dev/null 2>&1; then
-+ msg_starting "$DAEMON"
-+ "$DAEMON" $CLVMDOPTS || return $?
- fi
-
- # Refresh local cache.
-@@ -82,74 +70,60 @@ start()
- # unnecessary warnings.
-
- "$lvm_vgscan" > /dev/null 2>&1
--
-- action "Activating VG(s):" "$lvm_vgchange" -aay $LVM_VGS || return $?
--
-+ run_cmd "Activating VG(s):" ${lvm_vgchange} -aay $LVM_VGS || return $?
- touch "$LOCK_FILE"
--
- return 0
- }
-
- wait_for_finish()
- {
- count=0
-- while [ "$count" -le "$CLVMD_STOP_TIMEOUT" ] && \
-- rh_status_q ]; do
-+ while [ "$count" -le "$CLVMD_STOP_TIMEOUT" ] && status $DAEMON 1>/dev/null 2>&1 ; do
- sleep 1
- count=$((count+1))
- done
--
-- ! rh_status_q
-+ ! status $DAEMON 1>/dev/null 2>&1
- }
-
- stop()
- {
-- rh_status_q || return 0
--
-+ status $DAEMON 1>/dev/null 2>&1 || return 0
- [ -z "$LVM_VGS" ] && LVM_VGS="$(clustered_vgs)"
- if [ -n "$LVM_VGS" ]; then
-- action "Deactivating clustered VG(s):" "$lvm_vgchange" -anl $LVM_VGS || return $?
-+ run_cmd "Deactivating clustered VG(s):" ${lvm_vgchange} -anl $LVM_VGS || return $?
- fi
--
-- action "Signaling $DAEMON to exit" kill -TERM "$(pidofproc "$DAEMON")" || return $?
-+ run_cmd "Signaling $DAEMON to exit" kill -TERM $(pidofproc "$DAEMON") || return $?
-
- # wait half second before we start the waiting loop or we will show
- # the loop more time than really necessary
- usleep 500000
-
- # clvmd could take some time to stop
-- rh_status_q && action "Waiting for $DAEMON to exit:" wait_for_finish
--
-- if rh_status_q; then
-- echo -n "$DAEMON failed to exit"
-- failure
-- echo
-+ status $DAEMON 1>/dev/null 2>&1 && run_cmd "Waiting for $DAEMON to exit:" wait_for_finish
-+ if status $DAEMON 1>/dev/null 2>&1; then
-+ fail
- return 1
- else
-- echo -n "$DAEMON terminated"
-- success
-- echo
-+ ok
- fi
--
- rm -f "$LOCK_FILE"
--
- return 0
- }
-
- reload() {
-- rh_status_q || exit 7
-- action "Reloading $DAEMON configuration: " "$usrsbindir/$DAEMON" -R || return $?
-+ status $DAEMON 1>/dev/null 2>&1 || exit 7
-+ run_cmd "Reloading $DAEMON configuration: " "$DAEMON" -R || return $?
- }
-
- restart() {
- # if stop fails, restart will return the error and not attempt
-- # another start. Even if start is protected by rh_status_q,
-+ # another start. Even if start is protected by status call,
- # that would avoid spawning another daemon, it would try to
- # reactivate the VGs.
-
- # Try to get clvmd to restart itself. This will preserve
- # exclusive LV locks
-- action "Restarting $DAEMON: " "$usrsbindir/$DAEMON" -S
-+ run_cmd "Restarting $DAEMON: " "$DAEMON" -S
-
- # If that fails then do a normal stop & restart
- if [ $? != 0 ]; then
-@@ -166,38 +140,39 @@ restart() {
- exit 4
- }
-
-+RETVAL=0
- # See how we were called.
- case "$1" in
- start)
- start
-- rtrn=$?
-+ RETVAL=$?
- ;;
-
- stop)
- stop
-- rtrn=$?
-+ RETVAL=$?
- ;;
-
- restart|force-reload)
- restart
-- rtrn=$?
-+ RETVAL=$?
- ;;
-
- condrestart|try-restart)
-- rh_status_q || exit 0
-+ status $DAEMON 1>/dev/null 2>&1 || exit 0
- restart
-- rtrn=$?
-+ RETVAL=$?
- ;;
-
- reload)
- reload
-- rtrn=$?
-+ RETVAL=$?
- ;;
-
- status)
-- rh_status
-- rtrn=$?
-- if [ "$rtrn" = 0 ]; then
-+ status $DAEMON
-+ RETVAL=$?
-+ if [ $RETVAL = 0 ]; then
- cvgs="$(clustered_vgs)"
- echo Clustered Volume Groups: ${cvgs:-"(none)"}
- clvs="$(clustered_active_lvs)"
-@@ -206,9 +181,9 @@ case "$1" in
- ;;
-
- *)
-- echo $"Usage: $0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload}"
-- rtrn=2
-+ msg_usage "$0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload}"
-+ RETVAL=2
- ;;
- esac
-
--exit $rtrn
-+exit $RETVAL
-diff -urp LVM2.2.02.177.orig/scripts/cmirrord_init_red_hat.in LVM2.2.02.177/scripts/cmirrord_init_red_hat.in
---- LVM2.2.02.177.orig/scripts/cmirrord_init_red_hat.in 2017-12-18 20:44:35.000000000 +0000
-+++ LVM2.2.02.177/scripts/cmirrord_init_red_hat.in 2018-01-29 11:28:49.069892013 +0000
+diff -urp LVM2.2.03.00.orig/scripts/cmirrord_init_red_hat.in LVM2.2.03.00/scripts/cmirrord_init_red_hat.in
+--- LVM2.2.03.00.orig/scripts/cmirrord_init_red_hat.in 2018-10-21 14:21:38.112416609 +0000
++++ LVM2.2.03.00/scripts/cmirrord_init_red_hat.in 2018-10-21 14:25:55.744416609 +0000
@@ -2,7 +2,7 @@
#
# chkconfig: - 22 78
-exit $rtrn
+exit $RETVAL
-diff -urp LVM2.2.02.177.orig/scripts/lvm2_lvmetad_init_red_hat.in LVM2.2.02.177/scripts/lvm2_lvmetad_init_red_hat.in
---- LVM2.2.02.177.orig/scripts/lvm2_lvmetad_init_red_hat.in 2017-12-18 20:44:35.000000000 +0000
-+++ LVM2.2.02.177/scripts/lvm2_lvmetad_init_red_hat.in 2018-01-29 11:30:04.229887533 +0000
-@@ -1,4 +1,4 @@
--#!/bin/bash
-+#!/bin/sh
- #
- # Copyright (C) 2012-2017 Red Hat, Inc. All rights reserved.
- #
-@@ -33,78 +33,84 @@
-
- . /etc/init.d/functions
-
--DAEMON=lvmetad
-+DAEMON="lvmetad"
-+NAME="LVM metadata daemon"
-
--sbindir="@SBINDIR@"
--
--LOCK_FILE="@DEFAULT_SYS_LOCK_DIR@/subsys/$DAEMON"
--PID_FILE="@LVMETAD_PIDFILE@"
--
--rh_status() {
-- status -p "$PID_FILE" "$DAEMON"
--}
--
--rh_status_q() {
-- rh_status >/dev/null 2>&1
--}
-+LOCK_FILE="/var/lock/subsys/lvm2-lvmetad"
-+PID_FILE="/var/run/lvmetad.pid"
-
- start()
- {
-- ret=0
-- action "Starting LVM metadata daemon:" "$sbindir/$DAEMON" || ret=$?
-- return $ret
-+ if [ -f "$LOCK_FILE" ]; then
-+ msg_already_running "$NAME"
-+ return
-+ fi
-+ msg_starting "$NAME"
-+ daemon "/sbin/$DAEMON" </dev/null
-+ RETVAL=$?
-+ [ "$RETVAL" -eq 0 ] && touch "$LOCK_FILE"
- }
-
- stop()
- {
-- ret=0
-- action "Signaling LVM metadata daemon to exit:" killproc -p "$PID_FILE" "$DAEMON" -TERM || ret=$?
-- return $ret
-+ if [ ! -f "$LOCK_FILE" ]; then
-+ msg_not_running "$NAME"
-+ return
-+ fi
-+ msg_stopping "$NAME"
-+ killproc --pidfile "$PID_FILE" "$DAEMON"
-+ rm -f "$LOCK_FILE"
-+}
-+
-+condrestart() {
-+ if [ ! -f "$LOCK_FILE" ]; then
-+ msg_not_running "$NAME"
-+ RETVAL=$1
-+ return
-+ fi
-+ stop
-+ start
- }
-
--rtrn=1
-+reload() {
-+ if [ ! -f "$LOCK_FILE" ]; then
-+ msg_not_running "$NAME"
-+ RETVAL=7
-+ return
-+ fi
-+ msg_reloading "$NAME"
-+ killproc "$DAEMON" -HUP
-+ RETVAL=$?
-+}
-
-+RETVAL=0
- # See how we were called.
- case "$1" in
- start)
-- rh_status_q && exit 0
- start
-- rtrn=$?
-- [ "$rtrn" = 0 ] && touch "$LOCK_FILE"
- ;;
-
-- stop|force-stop)
-- rh_status_q || exit 0
-+ stop)
- stop
-- rtrn=$?
-- [ "$rtrn" = 0 ] && rm -f "$LOCK_FILE"
- ;;
-
- restart)
-- if stop
-- then
-- start
-- fi
-- rtrn=$?
-+ stop
-+ start
- ;;
-
- condrestart|try-restart)
-- rh_status_q || exit 0
-- if stop
-- then
-- start
-- fi
-- rtrn=$?
-+ condrestart 0
- ;;
-
- status)
-- rh_status
-- rtrn=$?
-+ status $DAEMON
-+ exit $?
- ;;
-
- *)
-- echo $"Usage: $0 {start|stop|force-stop|restart|condrestart|try-restart|status}"
-+ msg_usage "$0 {start|stop|force-stop|restart|condrestart|try-restart|status}"
- ;;
- esac
-
--exit $rtrn
-+exit $RETVAL
-diff -urp LVM2.2.02.177.orig/scripts/lvm2_lvmpolld_init_red_hat.in LVM2.2.02.177/scripts/lvm2_lvmpolld_init_red_hat.in
---- LVM2.2.02.177.orig/scripts/lvm2_lvmpolld_init_red_hat.in 2017-12-18 20:44:35.000000000 +0000
-+++ LVM2.2.02.177/scripts/lvm2_lvmpolld_init_red_hat.in 2018-01-29 11:31:12.405883470 +0000
+diff -urp LVM2.2.03.00.orig/scripts/lvm2_lvmpolld_init_red_hat.in LVM2.2.03.00/scripts/lvm2_lvmpolld_init_red_hat.in
+--- LVM2.2.03.00.orig/scripts/lvm2_lvmpolld_init_red_hat.in 2018-10-21 14:21:38.112416609 +0000
++++ LVM2.2.03.00/scripts/lvm2_lvmpolld_init_red_hat.in 2018-10-21 14:25:59.004416609 +0000
@@ -1,6 +1,6 @@
-#!/bin/bash
+#!/bin/sh
-exit $rtrn
+exit $RETVAL
-diff -urp LVM2.2.02.177.orig/scripts/lvm2_monitoring_init_red_hat.in LVM2.2.02.177/scripts/lvm2_monitoring_init_red_hat.in
---- LVM2.2.02.177.orig/scripts/lvm2_monitoring_init_red_hat.in 2017-12-18 20:44:35.000000000 +0000
-+++ LVM2.2.02.177/scripts/lvm2_monitoring_init_red_hat.in 2018-01-29 11:33:20.925875809 +0000
+diff -urp LVM2.2.03.00.orig/scripts/lvm2_monitoring_init_red_hat.in LVM2.2.03.00/scripts/lvm2_monitoring_init_red_hat.in
+--- LVM2.2.03.00.orig/scripts/lvm2_monitoring_init_red_hat.in 2018-10-21 14:21:38.112416609 +0000
++++ LVM2.2.03.00/scripts/lvm2_monitoring_init_red_hat.in 2018-10-21 14:25:59.004416609 +0000
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
# note: dmeventd requires mirrors=internal)
#
# Conditional build:
-# - initrd stuff
-%bcond_with initrd # build initrd version
-%bcond_without uClibc # link initrd version with uClibc
-%bcond_with dietlibc # link initrd version with dietlibc
-%bcond_with glibc # link initrd version with static GLIBC
# - functionality
-%bcond_without cluster # disable all cluster support (clvmd&cmirrord)
-%bcond_without lvmetad # lvmetad (and lvmlockd)
+%bcond_without cluster # disable all cluster support (cmirrord)
%bcond_without lvmdbusd # lvmdbusd
%bcond_without lvmpolld # lvmpolld (and lvmlockd)
%bcond_without lvmlockd # lvmlockd
%bcond_without python2 # Python 2 binding
%bcond_without python3 # Python 3 binding and lvmdbusd
-# lvmlockd requires lvmetad and lvmpolld
-%if %{without lvmetad} || %{without lvmpolld}
-%undefine with_lvmpolld
-%endif
-
-# if one of the *libc is enabled disable default dietlibc
-%if %{with dietlibc} && %{with uClibc}
-%undefine with_dietlibc
-%endif
-# with glibc disables default dietlibc
-%if %{with glibc} && %{with dietlibc}
-%undefine with_dietlibc
-%endif
-# fallback is glibc if neither alternatives are enabled
-%if %{without dietlibc} && %{without uClibc}
-%define with_glibc 1
-%endif
# for convenience
%if %{without python}
%undefine with_python2
Summary: The new version of Logical Volume Manager for Linux
Summary(pl.UTF-8): Nowa wersja Logical Volume Managera dla Linuksa
Name: lvm2
-Version: 2.02.181
+Version: 2.03.00
Release: 1
License: GPL v2 and LGPL v2.1
Group: Applications/System
Source0: ftp://sources.redhat.com/pub/lvm2/LVM2.%{version}.tgz
-# Source0-md5: 7d6380d9a34981fd7b605eaa371295b3
-Source3: clvmd.sysconfig
+# Source0-md5: f63cc5feaadd3000138e73f7143ed370
Patch0: %{name}-selinux.patch
-Patch1: %{name}-diet.patch
-Patch2: device-mapper-dmsetup-export.patch
-Patch3: %{name}-tld_init.patch
-Patch4: dl-dlsym.patch
-Patch5: %{name}-run-dir.patch
-Patch6: %{name}-clvmd_cmd_timeout.patch
-Patch7: device-mapper-dmsetup-deps-export.patch
-Patch8: %{name}-thin.patch
+Patch1: device-mapper-dmsetup-export.patch
+Patch2: %{name}-tld_init.patch
+Patch3: dl-dlsym.patch
+Patch4: %{name}-run-dir.patch
+Patch5: device-mapper-dmsetup-deps-export.patch
+Patch6: %{name}-thin.patch
+Patch7: %{name}-no-systemd.patch
URL: http://www.sourceware.org/lvm2/
BuildRequires: autoconf >= 2.69
BuildRequires: automake
BuildRequires: rpmbuild(macros) >= 1.647
%{?with_sanlock:BuildRequires: sanlock-devel >= 3.3.0}
BuildRequires: udev-devel >= 1:176
-%if %{with initrd}
-%if %{with dietlibc}
-BuildRequires: dietlibc-static >= 2:0.32-7
-BuildConflicts: device-mapper-dietlibc
-%endif
-%if %{with glibc}
-%{?with_selinux:BuildRequires: libselinux-static}
-%{?with_selinux:BuildRequires: libsepol-static}
-%endif
-%{?with_glibc:BuildRequires: glibc-static}
-%{?with_uClibc:BuildRequires: uClibc-static >= 2:0.9.29}
-%endif
%if %{with cluster}
BuildRequires: corosync-devel
BuildRequires: dlm-devel >= 3.99.5
Requires: uname(release) >= 2.6
Suggests: thin-provisioning-tools >= 0.5.4
Obsoletes: lvm
+Obsoletes: lvm2-clvmd
Obsoletes: lvm2-systemd
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
# causes: undefined reference to `__stack_chk_fail_local'
%define filterout_c -fstack-protector
-# for some reason known only to rpm there must be "\\|" not "\|" here
-%define dietarch %(echo %{_target_cpu} | sed -e 's/i.86\\|pentium.\\|athlon/i386/;s/amd64/x86_64/;s/armv.*/arm/')
-%define dietlibdir %{_prefix}/lib/dietlibc/lib-%{dietarch}
-
-%define skip_post_check_so '.*libdevmapper-event-lvm2.so.*'
+%define skip_post_check_so '.*(libdevmapper-event.so|libdevmapper-event-lvm2.so).*'
%description
This package includes a number of utilities for creating, checking,
Pakiet ten zawiera narzędzia do tworzenia, sprawdzania i naprawiania
logicznych wolumenów dyskowych (LVM2).
-%package initrd
-Summary: The new version of Logical Volume Manager for Linux - initrd version
-Summary(pl.UTF-8): Nowa wersja Logical Volume Managera dla Linuksa - wersja dla initrd
-Group: Base
-Conflicts: geninitrd < 10000.18
-
-%description initrd
-This package includes a number of utilities for creating, checking,
-and repairing logical volumes - staticaly linked for initrd.
-
-%description initrd -l pl.UTF-8
-Pakiet ten zawiera narzędzia do tworzenia, sprawdzania i naprawiania
-logicznych wolumenów dyskowych (LVM2) - statycznie skonsolidowane na
-potrzeby initrd.
-
-%package clvmd
-Summary: Cluster LVM daemon
-Summary(pl.UTF-8): Demon clustra LVM
-Group: Applications/System
-Requires: %{name} = %{version}-%{release}
-
-%description clvmd
-clvmd is the daemon that distributes LVM metadata updates around a
-cluster. It must be running on all nodes in the cluster and will give
-an error if a node in the cluster does not have this daemon running.
-
-%description clvmd -l pl.UTF-8
-clvmd to demon który rozprowadza zmiany meta-danych LVM po klastrze.
-Mysi działać na wszystkich węzłach klastra i zgłosi błąd gdy jakiś
-węzeł w klastrze nie ma tego demona uruchomionego.
-
%package cmirrord
Summary: Cluster mirror log daemon
Summary(pl.UTF-8): Demon śledzący log lustrzany w klastrze
%description -n device-mapper-dietlibc -l pl.UTF-8
Statyczna biblioteka devmapper zbudowana z dietlibc.
-%package -n device-mapper-initrd
-Summary: Userspace support for the device-mapper - initrd version
-Summary(pl.UTF-8): Wsparcie dla mapowania urządzeń w przestrzeni użytkownika - wersja dla initrd
-Group: Base
-Obsoletes: device-mapper-initrd-devel
-Conflicts: geninitrd < 10000.10
-
-%description -n device-mapper-initrd
-The goal of this driver is to support volume management. The driver
-enables the definition of new block devices composed of ranges of
-sectors of existing devices. This can be used to define disk
-partitions - or logical volumes. This light-weight kernel component
-can support user-space tools for logical volume management.
-
-This package contains dmsetup program linked staticaly for use in
-initrd.
-
-%description -n device-mapper-initrd -l pl.UTF-8
-Celem tego sterownika jest obsługa zarządzania wolumenami. Sterownik
-włącza definiowanie nowych urządzeń blokowych złożonych z przedziałów
-sektorów na istniejących urządzeniach. Może to być wykorzystane do
-definiowania partycji na dysku lub logicznych wolumenów. Ten lekki
-składnik jądra może wspierać działające w przestrzeni użytkownika
-narzędzia do zarządzania logicznymi wolumenami.
-
-Ten pakiet zawiera program dmsetup skonsolidowany statycznie na
-potrzeby initrd.
-
%prep
%setup -q -n LVM2.%{version}
%{?with_selinux:%patch0 -p1}
%patch5 -p1
%patch6 -p1
%patch7 -p1
-%patch8 -p1
# do not force --export-symbol linker option for e.g. statically linked executables
# -rdynamic compiler option drives linker in the right way.
%{__sed} -i -e 's#-Wl,--export-dynamic#-rdynamic#g' configure.ac
%build
-%if %{with initrd}
-echo Using %{?with_glibc:GLIBC} %{?with_uClibc:uClibc} %{?with_dietlibc:diet} for initrd
-%endif
cp -f /usr/share/automake/config.sub autoconf
%{__aclocal}
%{__autoconf}
-%if %{with initrd}
-%{?with_glibc:export CC="%{__cc}"}
-%{?with_uClibc:export CC="%{_target_cpu}-uclibc-gcc"}
-%{?with_dietlibc:cc="%{__cc}"; export CC="diet ${cc#ccache }"}
-
-%configure \
- ac_cv_lib_dl_dlopen=no \
- %{?with_uClibc:ac_cv_func_siginterrupt=no} \
- %{?debug:--enable-debug} \
- --disable-nls \
- --disable-readline \
- --enable-selinux%{!?with_glibc:=no} \
- --enable-static_link \
- --with-lvm1=internal \
- --with-optimisation="%{rpmcflags} -Os"
-# glibc version links with normal static libdevicemapper which has selinux enabled
-# and we need to keep these in sync between device-mapper and lvm2
-
-%{__sed} -i -e 's#rpl_malloc#malloc#g' lib/misc/configure.h
-%{__sed} -i -e 's#rpl_realloc#realloc#g' lib/misc/configure.h
-
-%{__make} -j1 -C include
-%{__make} -j1 -C lib LIB_SHARED= VERSIONED_SHLIB=
-%{__make} -j1 -C libdm LIB_SHARED= VERSIONED_SHLIB=
-%{__make} -j1 -C libdaemon/client LIB_SHARED= VERSIONED_SHLIB=
-%{__make} -j1 -C tools dmsetup.static lvm.static %{?with_dietlibc:DIETLIBC_LIBS="-lcompat"}
-%{__mv} tools/lvm.static initrd-lvm
-%{__mv} tools/dmsetup.static initrd-dmsetup
-
-# check if tools works
-for tool in initrd-lvm initrd-dmsetup; do
- LVM_SYSTEM_DIR=$(pwd) ./$tool help && rc=$? || rc=$?
- if [ $rc -gt 127 ]; then
- echo >&2 "Unexpected failure (exit status: $rc) from $tool. Does this tool work?!"
- exit 1
- fi
-done
-
-%{?with_dietlibc:%{__mv} libdm/ioctl/libdevmapper.a diet-libdevmapper.a}
-%{__make} clean
-
-unset CC
-%endif
-
%configure \
--enable-applib \
--enable-cache_check_needs_check \
%{?with_cluster:--enable-lvmlockd-dlm} \
%{?with_sanlock:--enable-lvmlockd-sanlock} \
%endif
- %{?with_lvmetad:--enable-lvmetad} \
--enable-lvmpolld \
--enable-ocf \
%{?with_python2:--enable-python2_bindings} \
--enable-thin_check_needs_check \
--enable-udev_sync \
--enable-udev_rules \
+ --disable-udev-systemd-background-jobs \
--with-cache=internal \
--with-cache-check=/usr/sbin/cache_check \
--with-cache-dump=/usr/sbin/cache_dump \
--with-cache-restore=/usr/sbin/cache_restore \
--with-cluster=internal \
%if %{with cluster}
- --with-clvmd=corosync \
--enable-cmirrord \
%endif
--with-dmeventd-path=%{_sbindir}/dmeventd \
--with-thin-restore=/usr/sbin/thin_restore \
--with-udev-prefix=/ \
--with-usrlibdir=%{_libdir}
-
# use bash because of "set -o pipefail"
%{__make} -j1 \
SHELL=/bin/bash
%install
rm -rf $RPM_BUILD_ROOT
install -d $RPM_BUILD_ROOT{/%{_lib},%{_sysconfdir}/lvm,/etc/sysconfig}
-%{?with_dietlibc:install -d $RPM_BUILD_ROOT%{dietlibdir}}
%{__make} install install_system_dirs install_initscripts \
DESTDIR=$RPM_BUILD_ROOT \
GROUP="" \
python3dir=%{py3_sitescriptdir}
-%if %{with cluster}
-cp -p %{SOURCE3} $RPM_BUILD_ROOT/etc/sysconfig/clvmd
-%endif
-
%{__mv} $RPM_BUILD_ROOT%{_libdir}/lib*.so.* $RPM_BUILD_ROOT/%{_lib}
for lib in $RPM_BUILD_ROOT/%{_lib}/lib*.so.*; do
lib=$(echo $lib | sed -e "s#$RPM_BUILD_ROOT##g")
touch $RPM_BUILD_ROOT%{_sysconfdir}/lvm/lvm.conf
-%if %{with initrd}
-install -d $RPM_BUILD_ROOT%{_libdir}/initrd
-install -p initrd-lvm $RPM_BUILD_ROOT%{_libdir}/initrd/lvm
-install -p initrd-dmsetup $RPM_BUILD_ROOT%{_libdir}/initrd/dmsetup
-
-%{?with_dietlibc:cp -a diet-libdevmapper.a $RPM_BUILD_ROOT%{dietlibdir}/libdevmapper.a}
-%endif
-
cp -a libdm/libdevmapper.a $RPM_BUILD_ROOT%{_libdir}
%clean
rm -rf $RPM_BUILD_ROOT
%post
-/sbin/chkconfig --add lvm2-lvmetad
-%service lvm2-lvmetad restart
/sbin/chkconfig --add lvm2-monitor
%service lvm2-monitor restart
/sbin/chkconfig --add lvm2-lvmpolld
%preun
if [ "$1" = "0" ]; then
- %service lvm2-lvmetad stop
- /sbin/chkconfig --del lvm2-lvmetad
%service lvm2-lvmpolld stop
/sbin/chkconfig --del lvm2-lvmpolld
%service lvm2-monitor stop
%post -n device-mapper-libs -p /sbin/ldconfig
%postun -n device-mapper-libs -p /sbin/ldconfig
-%post clvmd
-/sbin/chkconfig --add clvmd
-# no service restart - it breaks current locks!
-export NORESTART=1
-# re-exec instead
-/usr/sbin/clvmd -S 2>/dev/null || :
-
-%preun clvmd
-if [ "$1" = "0" ]; then
- %service clvmd stop
- /sbin/chkconfig --del clvmd
-fi
-
%files
%defattr(644,root,root,755)
%doc README WHATS_NEW doc/*
%attr(755,root,root) %{_sbindir}/lvdisplay
%attr(755,root,root) %{_sbindir}/lvextend
%attr(755,root,root) %{_sbindir}/lvm
-%attr(755,root,root) %{_sbindir}/lvmconf
%attr(755,root,root) %{_sbindir}/lvmconfig
%attr(755,root,root) %{_sbindir}/lvmdiskscan
%attr(755,root,root) %{_sbindir}/lvmdump
%{_mandir}/man8/lvm-fullreport.8*
%{_mandir}/man8/lvm-lvpoll.8*
%{_mandir}/man8/lvm.8*
-%{_mandir}/man8/lvmconf.8*
%{_mandir}/man8/lvmconfig.8*
%{_mandir}/man8/lvmdiskscan.8*
%{_mandir}/man8/lvmdump.8*
%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/lvm/profile/metadata_profile_template.profile
%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/lvm/profile/thin-generic.profile
%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/lvm/profile/thin-performance.profile
+%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/lvm/profile/vdo-small.profile
%dir %{_sysconfdir}/lvm/cache
%ghost %{_sysconfdir}/lvm/cache/.cache
%attr(754,root,root) /etc/rc.d/init.d/blk-availability
%attr(754,root,root) /etc/rc.d/init.d/lvm2-monitor
-%attr(700,root,root) %dir /var/run/lvm
%attr(700,root,root) %dir /var/lock/lvm
-%if %{with lvmetad}
-%attr(755,root,root) %{_sbindir}/lvmetad
-/lib/udev/rules.d/69-dm-lvm-metad.rules
-%attr(754,root,root) /etc/rc.d/init.d/lvm2-lvmetad
-%{_mandir}/man8/lvmetad.8*
-%endif
%if %{with lvmlockd}
%attr(755,root,root) %{_sbindir}/lvmlockctl
%attr(755,root,root) %{_sbindir}/lvmlockd
%endif
%if %{with cluster}
-%files clvmd
-%defattr(644,root,root,755)
-%attr(755,root,root) %{_usrsbindir}/clvmd
-%attr(754,root,root) /etc/rc.d/init.d/clvmd
-%config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/clvmd
-%{_mandir}/man8/clvmd.8*
-
%files cmirrord
%defattr(644,root,root,755)
%attr(755,root,root) %{_usrsbindir}/cmirrord
%attr(755,root,root) %{_sbindir}/lvmdbusd
%{py3_sitescriptdir}/lvmdbusd
%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/lvm/profile/lvmdbusd.profile
-#%config(noreplace) %verify(not md5 mtime size) /etc/dbus-1/system.d/com.redhat.lvmdbus1.conf
-#%{_datadir}/dbus-1/system-services/com.redhat.lvmdbus1.service
%{_mandir}/man8/lvmdbusd.8*
%endif
%if %{with python2}
%files -n python-lvm
%defattr(644,root,root,755)
-%attr(755,root,root) %{py_sitedir}/lvm.so
-%{py_sitedir}/lvm-%{version}_*-py*.egg-info
+#%attr(755,root,root) %{py_sitedir}/lvm.so
+#%{py_sitedir}/lvm-%{version}_*-py*.egg-info
%endif
%if %{with python3}
%files -n python3-lvm
%defattr(644,root,root,755)
-%attr(755,root,root) %{py3_sitedir}/lvm.cpython-*.so
-%{py3_sitedir}/lvm-%{version}_*-py*.egg-info
+#%attr(755,root,root) %{py3_sitedir}/lvm.cpython-*.so
+#%{py3_sitedir}/lvm-%{version}_*-py*.egg-info
%endif
%files -n device-mapper
%attr(755,root,root) /%{_lib}/libdevmapper.so.*.*
%attr(755,root,root) /%{_lib}/libdevmapper-event.so.*.*
%attr(755,root,root) /%{_lib}/libdevmapper-event-lvm2.so.*.*
-%attr(755,root,root) /%{_lib}/liblvm2app.so.*.*
%attr(755,root,root) /%{_lib}/liblvm2cmd.so.*.*
%files -n device-mapper-devel
%attr(755,root,root) %{_libdir}/libdevmapper.so
%attr(755,root,root) %{_libdir}/libdevmapper-event.so
%attr(755,root,root) %{_libdir}/libdevmapper-event-lvm2.so
-%attr(755,root,root) %{_libdir}/liblvm2app.so
%attr(755,root,root) %{_libdir}/liblvm2cmd.so
%{_includedir}/libdevmapper.h
%{_includedir}/libdevmapper-event.h
-%{_includedir}/lvm2app.h
%{_includedir}/lvm2cmd.h
%{_pkgconfigdir}/devmapper.pc
%{_pkgconfigdir}/devmapper-event.pc
-%{_pkgconfigdir}/lvm2app.pc
%files -n device-mapper-static
%defattr(644,root,root,755)
%{_libdir}/libdevmapper.a
-
-%if %{with initrd}
-%if %{with dietlibc}
-%files -n device-mapper-dietlibc
-%defattr(644,root,root,755)
-%{dietlibdir}/libdevmapper.a
-%endif
-
-%files -n device-mapper-initrd
-%defattr(644,root,root,755)
-%attr(755,root,root) %{_libdir}/initrd/dmsetup
-
-%files initrd
-%defattr(644,root,root,755)
-%attr(755,root,root) %{_libdir}/initrd/lvm
-%endif