]> sourceware.org Git - lvm2.git/log
lvm2.git
7 years agoman: remove hyphen escapes from source
David Teigland [Thu, 20 Jul 2017 21:26:13 +0000 (16:26 -0500)]
man: remove hyphen escapes from source

they are escaped by running sed in makefile

7 years agovgchange: split out code for systemid
David Teigland [Thu, 13 Jul 2017 18:43:39 +0000 (13:43 -0500)]
vgchange: split out code for systemid

Use the command definitions to separate the implementation
of vgchange systemid from the rest of vgchange.

7 years agovgchange: split out code for lockstart and lockstop
David Teigland [Thu, 13 Jul 2017 18:26:10 +0000 (13:26 -0500)]
vgchange: split out code for lockstart and lockstop

Use the command definitions to separate the implementation
of lockstop and lockstart from the rest of vgchange.

7 years agovgchange: separate change locktype and allow recovery
David Teigland [Wed, 12 Jul 2017 21:03:41 +0000 (16:03 -0500)]
vgchange: separate change locktype and allow recovery

Add an independent command definition for "vgchange --locktype",
and split the implementation out of the set of common metadata
changes.  It is unlike normal metadata changes, and can only
be run by itself.  (Changing the lock type is similar in
principle to changing the VG name or the VG system ID; it
effects the ability of any host to see or access the VG.)

At some point this command lost the ability to forcibly change
the lock type of a shared VG to "none" (making it a local VG).
This can be necessary to repair shared VGs (e.g. recovery steps
that occur in vg_read are disabled for shared VGs because
they are not locked properly, or recovering sanlock locks
when the PV holding them is lost.)

"vgchange --locktype none --lockopt force VG" is used as the
method of forcing the shared VG to become local so that it
can be repaired.

7 years agotidy: declaration names match implementation
Zdenek Kabelac [Thu, 20 Jul 2017 17:13:32 +0000 (19:13 +0200)]
tidy: declaration names match implementation

Put in sync some naming used for function declaration and
actual in-code implementation.

7 years agoraid: reshape synchronization point
Zdenek Kabelac [Thu, 20 Jul 2017 17:04:59 +0000 (19:04 +0200)]
raid: reshape synchronization point

Give udev time to get in sync and give md-core time to wake up
after table reload.

7 years agopost-release
Alasdair G Kergon [Thu, 20 Jul 2017 16:19:09 +0000 (17:19 +0100)]
post-release

7 years agopre-release v2_02_173
Alasdair G Kergon [Thu, 20 Jul 2017 15:57:27 +0000 (16:57 +0100)]
pre-release

7 years agoraid: avoid lv_size compiler warning
Alasdair G Kergon [Thu, 20 Jul 2017 15:16:51 +0000 (16:16 +0100)]
raid: avoid lv_size compiler warning

warning: declaration of ‘lv_size’ shadows a global declaration

7 years agoraid: move syncing with udev into function
Zdenek Kabelac [Thu, 20 Jul 2017 11:46:39 +0000 (13:46 +0200)]
raid: move syncing with udev into function

Since _deactivate_and_remove_lvs() is used in more then one place,
move the needed udev synchronization into this function so other
users automatically get correct fs state before next dm manipulation.

Assumption here is that this udev synchronization 'delay' may also
prevent to 'early' table reloads which might cause kernel problems
for md-core - but we may need more generic time-limited reload
frequency for raid devices.

Note: on udev-less system there will be almost no delay.

7 years agotests: aus.sh fix md teardown
Zdenek Kabelac [Thu, 20 Jul 2017 10:15:06 +0000 (12:15 +0200)]
tests: aus.sh fix md teardown

Commit 8a912d6dbcc34ce2b76a0104c39de7aa0480c512 missed the wrong logic,
we use 2 vars 'dev' & 'mddev' and their usage can't be mixed.

So correctly separate them so mddev keeps name of MD device.

