1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-21 13:34:40 +03:00
Commit Graph

15819 Commits

Author SHA1 Message Date
Zdenek Kabelac
8949903fbb cache: set areas count prior using it
Set correct counter, so it's not failing on internal error check.
2018-06-25 15:07:32 +02:00
Zdenek Kabelac
6b3a4aac09 vcfgrestore: add prompt with active volumes
Add check for active device with names matching restored VG.
When such devices are present in dm table, prompt user, if he
wish to continue.
2018-06-22 23:37:36 +02:00
Zdenek Kabelac
106ee05ba0 lv_manip: add extra internal error
Catch error early, when trying to store data into non-allocated area.
2018-06-22 23:37:02 +02:00
Zdenek Kabelac
6c84a36b53 utils: add clzll
Check for __builtin_clzll and add wrapper when missing.
2018-06-22 23:37:02 +02:00
Zdenek Kabelac
8215e3503d tests: fix rules for mke2fs.conf install 2018-06-22 23:36:54 +02:00
Zdenek Kabelac
fa58fc3257 build: support --disable-silent-rules
Add support for standardized option for have verbose builds.
Useful for distro builds where more details can be useful.
2018-06-22 23:36:19 +02:00
Zdenek Kabelac
c728d88e11 build: include configure.h
It's important to consistenly include  configure.h as the 1st. header.
It containts #defines influencing behavior of other included header
files.
2018-06-22 23:11:44 +02:00
Zdenek Kabelac
086f1ef4a0 build: make generate 2018-06-22 15:36:34 +02:00
Joe Thornber
254e5c5d11 radix-tree: squash a pointer arithmetic warning 2018-06-21 17:41:56 +01:00
Joe Thornber
18528180d9 Merge branch 'master' of git+ssh://sourceware.org/git/lvm2 2018-06-21 17:12:09 +01:00
Joe Thornber
72e2e92f4c radix-tree: fix bug when erasing elts in remove_prefix
_erase_elt() now zeroes the last element of the array (ie. sets to
UNSET).  Previously remove() was doing this, but not remove_prefix().
2018-06-21 17:10:05 +01:00
David Teigland
dd7ebec120 filter: use pointers to real addresses
instead of casting values 1 and 2 to pointers
which gcc optimization can have problems with.
2018-06-21 10:54:43 -05:00
David Teigland
15826214f9 Remove code for using files as devices
It appears this has not been used in a long time,
and it seems to have no point since loop devices exist.
2018-06-21 09:33:21 -05:00
David Teigland
e166d2b14c lvmlockd: fix another missing lock_type null check
Same as 347c807f8.
2018-06-21 09:24:51 -05:00
Joe Thornber
40c1f7889f radix-tree: More debugging of remove
There's now a pretty printer called radix_tree_dump()

n4, n16, and n48 weren't UNSETting the last entry after
sliding values down.
2018-06-21 09:49:43 +01:00
Joe Thornber
c8cfbfa605 radix_tree: add new test case
Check that value destructors are called by radix_tree_destroy()
2018-06-21 09:49:25 +01:00
Joe Thornber
20b9746c5d radix-tree: FIx various bugs to do with removal
Add radix_tree_is_well_formed() which does some sanity checking
of the tree.

Call the above a lot in the unit tests.

Fix revealed bugs.
2018-06-21 09:49:08 +01:00
David Teigland
42f7caf1c2 scan: work around udev problems by avoiding open RDWR
udev creates a train wreck of events if we open devices
with RDWR.  Until we can fix/disable/scrap udev, work around
this by opening RDONLY and then closing/reopening RDWR when
a write is needed.  This invalidates the bcache blocks for
the device before writing so it can trigger unnecessary
rereading.
2018-06-20 14:08:12 -05:00
David Teigland
f85a010a6b bcache: remove extraneous error message
an error from io_submit is already recognized by
the caller like errors during completion.
2018-06-18 12:02:22 -05:00
David Teigland
565df4e732 Print advice about changing clustered VGs to shared 2018-06-18 10:59:11 -05:00
David Teigland
428514a07f Drop --ignoreskippedcluster option
It's no longer needed.  Clustered VGs are now handled in
the same way as foreign VGs, and as shared VGs that
can't be accessed:

- A command processing all VGs sees a clustered VG,
  prints a message ("Skipping clustered VG foo."),
  skips it, and does not fail.

- A command where the clustered VG is explicitly
  named on the command line, prints a message and fails.
  "Cannot access clustered VG foo, see lvmlockd(8)."

The option is listed in the set of ignored options for
the commands that previously accepted it.  (Removing it
entirely would cause commands/scripts to fail if they
set it.)
2018-06-15 15:59:34 -05:00
David Teigland
ccab4a1994 report: show empty lock_type for none
Sometimes lock_type would be displayed as "none"
(after changing it) and sometimes as empty.
Make it consistently empty.
2018-06-15 14:14:39 -05:00
David Teigland
328303d4d4 Remove unused device error counting 2018-06-15 14:04:39 -05:00
David Teigland
54f61e7dcc config: add deprecated version for recently removed settings
assumes that the next version from this branch is 3.0.0
2018-06-15 13:56:26 -05:00
David Teigland
3fd75d1bcd scan: use full md filter when md 1.0 devices are present
The md filter can operate in two native modes:
- normal: reads only the start of each device
- full: reads both the start and end of each device

