| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
| |
When VDO support is available we will create VG object instances
which will allow the API user to create VDO pool LVs.
|
|
|
|
| |
Will be used to add vdo interfaces on demand.
|
|
|
|
| |
Added for vdo support.
|
|
|
|
| |
These were added for vdo integration.
|
|
|
|
|
| |
We can use tuple expansion from the command handler functions
directly.
|
|
|
|
|
| |
vg, lv, pv code had the same function for handling command execution.
Move to utility function and abstract the difference.
|
|
|
|
|
| |
Correct included header files for this outdated tool since
it's linked with libdm, it need to use header files from this dir.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Followup patch mentioned in previous commit fe577f84cbf6bd7be76b457c9d54d0e54e57f93d.
Problem:
even though dead raid component devices are detected, the
raid plugin is bailing out thus preventing a repair attempt.
Rational:
in case of component device errors, the MD resynchronization
thread runs in parallel with the thrown event being processed
by the raid plugin. The plugin retrieves the raid device status
but that still reflects insync regions as 0 (when it should
already be total regions) because the MD thread didn't update it yet.
Solution:
Remove the insync regions check but keep the informal message
"waiting for resynchronization" and let lvconvert carry out its
pre-repair checks and optionally carry out a repair attempt.
Related: https://bugzilla.redhat.com/show_bug.cgi?id=1751887
Related: https://bugzilla.redhat.com/show_bug.cgi?id=1560739
Related: https://bugzilla.redhat.com/show_bug.cgi?id=1468590
Related: https://bugzilla.redhat.com/show_bug.cgi?id=1654860
Related: https://bugzilla.redhat.com/show_bug.cgi?id=1729303
Related: https://bugzilla.redhat.com/show_bug.cgi?id=1741016
|
|
|
|
|
|
|
|
|
|
|
|
| |
This reverts commit ad560a286a0b5d08086324e6194b060c136e9353.
The reverted patch also removed the warning which we realized we need
to keep as valuable process information (see related bugzilla below).
In a followup patch, we'll keep the message and avoid bailing out thus
always allowing lvconvert to try repairing if 'allocate' fault policy set.
Related: https://bugzilla.redhat.com/show_bug.cgi?id=1751887
|
|
|
|
|
|
| |
This reverts commit 71af650760c2b75b3c267277f47d8ba235421300.
It disabled sd_notify() which broke 'systemctl start lvmlockd'.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
With Python 3.8 converting these directly to string using str()
no longer works, we need to convert these to integer first.
On Python 3.8:
>>> str(dbus.Int64(1))
'dbus.Int64(1)'
On Python 3.7 (and older):
>>> str(dbus.UInt64(1))
'1'
This is probably related to removing __str__ function from method
from int (dbus.UInt is subclass of int) which happened in 3.8, see
https://docs.python.org/3.8/whatsnew/3.8.html
Signed-off-by: Vojtech Trefny <vtrefny@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem:
even though dead raid component devices are detected, the
raid plugin is bailing out thus preventing a repair attempt.
Rational:
in case of component device errors, the MD resynchronization
thread runs in parallel with the thrown event being processed
by the raid plugin. The plugin retrieves the raid device status
but that still reflects insync regions as 0 (when it should
already be total regions) because the MD thread didn't update it yet.
Solution:
Remove the insync regions check and let lvconvert carry out its
pre-repair checks and optionally carry out a repair attempt.
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1560739
Related: https://bugzilla.redhat.com/show_bug.cgi?id=1468590
Related: https://bugzilla.redhat.com/show_bug.cgi?id=1654860
Related: https://bugzilla.redhat.com/show_bug.cgi?id=1729303
Related: https://bugzilla.redhat.com/show_bug.cgi?id=1741016
|
| |
|
|
|
|
|
|
|
|
|
|
| |
To avoid tiny race on checking arrival of signal and entering select
(that can latter remain stuck as signal was already delivered) switch
to use pselect().
If it would needed, we can eventually add extra code for older systems
without pselect(), but there are probably no such ancient systems in
use.
|
|
|
|
|
| |
Using select instead of normal args did not end
up being a help, so remove it.
|
|
|
|
|
|
|
| |
Update the previous commit to leave the vgname as
an arg instead of moving it into the select option,
(the compound select option rule is confusing the
dlm arg processing.)
|
|
|
|
|
|
|
|
| |
Using --select 'lvname=LV && vgname=VG' avoids the problem
of the lvchange exit code not distinguishing an actual error
result vs the VG or LV not existing. (This is in case there
is an odd dlm/gfs2 setup where some nodes are running the dlm
but do not have access to the VG.)
|
|
|
|
|
|
|
|
|
| |
When lvextend extends an LV that is active with a shared
lock, use this as a signal that other hosts may also have
the LV active, with gfs2 mounted, and should have the LV
refreshed to reflect the new size. Use the libdlmcontrol
run api, which uses dlm_controld/corosync to run an
lvchange --refresh command on other cluster nodes.
|
|
|
|
|
| |
Detect when a shared lock exists, don't require the
normal exclusive lock, and allow the lvextend.
|
|
|
|
|
|
|
|
|
|
| |
When an LV is active with a shared lock, a command can be
run to change the LV with --lockopt skiplv (to override the
exclusive lock the command ordinarily requires which is not
compatible with the outstanding shared lock.)
In this case, other commands may have the LV active and may
need to refresh the LV, so print warning stating this.
|
| |
|
|
|
|
|
| |
Use the UUID to specify the VG to rename instead of the name as this
approach works when we have duplicate VG names.
|
|
|
|
|
|
|
|
|
|
|
| |
Lvm can at times have duplicate names. When this happens the daemon will
internally use vg_name:vg_uuid as the name for lookups, but display just
the vg_name externally. If an API user uses the Manager.LookUpByLvmId and
queries the vg name they will only get returned one result as the API
can only accommodate returning 1. The one returned is the first instance
found when sorting the volume groups by UUID.
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1583510
|
|
|
|
|
|
|
|
|
| |
When we have two logical volumes which switch their names at the
same time we are left with incorrect lookups. Anytime we find
an entry by doing a lookup by UUID or by name we will ensure
that the lookups are indeed correct.
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1642176
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If there are two independent scripts doing:
vgchange --lockstart vg
lvchange -ay vg/lv
The first vgchange to do the lockstart will wait for
the lockstart to complete before returning.
The second vgchange to do the lockstart will see that
the start is already in progress (from the first) and
will do nothing. This means the second does not wait
for any lockstart to complete, and moves on to the
lvchange which may find the lockspace still starting
and fail.
To fix this, make the vgchange lockstart command
wait for any lockstart's in progress to complete.
|
|
|
|
| |
Some places forget to use zalloc().
|
|
|
|
| |
Do not leak lvs pointer on error path.
|
|
|
|
|
|
| |
This reverts commit b068f21f6a24094936a33269067c18373b48f2cd.
This revert was incorrect.
|
|
|
|
|
| |
New code missed to unlock locked lvm2 on error path when
command is not configured.
|
|
|
|
|
| |
These defines are automatically granted with _GNU_SOURCE
which is use for whole compilation via configure.h.
|
|
|
|
|
| |
Build with configured NOTIFYDBUS_SUPPORT, SYSTEMD_LIBS, SYSTEMD_CFLAGS.
Also add proper build dependencies on internal libraries.
|
|
|
|
| |
Add correct build dependencies on internal libraries.
|
|
|
|
|
|
|
|
|
|
| |
Since configure.h is a generated header and it's missing traditional
ifdefs preambule - it can be included & parsed multiple times.
Normally compiler is fine when defines have same value and there is
no warning - yet we don't need to parse this several times
and by adding -include directive we can ensure every file
in the package is rightly compile with configure.h as the
first header file.
|
|
|
|
|
|
|
| |
When a VG is exported, the 'fullreport' returns an exit code of 5, but
otherwise returns the data we are wanting.
Signed-off-by: Tony Asleson <tasleson@redhat.com>
|
|
|
|
|
|
|
|
|
| |
In some cases we get stuck where we are unable to retrieve the current
state of lvm as we are encountering an error. When the error is
persistent we will log and exit the daemon instead of consuming vast
amounts of resources.
Signed-off-by: Tony Asleson <tasleson@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A bit of chicken & egg problem - dmeventd needs to use old libdm library.
VDO is only part of new device_mapper internal library.
So include directly source file for parsing status - this fixes usability
problem of VDO plugin introduced with previous Makefile reshaping
patchset.
NOTE: source file needs to be keep then compilable in both environments.
Also add missing copyright header.
|
|
|
|
| |
(cherry picked from commit 24254ca86671ae49431e67788c039603fe4b79fb)
|
| |
|
|
|
|
|
|
|
| |
Since there is very little change there will be any new devel going
to happing with cmirror - avoid eating extra disk space and link
with already installed libdm which implements all use basic
function of dm list
|
|
|
|
|
| |
Avoid linking internal device-mapper and link dynamically libdevmapper.
This considerably reduced size of installed binaries.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Since dmeventd is 'libdm' based project, it needs to link
libdm library instead of its internal version
An external users may provide plugins loadeable by dmeventd.
So external user of libdevmapper-event library has no other option
then to link with released libdevmapper library.
The complexity comes with lvm2 plugins.
The lvm2 plugin itself uses internal version of device_mapper,
but libdevmapper-event usage is libdm based - so there needs to be avoided
any breakage on compatibility of internal i.e. dm_task_run structures.
TODO: most likely dmeventd itself should be moved into libdm/dm-tools dir,
and only lvm2 plugins should be created as part of lvm project,
but those still need to link with libdevmapper.
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
If we don't know the meaning we will return the key with default text
instead of raising an exception and taking the daemon out in the
process.
Resolves: rhbz1657950
|
|
|
|
|
|
| |
When we get bug reports we may not get the entire log, so lets
dump the fight recorder from newest to oldest as the one we
are interested in was likely to be the last command run.
|
|
|
|
|
| |
Replace Makefile -I with full path to headers like we use now
everywhere else.
|