7 years agotidy: drop unneeded cast
Zdenek Kabelac [Thu, 20 Jul 2017 07:57:09 +0000 (09:57 +0200)]
tidy: drop unneeded cast

Avoid casting to the same type.

7 years agotidy: name all parameters
Zdenek Kabelac [Thu, 20 Jul 2017 08:30:00 +0000 (10:30 +0200)]
tidy: name all parameters

7 years agotidy: drop unneeded return
Zdenek Kabelac [Wed, 19 Jul 2017 21:53:16 +0000 (23:53 +0200)]
tidy: drop unneeded return

7 years agotidy: else after continue
Zdenek Kabelac [Wed, 19 Jul 2017 21:12:48 +0000 (23:12 +0200)]
tidy: else after continue

Similar as with 'else' after 'return'  unindent whole block
for better readability of code.

7 years agotidy: prefer not using else after return
Zdenek Kabelac [Wed, 19 Jul 2017 14:16:12 +0000 (16:16 +0200)]
tidy: prefer not using else after return

clang-tidy: avoid using  'else' after return - give more readable code,
and also saves indention level.

7 years agocleanup: add braces in macro
Zdenek Kabelac [Wed, 19 Jul 2017 14:17:30 +0000 (16:17 +0200)]
cleanup: add braces in macro

7 years agocleanup: constify used parameter
Zdenek Kabelac [Wed, 19 Jul 2017 14:15:15 +0000 (16:15 +0200)]
cleanup: constify used parameter

7 years agodmsetup: simplify check of parsed cookie value
Zdenek Kabelac [Wed, 19 Jul 2017 20:04:37 +0000 (22:04 +0200)]
dmsetup: simplify check of parsed cookie value

Improving parsing error detection for strtoul.

7 years agotests: aux.sh fix wait_pvmove_lv_ready
Zdenek Kabelac [Wed, 19 Jul 2017 10:15:39 +0000 (12:15 +0200)]
tests: aux.sh fix wait_pvmove_lv_ready

Ignore error if the 'queried' LV is still not available
(since 'get' now properly returns failure when LV is missing)

7 years agotests: aus.sh better defaults
Zdenek Kabelac [Tue, 18 Jul 2017 19:25:03 +0000 (21:25 +0200)]
tests: aus.sh better defaults

7 years agotests: avoid endless loops
Zdenek Kabelac [Tue, 18 Jul 2017 19:17:51 +0000 (21:17 +0200)]
tests: avoid endless loops

If there is some problem with device removal avoid generating very long
error logs...

7 years agotests: aux.sh limit device
Zdenek Kabelac [Tue, 18 Jul 2017 11:14:02 +0000 (13:14 +0200)]
tests: aux.sh limit device

During test do a more close selection of visible devices.
If some test leaks a device with LVMTEST prefix, next
test should not be influnced (or parallel running one).

If the test is running in non-/dev  dir - it's already protected
by full path with $PREFIX in it - however it test is running
in real /dev dir - there was no such protection and test
were confused when they have seen such leaked device.

7 years agolvmcmdline: enhance locales check
Zdenek Kabelac [Mon, 17 Jul 2017 19:25:50 +0000 (21:25 +0200)]
lvmcmdline: enhance locales check

Make check for 'radixchar' more readable and logical.
Also avoid reread of number of locale is already using '.' as radixchar.

7 years agolvmcmdline: restore digit check
Zdenek Kabelac [Mon, 17 Jul 2017 18:36:39 +0000 (20:36 +0200)]
lvmcmdline: restore digit check

Commit 9b4b5d449ef7045d33b8d8d7e69011d16f4bb8ab started to accept
rather way to wide set of strings we do not want to take for size.
i.e.  lvresize -t vg0/lvol0 -LNaNM

Restore check for 'digit ||  locales defined 'dot' |  '.'
(as we tend to take '.' even if locales uses ',')

