]> sourceware.org Git - lvm2.git/log
lvm2.git
8 months agoudev: ignore LVs containing PVs 1170102018
David Teigland [Thu, 8 Feb 2024 20:51:46 +0000 (14:51 -0600)]
udev: ignore LVs containing PVs

If LVM LVs happen to contain PVs, they are passed to the lvm udev
rule for processing, where they should be ignored.  PVs on LVs
most likely belong to VM images, and don't belong to the host
which sees the LV.  It's unsafe for the host to use these PVs.
Without this change, the LV would be processed by pvscan which
would generally ignore it, either because of the devices file,
or because of the default lvm policy to not consider LVs as
potential PVs.  This change makes the udev rule consistent
with that policy and avoids the unnecessary system messages
produced when pvscan ignores the LV.

8 months agosystem_id: explain the reason for choosing appmachineid over machineid 1165351102
Andre Klärner [Mon, 5 Feb 2024 19:57:30 +0000 (13:57 -0600)]
system_id: explain the reason for choosing appmachineid over machineid

Since understanding the reason for choosing the appmachineid over the
direct use of machineid is not easily found, I extended to help text to
clarify this a bit.

8 months agoman: fix typo in -A description 1165236263
David Teigland [Mon, 5 Feb 2024 18:13:44 +0000 (12:13 -0600)]
man: fix typo in -A description

8 months agoarchiving: Fix doubled filename in vgcfgrestore 1149721925
Ranjith ML [Wed, 24 Jan 2024 13:05:24 +0000 (14:05 +0100)]
archiving: Fix doubled filename in vgcfgrestore

8 months agothin_pool: correct refactoring chunk_size 1141637488
Zdenek Kabelac [Wed, 17 Jan 2024 16:25:34 +0000 (17:25 +0100)]
thin_pool: correct refactoring chunk_size

Function to recalc chunk_size according to dev hints needs to be
used after chunk_size is being set to thin pool segment - correct
this ordering mistake introduced in previous refactoring commit.

8 months agovdo: correct vdo header size
Zdenek Kabelac [Wed, 17 Jan 2024 16:13:26 +0000 (17:13 +0100)]
vdo: correct vdo header size

Previous patch that introduced support for thinpool with vdo
not correctly handled header size - as this part is not fully usable
yet.  We are going to try to use the 0, but current state of code is not
yet compliant to this logic so keep vdo_header_size during conversion
and alos correctly pass through virtual_extents to vdo formating.

9 months agoWHATS_NEW: update 1133383466
Zdenek Kabelac [Wed, 10 Jan 2024 13:07:45 +0000 (14:07 +0100)]
WHATS_NEW: update

9 months agomake generate
Zdenek Kabelac [Tue, 12 Dec 2023 19:01:16 +0000 (20:01 +0100)]
make generate

9 months agotests: testing creation of compressed thin-pool
Zdenek Kabelac [Wed, 13 Dec 2023 16:37:31 +0000 (17:37 +0100)]
tests: testing creation of compressed thin-pool

9 months agolvmcmdline: support --pooldatavdo
Zdenek Kabelac [Fri, 8 Dec 2023 13:06:25 +0000 (14:06 +0100)]
lvmcmdline: support --pooldatavdo

Extend definitions for lvcreate & lvconvert to support
new option  --pooldatavdo y|n  with thinpools.

9 months agoman: document creation of VDO thin-pool
Zdenek Kabelac [Thu, 14 Dec 2023 22:21:11 +0000 (23:21 +0100)]
man: document creation of VDO thin-pool

Show some examples how to create and convert thin-pools
with VDO volume for thin-pool data.

9 months agovdo: support creation of compressed thin-pools
Zdenek Kabelac [Thu, 14 Dec 2023 13:20:19 +0000 (14:20 +0100)]
vdo: support creation of compressed thin-pools

Add code to handle creation of  thin-pool with VDO data backend
which can be seen as compressed deduplicated thin-pool.

To avoid need of changing to many internal APIs, pass the conversion
parameters for create thin-pool data volume via cmd_context.

9 months agovdo: refactor conversion to vdo lv
Zdenek Kabelac [Thu, 14 Dec 2023 13:06:54 +0000 (14:06 +0100)]
vdo: refactor conversion to vdo lv

Introduce struct vdo_convert_params {} to pass-in all the parameters
needed for the conversion of an LV to a vdopool + vdo LV.

