Statistics
| Branch: | Tag: | Revision:

root / lib / storage @ 0c3d9c7c

# Date Author Comment
0c3d9c7c 09/24/2013 09:17 am Thomas Thrainer

Replace physical_id with dynamic_params

The disk field 'physical_id' has to be kept up to date whenever a disk
object is sent to a node via RPC. This is done with the SetDiskID method
manually, which is a source of bugs.

This patch replaces the use of 'physical_id' with a new field names...

0c5f1b13 09/12/2013 03:23 pm Thomas Thrainer

Merge branch 'stable-2.9' into master

  • stable-2.9
    Fix bridging in net-common
    Sync build_chroot with buildbot slack role
    Auto-upgrade of disks' config wrt LD-renaming
    Fix tests regarding DISK_LD_DEFAULTS
    Fixing renaming of DISK_LD_DEFAULTS
    Replace LD_* constants with DT_* constants...
6da90c0a 08/28/2013 10:13 pm Helga Velroyen

Fixing renaming of DISK_LD_DEFAULTS

This fixes the somewhat over-eager renaming of
DISK_LD_DEFAULTS to DISK_DT_DEFAULTS, which clashes
with another occurence of DISK_DT_DEFAULTS. This
patch just undoes the renaming and additionally fixes
a test regarding shared file storage....

cd3b4ff4 08/28/2013 06:19 pm Helga Velroyen

Replace LD_* constants with DT_* constants

LD_* constants are basically like DT_* constants, except
for that both file and shared file were mapped to file.
In order to not having to maintain three slightly different
sets of disk-related constants (DT, LD and ST), we merge...

78f99abb 08/23/2013 03:12 pm Michele Tartara

Lint improvements to regexps

Fix some regular expressions so that they pass lint checks with newer versions
of pylint.

Signed-off-by: Michele Tartara <>
Reviewed-by: Helga Velroyen <>

1ca326c8 08/07/2013 06:46 pm Thomas Thrainer

Merge branch 'stable-2.9'

  • stable-2.9
    Fix batch creation of instances
    Fix documentation of gnt-instance batch-create
    Support multi instance allocs without iallocator
    Support DSA SSH keys in bootstrap
    Include VCS version in `gnt-cluster version`...
4b322a76 07/29/2013 03:27 pm Helga Velroyen

gnt-cluster verify: consider shared file storage

This patch enhances 'gnt-cluster verify' in a way that it
now validates the acceptance and existance of the shared
storage directory.

Signed-off-by: Helga Velroyen <>
Reviewed-by: Thomas Thrainer <>

22283069 07/19/2013 04:13 pm Michele Tartara

Merge branch 'stable-2.9' into master

  • stable-2.9
    Fix parsing of drbdsetup show output for DRBD 8.4
    Revert "Disable failing QA test"
    Add unit test for drbdsetup show parsing
    GenerateDiskTemplate: Proper check for valid disk templates
    Fix iallocator unit tests...
2650ea6b 07/17/2013 05:34 pm Helga Velroyen

Fix deprecation warning about exception

This fixes a deprecation warning regarding the retrieval
of the error message from an exception.

Signed-off-by: Helga Velroyen <>
Reviewed-by: Klaus Aehlig <>

f3ebe73e 07/17/2013 05:34 pm Helga Velroyen

Move bdev unit tests to filestorage unit tests

Some code was moved from bdev to file storage in
previous patches, but the related unit tests were
accidentally left in bdev. Moving and adjusting
them now.

Signed-off-by: Helga Velroyen <>...

8f8442d6 07/17/2013 11:11 am Thomas Thrainer

Fix parsing of drbdsetup show output for DRBD 8.4

DRBD 8.4 contains two `disk` entries under the `volume` section. In some
circumstances, the parsing code could wrongly use the empty one which
causes DRBD8Dev._SlowAssemble() to fail. This fixes issue 516....

5ee24e45 07/16/2013 12:17 pm Helga Velroyen

Improve debugging output of DRBD8 status

Signed-off-by: Brian Candler <>
Reviewed-by: Helga Velroyen <>

9c1c3c19 07/15/2013 12:34 pm Helga Velroyen

Verify file storage path

This patch adds two verification steps to 'gnt-cluster
verify':
- The configured file storage directory is checked against
the allowed file storage directories file.
- We check whether the configured file storage directory
is existing and writable on each node....

13a6c760 07/15/2013 12:34 pm Helga Velroyen

Prepare verification code for new file path verification