7 years agotests: better support for unbound vars for older shell
Zdenek Kabelac [Mon, 17 Jul 2017 18:32:48 +0000 (20:32 +0200)]
tests: better support for unbound vars for older shell

7 years agotests: aux.sh some backward compatible updates
Zdenek Kabelac [Mon, 17 Jul 2017 13:01:44 +0000 (15:01 +0200)]
tests: aux.sh some backward compatible updates

Older bash does not take empty array as bounded variable
(except for $@)

7 years agotest: repeat rediscovery few times
Zdenek Kabelac [Sun, 16 Jul 2017 16:29:20 +0000 (18:29 +0200)]
test: repeat rediscovery few times

Avoid using 'aux' shell when setting dmsetup cookie.
Do not user '--force' when using external cookie.

7 years agotests: aux.sh correcting bounder values
Zdenek Kabelac [Sun, 16 Jul 2017 18:41:13 +0000 (20:41 +0200)]
tests: aux.sh correcting bounder values

grep for defined PREFIX.
use 'dev' instead of undefined mddev.

7 years agotests: aux.sh also uses increseed hardening protection
Zdenek Kabelac [Sun, 16 Jul 2017 16:27:03 +0000 (18:27 +0200)]
tests: aux.sh also uses increseed hardening protection

Also use similar incresed hardeing of script correctness
for standalone aux scripts - so there is one common
logic for pipe failures.

7 years agotests: utils.sh look for more coredump places
Zdenek Kabelac [Sun, 16 Jul 2017 08:33:48 +0000 (10:33 +0200)]
tests: utils.sh look for more coredump places

Quoting helps to anyone storing coredumps inside dir with spaces....
Also add default dir for coredumps with systemd coredumpctl.

7 years agotests: extend lvcreate size validation
Zdenek Kabelac [Sun, 16 Jul 2017 09:18:13 +0000 (11:18 +0200)]
tests: extend lvcreate size validation

7 years agolvmetad: cleanup
Zdenek Kabelac [Sun, 16 Jul 2017 20:28:50 +0000 (22:28 +0200)]
lvmetad: cleanup

Avoid hashing insertion when object with same content is already there.

7 years agodev-cache: avoid hashing same data again
Zdenek Kabelac [Sun, 16 Jul 2017 18:56:58 +0000 (20:56 +0200)]
dev-cache: avoid hashing same data again

Before hashing device again with path, check if it's not already hashed.

TODO: maybe bigger chunk of executed code might be actually skipped.

7 years agolvmcmdline: enhance acceptance of size numbers
Zdenek Kabelac [Sun, 16 Jul 2017 08:30:07 +0000 (10:30 +0200)]
lvmcmdline: enhance acceptance of size numbers

Explictely detect duplicate sing symbols and leave the rest of
double number validation on 'strtod()' function. This way
we can also accept size like:

lvcreate -L.1M

We already accept -L0.1M - but it's common to accept numbers
starting with leading '.' - just as 'strtod()' accepts it).

7 years agocleanup: drop extra compare
Zdenek Kabelac [Sun, 16 Jul 2017 08:22:20 +0000 (10:22 +0200)]
cleanup: drop extra compare

dm_free() already validates for NULL itself.

7 years agocleanup: shorten dump output code
Zdenek Kabelac [Sun, 16 Jul 2017 16:22:52 +0000 (18:22 +0200)]
cleanup: shorten dump output code

Save couple lines on code with simpler code.

7 years agocleanup: drop const from allocated value
Zdenek Kabelac [Sun, 16 Jul 2017 16:21:41 +0000 (18:21 +0200)]
cleanup: drop const from allocated value

Avoid using const for casting to non-const.

7 years agonumbers: strtod or strtoul need reset of errno
Zdenek Kabelac [Sun, 16 Jul 2017 08:28:02 +0000 (10:28 +0200)]
numbers: strtod or strtoul need reset of errno