Function convert_vdo_lv() is also able to create a new LV and swap
segments, so the passed in LV can be later on use for futher
conversion so this refactoring makes it ready for more enhanced
usage.

9 months agovdo: refactor vdo_params passing
Zdenek Kabelac [Thu, 14 Dec 2023 13:09:55 +0000 (14:09 +0100)]
vdo: refactor vdo_params passing

Introduce vdo_convert_params and use vdo_params from this structure
also with lvcreate_params.

Later we will use this for convertion of thin-pool data volume to VDO.

9 months agothin_pool: introduce --pooldatavdo
Zdenek Kabelac [Thu, 7 Dec 2023 18:17:35 +0000 (19:17 +0100)]
thin_pool: introduce --pooldatavdo

Introducing new arg --pooldatavdo y|n

9 months agopool: code refactoring
Zdenek Kabelac [Fri, 8 Dec 2023 13:10:39 +0000 (14:10 +0100)]
pool: code refactoring

Move pool related manipulation code to pool_manip.c.

9 months agothin_pool: code refactoring
Zdenek Kabelac [Thu, 7 Dec 2023 17:07:56 +0000 (18:07 +0100)]
thin_pool: code refactoring

Move common code into thin_pool_set_params()
(just like we use  cache_set_params).

9 months agocov: check for failing device_ids_read
Zdenek Kabelac [Fri, 5 Jan 2024 14:23:27 +0000 (15:23 +0100)]
cov: check for failing device_ids_read

TODO: not sure if here we should possibly exit from function.

9 months agocov: remove unneeded header
Zdenek Kabelac [Fri, 5 Jan 2024 12:21:56 +0000 (13:21 +0100)]
cov: remove unneeded header

9 months agocov: some stack tracing corrections
Zdenek Kabelac [Fri, 5 Jan 2024 14:13:42 +0000 (15:13 +0100)]
cov: some stack tracing corrections

Checking some returned values and adding/correcting
some debug tracing.

9 months agolvcreate: support vg profile for error_on_full
Zdenek Kabelac [Fri, 8 Dec 2023 13:04:55 +0000 (14:04 +0100)]
lvcreate: support vg profile for error_on_full

9 months agovdo: flip return value to int
Zdenek Kabelac [Tue, 28 Nov 2023 14:50:59 +0000 (15:50 +0100)]
vdo: flip return value to int

Change API to return just 0/1.

9 months agodev_manager: reuse _setup_task_run
Zdenek Kabelac [Mon, 6 Nov 2023 13:39:30 +0000 (14:39 +0100)]
dev_manager: reuse _setup_task_run

9 months agolv: remove unused declaration
Zdenek Kabelac [Mon, 13 Nov 2023 12:52:44 +0000 (13:52 +0100)]
lv: remove unused declaration

9 months agoactivate: use lv_layer
Zdenek Kabelac [Thu, 9 Nov 2023 14:51:51 +0000 (15:51 +0100)]
activate: use lv_layer

Avoid code duplication.

10 months agoraid: add messages to lvs command output in case RaidLVs require a refresh 1097309350
Heinz Mauelshagen [Wed, 6 Dec 2023 11:58:14 +0000 (12:58 +0100)]
raid: add messages to lvs command output in case RaidLVs require a refresh

If a RaidLV mapping is required to be refreshed as a result of temporarily failed
and recurred RAID leg device (pairs) caused by writes to the LV during failure,
the requirement is reported by volume health character r' in position 9 of the
LV's attribute field (see 'man lvs' about additional volume health characters).

As this character can be overlooked, this patch adds messages to the top
of the lvs command output informing the user explicitely about the fact.

10 months agoman: update readonly description 1096422586
David Teigland [Tue, 5 Dec 2023 18:42:38 +0000 (12:42 -0600)]
man: update readonly description

10 months agoman: add inte(g)rity to man lvs
Lukas Herbolt [Tue, 5 Dec 2023 15:08:24 +0000 (09:08 -0600)]
man: add inte(g)rity to man lvs

10 months agospec: Uncomment some globals 1089423238
Marian Csontos [Wed, 29 Nov 2023 14:26:03 +0000 (15:26 +0100)]
spec: Uncomment some globals

These were incorrectly commented out, after escaping '%' these no longer
compile on some older machines.