This patch prepares the verification code for adding
a new verification step for the file storage paths:
- It moves a couple of file storage helper functions from
bdev to filestorage (since they make more sense there...

1f7c8208 07/15/2013 12:34 pm Helga Velroyen

backend: remove ENABLE_FILE_STORAGE

This patch removes the usage of the ENABLE_FILE_STORAGE
constant in the backend code. To avoid having to pass
it through various RPC calls, we instead move the check
to cmdlib.

Signed-off-by: Helga Velroyen <>...

65fc2388 07/03/2013 09:52 am Thomas Thrainer

Make DRBD replication protocol configurable

Add a new disk parameter which allows to choose the DRBD replication
protocol. The protocol is fixed to "C" during dual primary mode though.

Signed-off-by: Thomas Thrainer <>
Reviewed-by: Klaus Aehlig <>

c31ec06b 06/28/2013 03:38 pm Bernardo Dal Seno

Don't exceed the standard PV size when growing a disk

With exclusive storage, PVs are supposed to be used only up to the
standard PV size.

Signed-off-by: Bernardo Dal Seno <>
Reviewed-by: Klaus Aehlig <>

be9150ea 06/28/2013 03:38 pm Bernardo Dal Seno

Limit the PVs used for disk growth with exclusive storage

The exclusive storage flag is passed along in the backend functions for
disk growth. LVM volumes handles the flag by reusing the same PVs, as disks
are constrained by the number of their spindles....

32389d91 06/14/2013 02:43 pm Helga Velroyen

Refactor NodeInfo RPC regarding storage reporting

The NodeInfo RPC call is refactored to handle now more than
just storage reporting for volume groups.

Since NodeInfo now returns storage space information not
necessarily for volume groups, but also for other storage...

13669ecd 06/14/2013 02:43 pm Helga Velroyen

Integrate free space reporting for file storage

This patch integrates the free space reporting for file
storage. So far, it is only called, when the default
disk template is a file-based disk template ("file" or
"sharedfile").

Signed-off-by: Helga Velroyen <>...

e798d484 06/14/2013 02:43 pm Helga Velroyen

Renamining space reporting for file storage

Before being integrated, the function for space reporting
for file storage is renamed to a more expressive name.

Signed-off-by: Helga Velroyen <>
Reviewed-by: Thomas Thrainer <>

d0d7d7cf 06/13/2013 12:32 pm Thomas Thrainer

Inline simple "alias" variables

Remove variables in the form "var = self.var" throughout all LU's. Those
"alias" variables make it harder to read the code (it's no longer
immediately clear what's a field and what's a local variable), and can
introduce subtle bug (especially when not used consistently and when...

a1860404 06/07/2013 04:10 pm Bernardo Dal Seno

node_info RPC reports info about free spindles

node_info RPC can be used to get information about free/total spindles.

Signed-off-by: Bernardo Dal Seno <>
Reviewed-by: Klaus Aehlig <>

577edf04 05/28/2013 12:46 pm Bernardo Dal Seno

Adapt striping to the requested number of spindles

Otherwise LVM may use a smaller number of PVs (spindles) to accommodate for
the default stripes.

Signed-off-by: Bernardo Dal Seno <>
Reviewed-by: Helga Velroyen <>

7c848a6a 05/28/2013 12:46 pm Bernardo Dal Seno

Spindles are mandatory with exclusive storage

If they are not specified in the command line an error is reported. Also,
disk creation would fail without them.

QA has been updated.

Signed-off-by: Bernardo Dal Seno <>
Reviewed-by: Helga Velroyen <>

baa7f1d6 05/28/2013 12:45 pm Bernardo Dal Seno

New BlockDev methods to get spindles

Two new methods are created to get the number of spindles, one alone, and
one together with size. For devices that don't support spindles, None is
returned.

Signed-off-by: Bernardo Dal Seno <>
Reviewed-by: Helga Velroyen <>

b5d48e87 05/28/2013 12:45 pm Bernardo Dal Seno

Attaching a logical volume builds a list of PVs

When an LV gets attached, the list of the PVs used by the LV is built. This
will be used to count spindles for exclusive_storage, but it could also be
useful to optimize disk growing and snapshotting.

Signed-off-by: Bernardo Dal Seno <>...

688b5752 05/28/2013 12:45 pm Bernardo Dal Seno

Refactor code for attaching a logical volume

The parsing of "lvs" output is moved into private methods. The code is
slightly more readable and testable. The split in two methods is useful
for the following patches. Unit tests for the new functions are
provided....

24c06acb 05/23/2013 02:04 pm Bernardo Dal Seno

Spindles are used in creating new disks

The requested number of spindles is used to allocate PVs when creating new
LVs.

Signed-off-by: Bernardo Dal Seno <>
Reviewed-by: Thomas Thrainer <>

5073fa0c 05/23/2013 02:03 pm Bernardo Dal Seno

Document disk device Create() functions

Document all the arguments and return values of bdev.Create() and
bdev.BlockDev.Create().

Signed-off-by: Bernardo Dal Seno <>
Reviewed-by: Thomas Thrainer <>

5d94c034 05/15/2013 03:02 pm Helga Velroyen

Use os.statvfs to determine free disk space

This simplifies my previous commit (820bade90) by using os.statvfs
instead of parsing the output of 'df'.

Signed-off-by: Helga Velroyen <>
Reviewed-by: Bernardo Dal Seno <>

820bade9 05/14/2013 10:17 pm Helga Velroyen

Backend function for file storage space reporting

This adds functionality to retrieve disk space information
for file storage. It calls the 'df' tool and parses its
output to extract the total and free amount of disk space
on the disk where the given path is located....

8f096849 05/14/2013 04:46 pm Helga Velroyen

Move 'container.py' to storage directory

Moving 'container.py' to the storage directory.

Signed-off-by: Helga Velroyen <>
Reviewed-by: Thomas Thrainer <>

cde49218 05/14/2013 04:46 pm Helga Velroyen

Rename dir 'block' to 'storage'

Renaming the 'block' directory to 'storage', because I plan to
place code there that is related to file storage and leaving
it named 'block' would be misleading.

Signed-off-by: Helga Velroyen <>
Reviewed-by: Thomas Thrainer <>