API for strtod() or strtoul() needs reset of errno, before it's being
called. So add missing resets in missing places and some also some
errno validation for out-of-range numbers.

7 years agolvmcmdline: validate size as double
Zdenek Kabelac [Sun, 16 Jul 2017 07:53:49 +0000 (09:53 +0200)]
lvmcmdline: validate size as double

Since we are reading size as (double) we can get way bigger
number then just plain int64. So to make this check actually
more valid and usable do a maxsize compare in 'double'.

7 years agoclvmd: fix valgrind memory report
Zdenek Kabelac [Mon, 17 Jul 2017 10:25:05 +0000 (12:25 +0200)]
clvmd: fix valgrind memory report

Avoid reading already released memory and do a continue directly.

Invalid read of size 1
   at 0x1201B0: main_loop (clvmd.c:931)
   by 0x11F640: main (clvmd.c:666)
 Address 0x72ddef0 is 32 bytes inside a block of size 224 free'd
   at 0x4C30D18: free (vg_replace_malloc.c:530)
   by 0x54D6FD1: dm_free_wrapper (dbg_malloc.c:357)
   by 0x122E6E: process_work_item (clvmd.c:2034)
   by 0x123003: lvm_thread_fn (clvmd.c:2085)
   by 0x590A3A8: start_thread (pthread_create.c:465)
   by 0x5C3C7FE: clone (in /usr/lib64/libc-2.25.90.so)
 Block was alloc'd at
   at 0x4C2FB6B: malloc (vg_replace_malloc.c:299)
   by 0x54D6EF1: dm_malloc_aux (dbg_malloc.c:286)
   by 0x54D6F1C: dm_zalloc_aux (dbg_malloc.c:291)
   by 0x54D6F96: dm_zalloc_wrapper (dbg_malloc.c:345)
   by 0x11F89C: local_rendezvous_callback (clvmd.c:731)
   by 0x1203D2: main_loop (clvmd.c:964)
   by 0x11F640: main (clvmd.c:666)

7 years agoclvmd: fix valgrind warning
Zdenek Kabelac [Mon, 17 Jul 2017 10:23:37 +0000 (12:23 +0200)]
clvmd: fix valgrind warning

Initialize mutex upfront any debugging and fix this report:

Mutex reinitialization: mutex 0x485d20, recursion count 0, owner 1.
   at 0x4C38480: pthread_mutex_init_intercept (drd_pthread_intercepts.c:821)
   by 0x4C38480: pthread_mutex_init (drd_pthread_intercepts.c:830)
   by 0x11F359: main (clvmd.c:562)
mutex 0x485d20 was first observed at:
   at 0x4C38F63: pthread_mutex_lock_intercept (drd_pthread_intercepts.c:885)
   by 0x4C38F63: pthread_mutex_lock (drd_pthread_intercepts.c:898)
   by 0x11E920: debuglog (clvmd.c:254)
   by 0x11F1D8: main (clvmd.c:527)

7 years agodevcache: correct logging severity for connection
Zdenek Kabelac [Sun, 16 Jul 2017 16:23:41 +0000 (18:23 +0200)]
devcache: correct logging severity for connection

Switch from warn to log_error since this generated
failing return code for command so printing log_error()
is mandatory.

Happens with i.e. pvscan --cache meets crashing lvmetad.

7 years agolvmetad: fix memory leaks
Zdenek Kabelac [Sun, 16 Jul 2017 08:20:37 +0000 (10:20 +0200)]
lvmetad: fix memory leaks

Hash tables need to release no longer needed inserted data.

7 years agoraid: add validation checks for segment data_offset member
Heinz Mauelshagen [Fri, 14 Jul 2017 22:50:19 +0000 (00:50 +0200)]
raid: add validation checks for segment data_offset member

Commit 34504855a70772e1de3f117a9a610860ead80981 introduced
flag LV_RESHAPE_DATA_OFFSET and used it to avoid incompatible
activation on older runtime.