10 months agospec: Install and package /etc/lvm/devices 1089393814
Marian Csontos [Wed, 29 Nov 2023 14:09:36 +0000 (15:09 +0100)]
spec: Install and package /etc/lvm/devices

10 months agodmstats: Fix memory leak on error path 1088425690
Marian Csontos [Tue, 28 Nov 2023 20:41:35 +0000 (21:41 +0100)]
dmstats: Fix memory leak on error path

10 months agopost-release 1080205258
Marian Csontos [Tue, 21 Nov 2023 13:38:53 +0000 (14:38 +0100)]
post-release

10 months agopre-release
Marian Csontos [Tue, 21 Nov 2023 13:26:07 +0000 (14:26 +0100)]
pre-release

10 months agomake: generate
Marian Csontos [Thu, 16 Nov 2023 18:35:53 +0000 (19:35 +0100)]
make: generate

10 months agoWHATS_NEW: spelling
Marian Csontos [Wed, 15 Nov 2023 14:34:18 +0000 (15:34 +0100)]
WHATS_NEW: spelling

10 months agoraid: lvcreate and lvchange fail if --min_recovery_rate is defined 1080170876
Heinz Mauelshagen [Tue, 21 Nov 2023 13:17:57 +0000 (14:17 +0100)]
raid: lvcreate and lvchange fail if --min_recovery_rate is defined

Fix typos in previous commit 3589e515d.

Both commands default [raid_](min|max)recoveryrate to 0 but ensure
min_recovery_rate is not larger than max_recoveryrate.  This results
in command failure without requesting the user to also define
max_recovery_rate >= min_recovery_rate.

Fix both commands by defining max_recovery_rate = min_recoveryrate
in case "lvcreate/lvchange --minrecoveryrate Size ..." requests a
larger value than current maxrecoveryrate without also giving option

10 months agoraid: lvcreate and lvchange fail if --min_recovery_rate is defined 1079114472
Heinz Mauelshagen [Mon, 20 Nov 2023 16:05:59 +0000 (17:05 +0100)]
raid: lvcreate and lvchange fail if --min_recovery_rate is defined

Both commands default [raid_](min|max)recoveryrate to 0 but ensure
min_recovery_rate is not larger than max_recoveryrate.  This results
in command failure without requestinng the user to also define
max_recovery_rate >= min_recovery_rate.

Fix both commands by defining max_recovery_rate = min_recoveryrate
in case "lvcreate/lvchange --minrecoveryrate Size ..." requests a
larger value than current maxrecoveryrate without also giving option
"--maxrecoveryrate Size ..." with a size greater or equal than min.

10 months agolvmconfig: uncomment the report section 1076767364
David Teigland [Fri, 17 Nov 2023 19:52:49 +0000 (13:52 -0600)]
lvmconfig: uncomment the report section

so settings can be changed without uncommenting the
start/end of the section.

10 months agoWHATS_NEW: lv_attr for iorig LVs 1076750383
David Teigland [Fri, 17 Nov 2023 19:29:11 +0000 (13:29 -0600)]
WHATS_NEW: lv_attr for iorig LVs

10 months agolvs: set first attr flag for raid integrity images
David Teigland [Fri, 17 Nov 2023 17:04:22 +0000 (11:04 -0600)]
lvs: set first attr flag for raid integrity images

The first lv_attr flag is 'i' or 'I' for a raid image.
(i: raid image, I: out of sync raid image)
For integrity raid images (_iorig), the flag was not being set.

10 months agoWHATS_NEW: pvs -A 1075082744
David Teigland [Thu, 16 Nov 2023 14:46:23 +0000 (08:46 -0600)]
WHATS_NEW: pvs -A

10 months agopvs, pvscan: new option -A to show PVs outside the devices file
David Teigland [Fri, 10 Nov 2023 22:24:45 +0000 (16:24 -0600)]
pvs, pvscan: new option -A to show PVs outside the devices file

pvs -A|--allpvs
Show PVs that would otherwise be excluded by the devices file.

pvscan -A|--allpvs
Show PVs that would otherwise be excluded by the devices file.
For those devices that are included by the devices file,
their device ID is displayed in place of the usual "lvm2"
format and size.

(pvs -a|--all is unchanged, and shows devices not formatted as PVs.)

10 months agomake: generate 1073419502
Marian Csontos [Wed, 15 Nov 2023 12:35:52 +0000 (13:35 +0100)]
make: generate

