summaryrefslogtreecommitdiffstats
path: root/config.c
Commit message (Collapse)AuthorAgeFilesLines
* Fix for segfault when reading /proc/mdstatNeil Brown2008-04-281-0/+13
| | | | | | | | | Some kernel versions don't put a space between 'active' and '(auto-read-only)' in /proc/mdstat. This causes a parsing problem leaving 'level' set to NULL which causes a crash. So synthesise a space there if it is missing, and check for 'level' to be NULL and don't de-ref if it is.
* Remove spaces/tabs from ends of lines.Neil Brown2007-12-141-7/+7
|
* config.c include dirent.h instead sys/dir.hmaximilian attems2007-09-241-1/+1
| | | | | | | | | | sys/dir.h is an old BSD'ism, include dirent directly. small step for better klibc support. compile tested against glibc. Signed-off-by: maximilian attems <max@stro.at> Signed-off-by: Neil Brown <neilb@suse.de>
* Add new mode: --incrementalNeil Brown2006-12-211-1/+17
| | | | | --incremental allows arrays to be assembled one device at a time. This is expected to be used with udev.
* Default to --auto=yesNeil Brown2006-12-141-0/+1
| | | | | so the array devices with 'standard' names get created automatically, as this is almost always what is wanted.
* Strdup the bitmap file name found in the config fileNeil Brown2006-11-091-1/+1
| | | | Otherwise we quickly lose it...
* Allow a number after --auto=yesNeil Brown2006-10-131-0/+2
| | | | | | So if the device name is /dev/md/d0, then the number of partitions is as given. This is useful in 'CREATE' in mdadm.conf
* Allow symlink creation to be disabled from command line or mdadm.confNeil Brown2006-08-111-2/+6
|
* More consistent honoring of --configfileNeil Brown2006-06-261-15/+21
| | | | | Never use /etc/mdadm.conf if --config file is given (previously some code used one, some used the other).
* Stop map_dev from returning [0:0]Neil Brown2006-06-201-1/+2
| | | | | We sometimes need the NULL when major==minor==0. So make sure all callers of map_dev can cope with NULL.
* Allow default metadata to be specified in mdadm.confNeil Brown2006-06-021-0/+10
| | | | | | | CREATE metadata=1 in mdadm.conf will cause version-1 superblocks to be the default. Signed-off-by: Neil Brown <neilb@suse.de>
* Improve compiling for static binaries.Neil Brown2006-05-291-4/+0
| | | | | | | | | Have "#ifdef STATIC" in config.c, and the 'rmconf' target was a mess. Instead, create 'pwgr.c' with stub routines for those unavailable when statically compiled, and include that in STATICOBJ Signed-off-by: Neil Brown <neilb@suse.de>
* Initial implementation of auto-assemblyNeil Brown2006-05-261-0/+2
| | | | | | This basically works, but needs various improvements and some tests. Signed-off-by: Neil Brown <neilb@suse.de>
* Allow homehost to be set on command line or in config fileNeil Brown2006-05-191-0/+23
| | | | Signed-off-by: Neil Brown <neilb@suse.de>
* Improve code for recognising config lines.Neil Brown2006-05-191-12/+19
| | | | | | No more magic numbers. Signed-off-by: Neil Brown <neilb@suse.de>
* Just updaqte copyright dates and email addressNeil Brown2006-05-191-1/+1
| | | | Signed-off-by: Neil Brown <neilb@suse.de>
* Arrange the 'auto' setting in mdadm.conf can choose default type.Neil Brown2006-05-161-12/+17
| | | | | | | | | | | | 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>
* Allow default creation info to to be stored in mdadm.confNeil Brown2006-05-151-27/+121
| | | | | | Default owner, group, mode and 'auto' flag can be given in a 'CREATE' line. Signed-off-by: Neil Brown <neilb@suse.de>
* Assume "DEVICE partitions" if no DEVICE line present.Neil Brown2006-05-151-1/+5
| | | | | | | This means the output of "mdadm -Es" can be used as a complete mdadm.conf file .... if you really want to do that. Signed-off-by: Neil Brown <neilb@suse.de>
* Support 'mailfrom' line in mdadm.conf so the From: line in alert emails can ↵Neil Brown2006-05-151-1/+27
| | | | | | be explicitly set. Signed-off-by: Neil Brown <neilb@suse.de>
* Use O_DIRECT to read bitmap files.Neil Brown2006-05-151-1/+1
| | | | | | | | A pending patch to the kernel causes bitmap file updates to not go through the page cache, so O_DIRECT is needed to ensure that we read current data. Signed-off-by: Neil Brown <neilb@suse.de>
* Support 'bitmap=' in mdadm.conf for auto-assembling arrays with write-intent ↵Neil Brown2006-03-291-0/+8
| | | | | | bitmaps in separate files. Signed-off-by: Neil Brown <neilb@suse.de>
* Create missing /dev files where needed.Neil Brown2006-03-281-5/+1
| | | | | | | 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>
* Allow /etc/mdadm/mdadm.conf as an alternate to /etc/mdadm.confNeil Brown2005-12-091-1/+17
| | | | | | This provide compatability with Debian. Signed-off-by: Neil Brown <neilb@suse.de>
* Allow scanning of devices listed in /proc/partitions independant of /devNeil Brown2005-12-051-7/+10
| | | | | | | If a device found in /proc/partitions isn't listed in /dev, then mknod a temporary name and open that. Signed-off-by: Neil Brown <neilb@suse.de>
* Support nameing of version-1 arrays.Neil Brown2005-08-091-1/+11
| | | | | | | --name is recognised in --create and --assemble name= is recognised in config file. Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au>
* Assorted Fixes for multiple bugs.Neil Brown2005-08-041-1/+3
| | | | | | | Assemble would crash, or just not work. A few other problem found by a new test-suite. Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au>
* Allow --auto to still be meaningful when --scan is givenNeil Brown2005-06-141-1/+1
| | | | Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au>
* Initialise mis.next to NULLNeil Brown2005-06-141-0/+1
| | | | | | Probably not needed, but safer. Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au>
* super1Neil Brown2005-05-031-6/+4
| | | | | | | Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au> Fix raid5 creation with new code. Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au>
* Add a 'super-switch' so that different format superblocks can be used.Neil Brown2005-05-031-0/+11
| | | | | | | | This includes: adding --metadata= option to choose metadata format adding metadata= word to config file. Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au>
* Fix "--config=partitions" which was broken.Neil Brown2005-04-041-1/+5
| | | | | | "devline" wants a list of words, not a whole line... Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au>
* Reread partitions file for each array being assembled.Neil Brown2005-04-041-14/+17
| | | | | This makes assembling arrays from other arrays work better. Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au>
* mdadm-1.7.0mdadm-1.7.0Neil Brown2004-08-111-1/+1
|
* mdadm-1.6.0mdadm-1.6.0Neil Brown2004-06-041-1/+33
|
* mdadm-1.5.0mdadm-1.5.0Neil Brown2004-01-221-8/+11
|
* mdadm-1.4.0mdadm-1.4.0Neil Brown2003-10-281-2/+6
|
* mdadm-1.1.0mdadm-1.1.0Neil Brown2003-03-021-0/+5
|
* mdadm-1.0.9mdadm-1.0.9Neil Brown2003-02-121-0/+34
|
* mdadm-0.8.2mdadm-0.8.2Neil Brown2002-04-111-0/+4
|
* mdadm-0.8mdadm-0.8Neil Brown2002-04-041-12/+61
|
* mdadm-0.7.2mdadm-0.7.2Neil Brown2002-03-201-1/+4
|
* mdadm-0.7mdadm-0.7Neil Brown2002-03-081-3/+3
|
* mdctl-0.6mdctl-0.6Neil Brown2002-03-061-1/+9
|
* mdctl-0.5mdctl-0.5Neil Brown2001-08-231-182/+241
|
* mdctl-v0.4.2mdctl-v0.4.2Neil Brown2001-07-261-2/+4
|
* mdctl-v0.4mdctl-v0.4Neil Brown2001-07-261-3/+286
|
* mdctl-v0.2mdctl-v0.2Neil Brown2001-06-081-0/+54