Enhance vg_validate() raid checking functions with checks for it.

7 years agotests: use get_devs
Zdenek Kabelac [Fri, 14 Jul 2017 22:13:33 +0000 (00:13 +0200)]
tests: use get_devs

7 years agotests: utils.sh looks for more dumps
Zdenek Kabelac [Fri, 14 Jul 2017 22:12:07 +0000 (00:12 +0200)]
tests: utils.sh looks for more dumps

Check for core in  sysctl kernel.core_pattern
(assuming core prefix still)

7 years agotests: add udev_wait before tearing scsi_debug
Zdenek Kabelac [Fri, 14 Jul 2017 18:23:02 +0000 (20:23 +0200)]
tests: add udev_wait before tearing scsi_debug

Make less probably there will be some udev work going while we try
to remove scsi_debug target.

7 years agotests: aux.sh fix double quote
Zdenek Kabelac [Fri, 14 Jul 2017 18:16:54 +0000 (20:16 +0200)]
tests: aux.sh fix double quote

Patch 72a58ce4b0f68f6e45ae30606fe5af21caa42b43 was wronly placing
double quotes around this variable which we want to pass expanded,
as it's just set of 'space' device args ATM.

TODO consider using array[@] to make this cleaner.
Add shellcheck directive to skip warning here

7 years agotests: utils.sh six stacktrace
Marian Csontos [Fri, 14 Jul 2017 17:51:59 +0000 (19:51 +0200)]
tests: utils.sh six stacktrace

Changes:

- BASH_SOURCE index was one off.
- The first line of stacktrace was pure confusion displaying executed
  script together with innermost line number (which was either 125 when
  STACKTRACE or 229 when skip was called.)
- We can safely ignore innermost call, as stack trace is always produced
  by stacktrace function.
- It is safer to test for array length, instead of testing FUNCNAME is
  main - if main function were introduced.
- Bashishm is safe to use as this function as a whole is relying on bash.

7 years agoraid: add data_offset incompatibility segment type flag
Heinz Mauelshagen [Fri, 14 Jul 2017 13:52:18 +0000 (15:52 +0200)]
raid: add data_offset incompatibility segment type flag

In order to reject out of place reshaping with segment data_offset
field on old runtime, add a respective segment type incompatibility
flag causing "+RESHAPE_DATA_OFFSET" to be suffixed to the segment
type name.

7 years agoraid: use return_0 for better backtracking
Heinz Mauelshagen [Fri, 14 Jul 2017 12:05:21 +0000 (14:05 +0200)]
raid: use return_0 for better backtracking

7 years agoreport: fix data_offset/new_data_offset reporting
Heinz Mauelshagen [Thu, 13 Jul 2017 16:27:38 +0000 (18:27 +0200)]
report: fix data_offset/new_data_offset reporting

7 years agolvconvert: allow reshaping in the cluster and on open devices
Heinz Mauelshagen [Thu, 13 Jul 2017 16:27:19 +0000 (18:27 +0200)]
lvconvert: allow reshaping in the cluster and on open devices

The previous commit fixed allocation/activation of reshape space.

Remove conditionals prohibiting reshaping in these cases.

Related: rhbz1447812
Related: rhbz1448116
Related: rhbz1461562

7 years agoraid: fix allocation/activation of reshape space
Heinz Mauelshagen [Thu, 13 Jul 2017 16:26:43 +0000 (18:26 +0200)]
raid: fix allocation/activation of reshape space

When reshape space is allocated anew, an update and reload is needed to
promote the new size to the cluster node with the exclusively active RaidLV
or reloading the RaidLV will fail with a size related error.  Additionally,
store "data_offset <sectors>" with the RaidLV in the lvm2 metadata so that
it can be retrieved on cluster nodes.

Process allocation of reshape space on a 2-legged raid4/5 (interim layout
to convert from/to linear via raid1) properly in the cluster.