10 months agoWHATS_NEW: update
Marian Csontos [Wed, 15 Nov 2023 12:35:10 +0000 (13:35 +0100)]
WHATS_NEW: update

Remove stray line

10 months agospec: Fix spec file to work with mock 1073156117
Marian Csontos [Tue, 26 Sep 2023 13:34:21 +0000 (15:34 +0200)]
spec: Fix spec file to work with mock

- missing BuildRequires

diff --git a/spec/source.inc b/spec/source.inc
index 7b44ef152..b04c500a2 100644
--- a/spec/source.inc
+++ b/spec/source.inc
@@ -12,8 +12,8 @@
 %global enable_lvmlockd 1
 %global enable_lvmpolld 1
 %global enable_dmfilemapd 0
-#%global enable_lvmlockd_dlm 0
-#%global enable_lvmlockd_sanlock 0
+#%%global enable_lvmlockd_dlm 0
+#%%global enable_lvmlockd_sanlock 0

 %if %{enable_udev}
 %service lvmpolld 1
@@ -43,7 +43,8 @@
 %with writecache internal
 %with integrity internal

-%global buildreq_udev systemd-devel
+# NOTE: Required by fedora 38+, maybe older
+%global buildreq_udev systemd-devel, systemd-units
 %global req_udev udev >= 181-1

@@ -60,15 +61,12 @@
  %global sanlock_version 3.3.0-1
  %global enable_lvmlockd_dlm 1
  %global enable_lvmlockd_sanlock 1
+ # FIXME: Check these conditions against RHEL builds!
  %if %{rhel}
-  %ifarch i686 x86_64 s390x
-   %global buildreq_lvmlockd_dlm dlm-devel >= %{dlm_version}
-  %else
+  %ifnarch i686 x86_64 s390x
    %global enable_lvmlockd_dlm 0
   %endif
-  %ifarch x86_64 ppc64le ppc64 aarch64
-   %global buildreq_lvmlockd_sanlock sanlock-devel >= %{sanlock_version}
-  %else
+  %ifnarch x86_64 ppc64le ppc64 aarch64
    %global enable_lvmlockd_sanlock 0
   %endif
  %endif
@@ -78,6 +76,12 @@
   %global enable_lvmlockd_dlm 1
  %endif
 %endif
+%if 0%{enable_lvmlockd_dlm}
+ %global buildreq_lvmlockd_dlm dlm-devel >= %{dlm_version}
+%endif
+%if 0%{enable_lvmlockd_sanlock}
+ %global buildreq_lvmlockd_sanlock sanlock-devel >= %{sanlock_version}
+%endif

 ##############################################################

@@ -164,6 +168,11 @@ Source92: build.inc
 Source93: packages.inc
 Source94: macros.inc

+BuildRequires: make
+BuildRequires: gcc
+%if %{enable_testsuite}
+BuildRequires: gcc-c++
+%endif
 BuildRequires: libselinux-devel >= 1.30.19-4, libsepol-devel
 BuildRequires: ncurses-devel
 %if %{enable_readline}
@@ -174,6 +183,9 @@ BuildRequires: libedit-devel
 %endif
 BuildRequires: module-init-tools
 BuildRequires: pkgconfig
+# TODO: Should these be conditional?
+BuildRequires: libaio-devel
+BuildRequires: libblkid-devel

 # Expands to nothing unless at least 2 arguments are given
 %define maybe() \
@@ -189,6 +201,8 @@ BuildRequires: pkgconfig
 %maybe BuildRequires: %{?buildreq_lvmlockd_sanlock}
 %maybe BuildRequires: %{?buildreq_python3_devel}
 %maybe BuildRequires: %{?buildreq_python3_setuptools}
+%maybe BuildRequires: %{?buildreq_python3_dbus}
+%maybe BuildRequires: %{?buildreq_python3_pyudev}

 %description
 LVM2 includes all of the support for handling read/write operations on

10 months agoWHATS_NEW: update
Marian Csontos [Wed, 15 Nov 2023 09:37:18 +0000 (10:37 +0100)]
WHATS_NEW: update

11 months agodevice: remove log_debug for nvme device 1067244130
David Teigland [Thu, 9 Nov 2023 19:31:01 +0000 (13:31 -0600)]
device: remove log_debug for nvme device

