| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
Signed-off-by: Doug Ledford <dledford@redhat.com>
|
| |
|
|
|
|
|
| |
Two places have code to find a free md device number. Make this
a subroutine.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
From: Bill Nottingham <notting@redhat.com>
mdadm --incremental doesn't really do any locking. If you get multiple
events in parallel for the same device (that has not yet started), they
will all go down the path to create the array. One will succeed, the
rest will have SET_ARRAY_INFO die with -EBUSY (md: array mdX already has disks!)
and will exit without adding the disk.
Original bug report is: https://bugzilla.redhat.com/show_bug.cgi?id=433932
This is solved by adding very very rudimentary locking. Incremental() now
opens the device with O_EXCL to ensure only one invocation is frobbing the
array at once. A simple loop just tries to open 5 times a second for 5
seconds. If the array stays locked that long, you probably have bigger
issues.
|
|
|
|
| |
From: Bill Nottingham <notting@redhat.com>
|
| |
|
|
|
|
|
| |
This would only create partitioned devices if the device name was a
'standard' name. This this patch, any name will work.
|
|
|
|
|
|
|
| |
s/(major|minor)/\1_num/
Signed-off-by: maximilian attems <max@stro.at>
Signed-off-by: Neil Brown <neilb@suse.de>
|
|
|
|
|
| |
--incremental allows arrays to be assembled one device at a time.
This is expected to be used with udev.
|
|
|
|
|
| |
so the array devices with 'standard' names
get created automatically, as this is almost always what is wanted.
|
|
|
|
| |
From: "Michael Labuschke" <michael@labuschke.de>
|
|
|
|
|
|
| |
From: Luca Berra <bluca@comedia.it>
There is no need and it causes occasional problems.
|
| |
|
|
|
|
|
| |
When (auto)creating devices in /dev/md/, create
an appropriate symlink from /dev to avoid confusion.
|
|
|
|
|
| |
Never use /etc/mdadm.conf if --config file is given (previously
some code used one, some used the other).
|
|
|
|
|
|
| |
and assorted bugfixes.
Signed-off-by: Neil Brown <neilb@suse.de>
|
|
|
|
|
|
| |
This is just too risky.
Signed-off-by: Neil Brown <neilb@suse.de>
|
|
|
|
| |
Signed-off-by: Neil Brown <neilb@suse.de>
|
|
|
|
| |
Signed-off-by: Neil Brown <neilb@suse.de>
|
|
|
|
|
|
|
|
|
|
|
|
| |
So when you say auto=md or auto=part in mdadm.conf, it give a preference
for type of array, but standard name will override.
But --auto=md is more insistant.
FIXME I'm not at all happy about handling of names that already exist.
I don't think that should be removed if the device is active.
Signed-off-by: Neil Brown <neilb@suse.de>
|
|
|
|
|
|
| |
Default owner, group, mode and 'auto' flag can be given in a 'CREATE' line.
Signed-off-by: Neil Brown <neilb@suse.de>
|
|
|
|
|
|
|
| |
Whenever we need a device file to open, if one cannot be found in /dev,
create a temporary one.
Signed-off-by: Neil Brown <neilb@suse.de>
|
|
|
|
| |
Signed-off-by: Neil Brown <neilb@suse.de>
|
|
|
|
|
|
|
| |
This means that "-Ds" lists arrays in an approprate order
for assembly.
Signed-off-by: Neil Brown <neilb@suse.de>
|
|
|
|
|
|
| |
To quiet diet-libc
Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au>
|
|
|
|
| |
Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au>
|
|
|
|
| |
Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au>
|
|
|
|
| |
Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au>
|
|
|
|
| |
Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au>
|
|
|
|
|
|
|
|
|
| |
This allows for larger device number if glibc supports
it (requires 2.3.3).
Also fail before creating larger device number if glibc
support isn't present.
Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au>
|
|
|
|
| |
Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au>
|
|
|