Resolves: rhbz1461562
Resolves: rhbz1448116

7 years agotests: aux.sh integrate both teardown loops
Zdenek Kabelac [Fri, 14 Jul 2017 11:22:15 +0000 (13:22 +0200)]
tests: aux.sh integrate both teardown loops

Use 1 logic for 2 loops tearing down left device.
First loops tries to remove all closed devices with 'normal' remove.
Second loop tries to replace those left devices with 'error' target.

7 years agotests: skip test for non dirty cache
Zdenek Kabelac [Thu, 13 Jul 2017 22:42:40 +0000 (00:42 +0200)]
tests: skip test for non dirty cache

Seems some cache LV can't be made dirty easily with older
cache policy implementations....

7 years agotests: aux.sh better teardown loop
Zdenek Kabelac [Thu, 13 Jul 2017 22:27:55 +0000 (00:27 +0200)]
tests: aux.sh better teardown loop

We can't really sleep that much in teardown as it slows test too much.
So do a nested loop (similar to 'dmsetup remove_all') and keep
removing devices with open count == 0 as long as it works.

7 years agotests: wait for udev to minize race windows
Zdenek Kabelac [Thu, 13 Jul 2017 19:10:06 +0000 (21:10 +0200)]
tests: wait for udev to minize race windows

mkfs can complain about volume in use when meets udev rule processing.

7 years agotests: bound variables
Zdenek Kabelac [Thu, 13 Jul 2017 19:09:45 +0000 (21:09 +0200)]
tests: bound variables

7 years agotests: delay read of cache pool data
Zdenek Kabelac [Thu, 13 Jul 2017 19:08:49 +0000 (21:08 +0200)]
tests: delay read of cache pool data

It's better to delay read of cached data.
Limit loop checking for cleaner policy.

7 years agotests: add some delay after dmsetup
Zdenek Kabelac [Thu, 13 Jul 2017 19:06:04 +0000 (21:06 +0200)]
tests: add some delay after dmsetup

When we want to squash as much device as possible,
it's better to give it some delay, so devices have
some time to release it's resouces for next removal.

Also drop surrounding cookie processing and let each
dmsetup call run on its own.

7 years agoformat_text: Extend FIXME to reduce label scans
Alasdair G Kergon [Thu, 13 Jul 2017 16:05:49 +0000 (17:05 +0100)]
format_text: Extend FIXME to reduce label scans

It's unnecessarily scanning all invalid labels even when nothing changed
instead of first just scanning the ones under the lock.

7 years agodocs: Refresh kernel target docs
Alasdair G Kergon [Wed, 12 Jul 2017 17:59:07 +0000 (18:59 +0100)]
docs: Refresh kernel target docs

7 years agotests: fix for new hardened bash
Zdenek Kabelac [Wed, 12 Jul 2017 16:03:10 +0000 (18:03 +0200)]
tests: fix for new hardened bash

Add missing get_devs.
When $7 is not given use empty string.
See if we can live with less RAM disk for PVs.
Drop limitation on single core as presence 1.12 should address this.

7 years agopvs: use dummy structs in duplicate processing
David Teigland [Wed, 12 Jul 2017 15:51:54 +0000 (10:51 -0500)]
pvs: use dummy structs in duplicate processing

Use the same dummy struct approach from report.c
when a pv needs to be processed without a real vg.

7 years agotests: properly check variables were defined
Zdenek Kabelac [Wed, 12 Jul 2017 11:51:16 +0000 (13:51 +0200)]
tests: properly check variables were defined

When test suite is installed some vars are not defined.

7 years agotests: use properly quoted device list
Zdenek Kabelac [Wed, 12 Jul 2017 11:50:25 +0000 (13:50 +0200)]
tests: use properly quoted device list

7 years agotests: fix detection of running dmeventd after test
Zdenek Kabelac [Wed, 12 Jul 2017 11:38:07 +0000 (13:38 +0200)]
tests: fix detection of running dmeventd after test