11 months agodevice_id: remove unused dev pointer from dev_id struct 1067230115
David Teigland [Thu, 9 Nov 2023 19:12:33 +0000 (13:12 -0600)]
device_id: remove unused dev pointer from dev_id struct

11 months agodevice_id: ensure pvid buffers are ID_LEN+1
David Teigland [Wed, 8 Nov 2023 17:46:38 +0000 (11:46 -0600)]
device_id: ensure pvid buffers are ID_LEN+1

A pvid string read from system.devices could be less
then ID_LEN since system.devices fields can be edited.
Ensure the pvid buffer is ID_LEN+1 even if the string
read from the file is shorter.

11 months agodevice_id: improve searched_devnames temp file
David Teigland [Thu, 2 Nov 2023 19:54:31 +0000 (14:54 -0500)]
device_id: improve searched_devnames temp file

Include info in the temp file to confirm that it should be used.
The temp file is meant to suppress repeated, identical searches
for the same PVIDs on the same set of devices.  Write to the file
a count and hash of the missing PVIDs and a count and hash of the
devices to search.  A subsequent command will ignore and remove
the temp file if any of these values differ.  We don't want to
suppress a search if a change has occured, and a missing PV could
be found by scanning devices.

11 months agolvmdevices: print changes for product_uuid or hostname 1064341461
David Teigland [Tue, 7 Nov 2023 20:30:48 +0000 (14:30 -0600)]
lvmdevices: print changes for product_uuid or hostname

used by the recently added refresh feature

11 months agolvmdevices: handle empty fields in new check and update 1060752941
David Teigland [Fri, 3 Nov 2023 20:15:59 +0000 (15:15 -0500)]
lvmdevices: handle empty fields in new check and update

Expand the recent commit 37773c1055913
"lvmdevices: new output and options for check and update"
to specifically cover entries with empty fields.

11 months agodevice_id: change default search_for_devnames to all 1059322176
David Teigland [Thu, 2 Nov 2023 17:10:56 +0000 (12:10 -0500)]
device_id: change default search_for_devnames to all

Problematic scenario:
. the device for a PV has no wwid, so it's identified in system.devices
  with IDTYPE=devname IDNAME=/dev/foo
. user adds/enables a wwid for the device
. on reboot, the device name changes, e.g. now /dev/bar
. the code that searches for the new device name includes an
  optimization to skip looking on devs that have a wwid, on
  the basis that a device with a wwid won't have IDTYPE=devname
. this optimization causes lvm to not look for the PV on /dev/bar
  since that device now has a wwid, so the PV is not found
. the optimization is enabled by search_for_devnames="auto"
. change the default to search_for_devnames="all" which does not
  use the problematic optimization

11 months agolvmdevices: new output and options for check and update 1059238271
David Teigland [Fri, 27 Oct 2023 22:39:32 +0000 (17:39 -0500)]
lvmdevices: new output and options for check and update

- add new comparison between old and new entries, and use this
  as the basis for new dedicated output for check and update
- add new --refresh option to search for missing PVIDs on all
  devices, and possibly update the device ID
- internally, only use the term "refresh" for cases where a
  new device ID may be found and assigned for a missing PVID

11 months agodevice_id: improve validate debug messages
David Teigland [Fri, 27 Oct 2023 22:13:25 +0000 (17:13 -0500)]
device_id: improve validate debug messages

Make the device_ids_validate messages consistent.

Consistently use "noupdate" and "update_needed" args.

11 months agodevice_id: reduce messages
David Teigland [Tue, 24 Oct 2023 21:39:15 +0000 (16:39 -0500)]
device_id: reduce messages

Don't print messages about devices file entries that are
missing or are being updated.

11 months agoREADME: update with new list info 1056712015
Zdenek Kabelac [Tue, 31 Oct 2023 18:07:47 +0000 (19:07 +0100)]
README: update with new list info

Server is changed for linux-lvm and lvm-devel mailing lists.

11 months agotests: unit test for raid status
Zdenek Kabelac [Thu, 26 Oct 2023 20:02:54 +0000 (22:02 +0200)]
tests: unit test for raid status

11 months agotests: longer timeout
Zdenek Kabelac [Thu, 26 Oct 2023 19:58:55 +0000 (21:58 +0200)]
tests: longer timeout

11 months agotests: lvmdbusd handles empty LvCommon.Devices
Tony Asleson [Wed, 25 Oct 2023 20:08:12 +0000 (15:08 -0500)]
tests: lvmdbusd handles empty LvCommon.Devices

