diff options
author | Neil Brown <neilb@suse.de> | 2006-12-14 17:31:10 +1100 |
---|---|---|
committer | Neil Brown <neilb@suse.de> | 2006-12-14 17:31:10 +1100 |
commit | 757234466509aae6221c2cb96e8366f41ba7e532 (patch) | |
tree | c6bebe56053849971f8f2b7fad638bbc125d50a8 /mdopen.c | |
parent | d645b91a1baf44e4674900f1124841fe6c0a2410 (diff) | |
download | mdadm-757234466509aae6221c2cb96e8366f41ba7e532.tar.gz mdadm-757234466509aae6221c2cb96e8366f41ba7e532.tar.xz mdadm-757234466509aae6221c2cb96e8366f41ba7e532.zip |
Default to --auto=yes
so the array devices with 'standard' names
get created automatically, as this is almost always what is wanted.
Diffstat (limited to 'mdopen.c')
-rw-r--r-- | mdopen.c | 14 |
1 files changed, 7 insertions, 7 deletions
@@ -135,10 +135,6 @@ int open_mddev(char *dev, int autof) dev); return -1; } - if (autof == 2 && stb.st_mode == 0 && !is_standard(dev, NULL)) { - fprintf(stderr, Name ": --auto=yes requires a 'standard' md device name, not %s\n", dev); - return -1; - } /* check major number is correct */ num = -1; std = is_standard(dev, &num); @@ -146,19 +142,23 @@ int open_mddev(char *dev, int autof) switch(autof) { case 2: /* only create is_standard names */ if (!std && !stb.st_mode) { - fprintf(stderr, Name ": --auto=yes requires a 'standard' md device name, not %s\n", dev); + fprintf(stderr, Name + ": %s does not exist and is not a 'standard' name " + "so it cannot be created\n", dev); return -1; } break; case 3: /* create md, reject std>0 */ if (std > 0) { - fprintf(stderr, Name ": that --auto option not compatable with device named %s\n", dev); + fprintf(stderr, Name ": that --auto option " + "not compatable with device named %s\n", dev); return -1; } break; case 4: /* create mdp, reject std<0 */ if (std < 0) { - fprintf(stderr, Name ": that --auto option not compatable with device named %s\n", dev); + fprintf(stderr, Name ": that --auto option " + "not compatable with device named %s\n", dev); return -1; } break; |