The checking order here has happend after TESTDIR was removed
resulting in weird further error on trap path.

Properly check for unexpected dmeventd before removing TESTDIR
since  'trap' codepath is still using it.

Also try to kill this unexpected dmeventd so testing is
not skipping all next  dmeventd tests.

(Downside would be - if user would be accidentally starting
dmeventd by some regular system admin work - such dmeventd
might be killd if it's unused. It can't kill dmeventd in-use.

7 years agotests: utils.sh drop gdb_commands.txt
Zdenek Kabelac [Tue, 11 Jul 2017 23:50:06 +0000 (01:50 +0200)]
tests: utils.sh  drop gdb_commands.txt

Remove file after use (fixes recursive STACKTRACE calls)

7 years agotests: bounds still more vars
Zdenek Kabelac [Tue, 11 Jul 2017 23:37:29 +0000 (01:37 +0200)]
tests: bounds still more vars

7 years agotests: drop type
Zdenek Kabelac [Tue, 11 Jul 2017 23:20:22 +0000 (01:20 +0200)]
tests: drop type

Assuming test wanted to check $lv3 does not exists.

7 years agotests: more exact test
Zdenek Kabelac [Tue, 11 Jul 2017 23:16:10 +0000 (01:16 +0200)]
tests: more exact test

Check there is really just linear.

Also short-circuit mimages_are_on_ when file is empty
(avoids unbound  mimages[@] access on older bash)

7 years agotests: more vars bounded
Zdenek Kabelac [Tue, 11 Jul 2017 23:15:41 +0000 (01:15 +0200)]
tests: more vars bounded

7 years agotests: aux.sh better loop logic
Zdenek Kabelac [Tue, 11 Jul 2017 23:14:36 +0000 (01:14 +0200)]
tests: aux.sh better loop logic

Instead of using pipe for read and haveing no chance
to modify shell vars inside such loop  use  <( )
and keep using bash arrays.

7 years agotests: improve logic for a race to catch abortion
Zdenek Kabelac [Tue, 11 Jul 2017 15:20:24 +0000 (17:20 +0200)]
tests: improve logic for a race to catch abortion

7 years agotests: hardening - no unbound vars
Zdenek Kabelac [Tue, 11 Jul 2017 09:23:34 +0000 (11:23 +0200)]
tests: hardening - no unbound vars

Dissallow usage of any unbound shell variable in tests.
All vars needs to have some defined value.

7 years agotests: check.sh simplify in_sync
Zdenek Kabelac [Tue, 11 Jul 2017 11:29:54 +0000 (13:29 +0200)]
tests: check.sh simplify in_sync

Avoid calling sed.

7 years agotests: double quote
Zdenek Kabelac [Tue, 11 Jul 2017 09:23:14 +0000 (11:23 +0200)]
tests: double quote

7 years agotests: correct typo
Zdenek Kabelac [Tue, 11 Jul 2017 09:19:09 +0000 (11:19 +0200)]
tests: correct typo

Use defined MARKED_AS_USED_MSG shell var.

7 years agotests: avoid unbound shell var usage
Zdenek Kabelac [Tue, 11 Jul 2017 09:18:22 +0000 (11:18 +0200)]
tests: avoid unbound shell var usage

7 years agotests: improve test logic
Zdenek Kabelac [Tue, 11 Jul 2017 09:16:24 +0000 (11:16 +0200)]
tests: improve test logic

Use existing vars.
Reduce extra lvchange -an and use directly activation with lvcreate.

7 years agocleanup: whitespace
Zdenek Kabelac [Tue, 11 Jul 2017 09:21:18 +0000 (11:21 +0200)]
cleanup: whitespace

7 years agocommands: fix lvm shell segfaults
Alasdair G Kergon [Tue, 11 Jul 2017 00:42:06 +0000 (01:42 +0100)]
commands: fix lvm shell segfaults

Don't check for -h/--help if argc is 1.

7 years agolvm: report error if options are set before command
David Teigland [Mon, 10 Jul 2017 16:00:28 +0000 (11:00 -0500)]
lvm: report error if options are set before command

Previously, strange parsing errors were reported.

7 years agolvm: run help from -h|--help
David Teigland [Mon, 10 Jul 2017 15:43:47 +0000 (10:43 -0500)]
lvm: run help from -h|--help

7 years agotests: avoid using readarray
Zdenek Kabelac [Mon, 10 Jul 2017 15:40:31 +0000 (17:40 +0200)]
tests: avoid using readarray

Real bashman can live without readarray.

Support older tested machines with bash <4.0....

7 years agoman: specify slow device when creating origin LV
Eric Ren [Sat, 8 Jul 2017 17:15:51 +0000 (01:15 +0800)]
man: specify slow device when creating origin LV

Also make the slow device name consistent everywhere.

Signed-off-by: Eric Ren <zren@suse.com>
7 years agocleanup: fix some typos
Eric Ren [Sat, 8 Jul 2017 17:21:38 +0000 (01:21 +0800)]
cleanup: fix some typos

form -> from
accomodate -> accommodate

Signed-off-by: Eric Ren <zren@suse.com>
7 years agocomment: update
Eric Ren [Sat, 8 Jul 2017 17:15:49 +0000 (01:15 +0800)]
comment: update

Use 'is' for both forms.

7 years agotests: using prepare_vg
Zdenek Kabelac [Sun, 9 Jul 2017 13:55:10 +0000 (15:55 +0200)]
tests: using prepare_vg

7 years agotests: assign path
Zdenek Kabelac [Sun, 9 Jul 2017 13:54:43 +0000 (15:54 +0200)]
tests: assign path

7 years agotests: fix array usage
Zdenek Kabelac [Sat, 8 Jul 2017 20:29:50 +0000 (22:29 +0200)]
tests: fix array usage

Use bash arrays to pass devs.

7 years agotests: simplify and doublequote
Zdenek Kabelac [Sat, 8 Jul 2017 16:23:07 +0000 (18:23 +0200)]
tests: simplify and doublequote

7 years agotests: use well defined test
Zdenek Kabelac [Fri, 7 Jul 2017 19:31:38 +0000 (21:31 +0200)]
tests: use well defined test

Prefer [ p ] && [ q ] as [ p -a q ] is not well defined.

Apparently && and || "short-circuit" while -a and -o do not.

7 years agotests: cleaner written eval
Zdenek Kabelac [Fri, 7 Jul 2017 19:24:57 +0000 (21:24 +0200)]
tests: cleaner written eval

Although code work this coding style is better.
This \c will be a regular 'c' in this context.

7 years agotests: mixes string and array
Zdenek Kabelac [Fri, 7 Jul 2017 19:24:17 +0000 (21:24 +0200)]
tests: mixes string and array

Argument mixes string and array. Use * or separate argument

7 years agotests: fix caller of mirror_images_on
Zdenek Kabelac [Fri, 7 Jul 2017 19:18:56 +0000 (21:18 +0200)]
tests: fix caller of mirror_images_on

Missed vg name.

7 years agotests: fix working with devs in array
Zdenek Kabelac [Sat, 8 Jul 2017 16:23:47 +0000 (18:23 +0200)]
tests: fix working with devs in array

Also fixes one instance of invalid  'mirror_image_on' test
and places there correct indexed set of PVs.

7 years agotests: check mirror_images_on fixed
Zdenek Kabelac [Fri, 7 Jul 2017 19:17:03 +0000 (21:17 +0200)]
tests: check mirror_images_on fixed

Fix mirror_images_on() to actually report something useful (thought
it might be tuned later).

So for now the function got through all '_mimages_' and compares
where the order of them is matching given list of devices.

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