During vdo testing with smaller block devices the test needs to determine
which PVs in a VG are unused.  This was leveraging LvCommon.Devices, but
that isn't populated when a LV is resides on a LV pool instead of a PV.
This is a known limitation of the code at this time.  For now we will walk
all the PVs in the VG looking for ones that don't have any associated LVs
and use them instead.

Signed-off-by: Tony Asleson <tasleson@redhat.com>
11 months agodevice_mapper: raid status handle all a chars
Zdenek Kabelac [Thu, 26 Oct 2023 19:57:59 +0000 (21:57 +0200)]
device_mapper: raid status handle all a chars

When getting raid status from some older kernels, we may get an 'a'
for 'A' leg when doing initial synchronization.
This may prohibit removal of newly synchronized leg until synchronization
is finished.
So in this case change the status to look like being reported
from a newer kernel version.

11 months agotests: add devicesfile-misc 1046737321
David Teigland [Mon, 23 Oct 2023 19:29:14 +0000 (14:29 -0500)]
tests: add devicesfile-misc

11 months agodevice_id: simplify devname matching
David Teigland [Mon, 23 Oct 2023 19:27:36 +0000 (14:27 -0500)]
device_id: simplify devname matching

Handle this case directly rather than going through the
process for reading other device ids.  Also simplify
matching alternate dm devnames.

11 months agodevice_id: no idname should be NULL not empty string
David Teigland [Tue, 17 Oct 2023 21:49:30 +0000 (16:49 -0500)]
device_id: no idname should be NULL not empty string

One place was setting idname to "" instead of NULL when
there was no idname value.

11 months agodevice_id: first match non-devname device ids
David Teigland [Tue, 17 Oct 2023 18:54:31 +0000 (13:54 -0500)]
device_id: first match non-devname device ids

Incorrectly matching a dev to a devname id (due to changing devnames)
before matching the dev to a proper device id, can result in the
dev not being matched to the real id.

11 months agolibdm: report: fix invalid JSON if using DM_REPORT_OUTPUT_MULTIPLE_TIMES and selection 1046171620
Peter Rajnoha [Mon, 23 Oct 2023 11:56:55 +0000 (13:56 +0200)]
libdm: report: fix invalid JSON if using DM_REPORT_OUTPUT_MULTIPLE_TIMES and selection

When reporting in JSON format, we need to be able to find the 'last
displayed row', not just 'last row' as we did before. This is used
to decide whether to put the JSON_SEPARATOR (the ',' character)
between the lines when reporting in JSON format.

This is mainly important in case we use a combination of JSON format
and a report marked with DM_REPORT_OUTPUT_MULTIPLE_TIMES flag.
Such report may be reused several times with different selection
criteria each time. In that case, the report always contains all lines
in memory, even though some of them do not need to pass the selection
criteria that are currently used.

Without DM_REPORT_OUTPUT_MULTIPLE_TIMES flag, the report only contains
the lines that have passed the selection criteria, so the this wasn't
an issue in this case.

Fix suggested by Lars Ellenberg and reported here: https://github.com/lvmteam/lvm2/issues/130

11 months agotypo: update 1043152934
Zdenek Kabelac [Thu, 19 Oct 2023 20:05:11 +0000 (22:05 +0200)]
typo: update

11 months agotests: longer delay between table reloads
Zdenek Kabelac [Thu, 19 Oct 2023 22:02:44 +0000 (00:02 +0200)]
tests: longer delay between table reloads

It looks like there is some kernel bug/limitation
that may cause invalid table load processing:

dmsetup load LVMTEST-LV1
device-mapper: reload ioctl on LVMTEST-LV1  failed: Invalid argument
  md/raid:mdX: reshape_position too early for auto-recovery - aborting.
           md: pers->run() failed ...
device-mapper: table: 253:38: raid: Failed to run raid array (-EINVAL)
device-mapper: ioctl: error adding target to table

However ATM there is not much we can do then make delays bigger.
TODO: fixing md core...

11 months agotests: skip on problematic kernel
Zdenek Kabelac [Wed, 18 Oct 2023 11:35:08 +0000 (13:35 +0200)]
tests: skip on problematic kernel

11 months agolvconvert: fix "lvconvert -m 0" for in-sync legs
Heinz Mauelshagen [Thu, 19 Oct 2023 14:50:01 +0000 (16:50 +0200)]
lvconvert: fix "lvconvert -m 0" for in-sync legs