md 1.0 devices place the superblock at the end of the device,
so components of this version will only be identified and
excluded when lvm uses the full md filter.

Previously, the full md filter was only used in commands
that could write to the device.  Now, the full md filter
is also applied when there is an md 1.0 device present
on the system.  This means the 'pvs' command can avoid
displaying md 1.0 components (at the cost of doubling
the i/o to every device on the system.)

(The md filter can operate in a third mode, using udev,
but this is disabled by default because there have been
problems with reliability of the info returned from udev.)
2018-06-15 12:21:25 -05:00
David Teigland
8eab37593e Add cmd arg to more functions
so that it can be used in the filter code
2018-06-15 11:03:55 -05:00
Zdenek Kabelac
27c647d6ce rpm: drop no longer present clvmd, lvm2app 2018-06-15 00:47:35 +02:00
Zdenek Kabelac
2a7f2a3a24 tests: more tolerable makefile 2018-06-15 00:46:54 +02:00
Zdenek Kabelac
7d8bd97187 scripts: clvmd gone 2018-06-15 00:46:24 +02:00
Zdenek Kabelac
9d2b9e5bc6 man: stop installing clvmd man page 2018-06-15 00:46:08 +02:00
Zdenek Kabelac
52e7270e23 man-generator: drop macro redefines 2018-06-14 23:22:42 +02:00
Zdenek Kabelac
faf3cc8f71 tests: drop some clvmd refs
Do not try to link clvmd binary.
Ensure lib is created new and does not refer old binaries.
2018-06-14 23:22:42 +02:00
Zdenek Kabelac
b2cb8f846a build: cmirrord with internal dm lib 2018-06-14 23:14:04 +02:00
Zdenek Kabelac
b1729dbcdd tests: bigger lv
Although throttling slows down things considerable, it still could
reach the end before next test so use bigger LV.
2018-06-14 22:02:01 +02:00
Zdenek Kabelac
f4abbafde7 debug: missing trace 2018-06-14 22:02:01 +02:00
Zdenek Kabelac
b58160a191 systemd: add conficting sockets
Since we are using "DefaultDependencies=no" we do not get automatic STOP
job on socket connection - so automatically refuse connection on
shutdown by adding this Conflict definition to socket Unit.
2018-06-14 22:02:01 +02:00
Zdenek Kabelac
a35098b110 vgchange: start polling with activation
Shuffle code for better readability as set of conditions was
hard to follow.

Make it obvious the refresh & activate path is handling
monitoring and polling on its own.

So the only --monitor and --poll option needs explicit care.
Option --monitor without option --poll will now as a result
of this patch NOT start polling.

So command: vgchange --monitor n    is no longer a polling starter.
2018-06-14 22:02:01 +02:00
Zdenek Kabelac
218c57410c pvscan: move start of polling into vgchange
Restoring polling for activated volumes lost with my recent commit:
75fed05d3e and move start of polling
directly into _activate_lvs_in_vg() - as there we know exactly
if there was some volume even activated.

Also make it sharing same code for pvscan -aay.
2018-06-14 22:02:01 +02:00
Zdenek Kabelac
752c39d91d pvscan: code reshape 2018-06-14 22:02:01 +02:00
Zdenek Kabelac
33703995ae vgchange: trace faling activation
Trace failed activation and directly assign 0 returning failure.
2018-06-14 22:02:01 +02:00
Zdenek Kabelac
f38a54227d vgchange: move active assing
Make eval of activate_ARG reusable.
2018-06-14 22:02:01 +02:00
Zdenek Kabelac
70b159d145 vgchange: fix error code in error path
This rather hard to hit error path used wrong return value to signal
real error.
2018-06-14 22:02:01 +02:00
Zdenek Kabelac
3eff3aa4f8 device_mapper: drop unneeded function
Subdir without stats.
2018-06-14 22:02:01 +02:00
Zdenek Kabelac
5b515db71b build: better srcdir builddir support
With the move to top-level makefile - there are some issues
with subdir recursive makefile.
Make the building more tolerant for now until fully resolved.
2018-06-14 22:02:01 +02:00
Zdenek Kabelac
52ab3c1584 build: drop libdm referring from lvm code
Avoid adding /libdm  paths into lvm building.
2018-06-14 22:02:01 +02:00
Zdenek Kabelac
a457566e91 build: drop some lvm references from libdm making
Some simplification, more may follow...
2018-06-14 22:02:01 +02:00
Zdenek Kabelac
c6be409609 build: ensure libdm is built before dm-tools
Making libs before entering dm-tools subdir,
so the tool will not link i.e. system library if present.
2018-06-14 22:02:01 +02:00
David Teigland
327f62a255 man: update lvmsystemid wording
to refer to "shared VG" instead of "lockd VG".
2018-06-14 12:35:00 -05:00
David Teigland
b5f444d447 man: updates to lvmlockd
The terminology has migrated toward using "shared VG"
rather than "lockd VG".

Also improve the wording in a number of places.
2018-06-14 12:35:00 -05:00
Joe Thornber
e84e9cd115 device_mapper: remove libdm-stats.c
We don't use it in lvm.
2018-06-14 14:32:17 +01:00