With commit d7e922480e04ecfb7c4d8b2d42533699ddef5c34
lvconvert -m   may fail if we try to remove 1st. leg that
is out-of-sync while other leg is in-sync.

Hot fix allows to proceed with such down conversion.

Signed-off-by: Heinz Mauelshagen <heinzm@redhat.com>
11 months agofilters: fix condition 1040436447
Zdenek Kabelac [Wed, 18 Oct 2023 00:19:15 +0000 (02:19 +0200)]
filters: fix condition

During revork in commit cf46f4baeeaba5f79982e651c1c36c15476f7329
condition was inverted, the check for non-null string is needed.

11 months agotests: aux kills lvmdbusd more agressively 1040416585
Zdenek Kabelac [Tue, 17 Oct 2023 23:48:50 +0000 (01:48 +0200)]
tests: aux kills lvmdbusd more agressively

It's not exactly trivial to kill 'frozen' lvmdbusd.
So skip the test testing interruption and also add killall use.

11 months agotests: wait till snapshot merge is finished
Zdenek Kabelac [Tue, 17 Oct 2023 23:47:13 +0000 (01:47 +0200)]
tests: wait till snapshot merge is finished

In case test runs with lvmpolld (and lvmlockd) wait till snapshot
merge is finished.

11 months agotests: init of dmevent may take upto a second
Zdenek Kabelac [Tue, 17 Oct 2023 21:24:03 +0000 (23:24 +0200)]
tests: init of dmevent may take upto a second

Dynamic load of plugins takes a while...

11 months agotests: avoid busy looping 1039938507
Zdenek Kabelac [Tue, 17 Oct 2023 14:45:10 +0000 (16:45 +0200)]
tests: avoid busy looping

While waiting for the change, don't busy loop on CPU.
TODO: fix missing notification about device removal.

11 months agotests: ensure file is removed
Zdenek Kabelac [Tue, 17 Oct 2023 11:05:09 +0000 (13:05 +0200)]
tests: ensure file is removed

Make sure there are no previous loop results.

11 months agolvm: fix reporting path with HOME envvar
Zdenek Kabelac [Mon, 16 Oct 2023 10:57:41 +0000 (12:57 +0200)]
lvm: fix reporting path with HOME envvar

When envvar HOME is not present we were using invalid path with (null).

11 months agomake: generate
Zdenek Kabelac [Tue, 17 Oct 2023 14:48:50 +0000 (16:48 +0200)]
make: generate

11 months agodevice_id: make dmeventd use system.devices by default 1038717006
David Teigland [Mon, 2 Oct 2023 22:15:44 +0000 (17:15 -0500)]
device_id: make dmeventd use system.devices by default

When no dmeventd.devices exists, make it use system.devices
rather than no devices file at all.

11 months agodevice_id: accept wwids containing QEMU HARDDISK
David Teigland [Mon, 16 Oct 2023 20:11:29 +0000 (15:11 -0500)]
device_id: accept wwids containing QEMU HARDDISK

A wwid may be useful even when it contains the string
"QEMU HARDDISK", so allow these to be used.

11 months agodevice_id: improve handling of non-standard wwid prefixes
David Teigland [Mon, 16 Oct 2023 20:09:17 +0000 (15:09 -0500)]
device_id: improve handling of non-standard wwid prefixes

11 months agohints: correct fix for hints with device ids 1038649998
David Teigland [Mon, 16 Oct 2023 19:08:28 +0000 (14:08 -0500)]
hints: correct fix for hints with device ids

Fixes commit 63b469c1609fe5d3395b7757eebaf35a4a77ea7a
"device_id: fix hints with device ids"

It's not correct for internal filtering to be a factor
in validating the set of devs that are the basis for hints.

Instead, look for inconsistencies between a hint entry and
the corresponding devices file entry.

11 months agotests: aux mdadm_assemble skip path 1037427774
Zdenek Kabelac [Sun, 15 Oct 2023 22:11:35 +0000 (00:11 +0200)]
tests: aux mdadm_assemble skip path

If the old mdadm fails to assembly array due to its internal buggy logic
skip the test instead of failure.

11 months agotests: simplify line counting
Zdenek Kabelac [Sun, 15 Oct 2023 19:47:36 +0000 (21:47 +0200)]
tests: simplify line counting

No need for pipes

11 months agotests: better synchronization
Zdenek Kabelac [Sun, 15 Oct 2023 19:42:20 +0000 (21:42 +0200)]
tests: better synchronization

12 months agotests: fsck with yes
Zdenek Kabelac [Sun, 15 Oct 2023 17:51:43 +0000 (19:51 +0200)]
tests: fsck with yes

Fsck may need to update metadata even after clean unmount.

12 months agotests: check for blkid 1037198448
Zdenek Kabelac [Sun, 15 Oct 2023 12:43:13 +0000 (14:43 +0200)]
tests: check for blkid

When libblkid is not present (older systems) we can't use new -fs tests at
all so skip these tests.

12 months agotests: shorting batch line output
Zdenek Kabelac [Sun, 15 Oct 2023 12:42:14 +0000 (14:42 +0200)]
tests: shorting batch line output

12 months agotests: old way to disable copy contructor 1036898694
Zdenek Kabelac [Sat, 14 Oct 2023 21:37:38 +0000 (23:37 +0200)]
tests: old way to disable copy contructor

Mark them private.

12 months agotests: io stream class saver 1036894333
Zdenek Kabelac [Sat, 14 Oct 2023 14:56:26 +0000 (16:56 +0200)]
tests: io stream class saver

Restore io stream when changed by modifiers.
Also simplify getenv access.

12 months agotests: extend the usability for older systems
Zdenek Kabelac [Sat, 14 Oct 2023 19:26:39 +0000 (21:26 +0200)]
tests: extend the usability for older systems

Extend the test a bit futher so we can keep logic of resize
working similarly well for older and newer systems.

Test uses new 'aux have_fsinfo'function to regnize compiled
version of lvm.

12 months agotests: aux add have_fsinfo
Zdenek Kabelac [Sat, 14 Oct 2023 20:56:22 +0000 (22:56 +0200)]
tests: aux add have_fsinfo

Add function to detect whether lvm2 was compiled with
blkid.h with BLKID_SUBLKS_FSINFO

Currently it can be detected by support of '--fs checksize'.

12 months agocov: avoid resoure leaks on error path
Zdenek Kabelac [Sat, 14 Oct 2023 14:55:46 +0000 (16:55 +0200)]
cov: avoid resoure leaks on error path

12 months agocov: check next_get token exists
Zdenek Kabelac [Sat, 14 Oct 2023 14:54:54 +0000 (16:54 +0200)]
cov: check next_get token exists

12 months agocov: enusure pointer to idname exists
Zdenek Kabelac [Sat, 14 Oct 2023 14:53:58 +0000 (16:53 +0200)]
cov: enusure pointer to idname exists

12 months agoresize: reduce without prompt for no-fs case
Zdenek Kabelac [Sat, 14 Oct 2023 19:19:21 +0000 (21:19 +0200)]
resize: reduce without prompt for  no-fs case

Apply the same logic for 'lvreduce' which exists for newer
systems (compiled with HAVE_BLKID_SUBLKS_FSINFO)
also for older systems for one very common practical case where
the active LV does not have any blkid known signature/filesystem.

New variant recognized this situation and allowed to proceed
without requesting a prompt, while the older variant always
requested confirmation prompt.

With this patch command now works equily for both variants
for 'active LV' without signature and allows to reduce LV
without prompting.

12 months agoWHATS_NEW{_DM}: update 1036471707
Zdenek Kabelac [Fri, 13 Oct 2023 18:56:39 +0000 (20:56 +0200)]
WHATS_NEW{_DM}: update

12 months agoconfigure: update
Zdenek Kabelac [Fri, 13 Oct 2023 20:03:40 +0000 (22:03 +0200)]
configure: update

12 months agoconfigure.ac: enhancemetns
Zdenek Kabelac [Fri, 13 Oct 2023 19:28:56 +0000 (21:28 +0200)]
configure.ac: enhancemetns

Simplify configuration with enabling options:
- For --enable-dmeventd automatically --enable-cmdlib.
- For --enable-dbus-service auto --enable-notify-dbus.

Fix check linux/fiemap.h for dmfilemapd.

12 months agodebug: initialize empty string
Zdenek Kabelac [Fri, 13 Oct 2023 18:57:02 +0000 (20:57 +0200)]
debug: initialize empty string

This page took 0.071621 seconds and 5 git commands to generate.