Solved

RH7.1 raidhotadd doesn't work...

Posted on 2001-08-16
5
606 Views
Last Modified: 2013-12-15
I am having difficulty resynchronizing disks after booting the system without one disk(sdb)... Looks like the mirror broke when I booted.

I set up RAID 1 with two SCSI disks(sda & sdb) and this is the strucutre:
-----------------------------------------------------
df

Filesystem           1k-blocks      Used Available Use% Mounted on
/dev/md0               4032000    933016   2894164  25% /
/dev/md1              60475924    107636  57296268   1% /home
/dev/md3               3510208       368   3331528   1% /tmp
/dev/md2               2015952     20584   1892960   2% /var

But when I do "raidhotadd", I get an error message:

raidhotadd /dev/md0 /dev/sdb1
/dev/md0: can not hot-add disk: invalid argument.

After this, if I do not specify the second drive, it doesn't get any error, but it doesn't do the job either.

raidhotadd /dev/md0 /dev/sdb
---------------------------------------------------------
cat /proc/mdstat
Personalities : [raid1]
read_ahead 1024 sectors
md0 : active raid1 sdb[2] sda1[1]
      4096448 blocks [2/1] [_U]
      [=>...................]  recovery =  6.5% (267620/4096448) finish=5.7min speed=11150K/sec
md1 : active raid1 sda5[1]
      61440448 blocks [2/1] [_U]

md3 : active raid1 sda6[1]
      3566272 blocks [2/1] [_U]

md2 : active raid1 sda7[1]
      2048192 blocks [2/1] [_U]

unused devices: <none>
--------------------------------------------------

After this, if I do this I get error message:

raidhotadd /dev/md1 /dev/sdb
/dev/md1: can not hot-add disk: invalid argument.

Can anyone help? Thanks.


Some important information:
-----------------------------------------------------
dmesg -c

trying to hot-add sdb1 to md0 ...
md: could not lock sdb1, zero-size? Marking faulty.
md: error, md_import_device() returned -22
trying to hot-add sdb5 to md1 ...
md: could not lock sdb5, zero-size? Marking faulty.
md: error, md_import_device() returned -22
trying to hot-add sdb5 to md2 ...
md: could not lock sdb5, zero-size? Marking faulty.
md: error, md_import_device() returned -22
trying to hot-add sdb6 to md3 ...
md: could not lock sdb6, zero-size? Marking faulty.
md: error, md_import_device() returned -22
trying to hot-add sdb1 to md0 ...
md: could not lock sdb1, zero-size? Marking faulty.
md: error, md_import_device() returned -22
-------------------------------------------------------
cat /proc/mdstat

Personalities : [raid1]
read_ahead 1024 sectors
md0 : active raid1 sda1[1]
      4096448 blocks [2/1] [_U]

md1 : active raid1 sda5[1]
      61440448 blocks [2/1] [_U]

md3 : active raid1 sda6[1]
      3566272 blocks [2/1] [_U]

md2 : active raid1 sda7[1]
      2048192 blocks [2/1] [_U]

unused devices: <none>
-------------------------------------------------------
df

Filesystem           1k-blocks      Used Available Use% Mounted on
/dev/md0               4032000    933016   2894164  25% /
/dev/md1              60475924    107636  57296268   1% /home
/dev/md3               3510208       368   3331528   1% /tmp
/dev/md2               2015952     20552   1892992   2% /var

-----------------------------------------------------
cat /etc/raidtab

raiddev             /dev/md0
raid-level                  1
nr-raid-disks               2
chunk-size                  64k
persistent-superblock       1
#nr-spare-disks     0
    device          /dev/sda1
    raid-disk     0
    device          /dev/sdb1
    raid-disk     1
raiddev             /dev/md1
raid-level                  1
nr-raid-disks               2
chunk-size                  64k
persistent-superblock       1
#nr-spare-disks     0
    device          /dev/sda5
    raid-disk     0
    device          /dev/sdb5
    raid-disk     1
raiddev             /dev/md2
raid-level                  1
nr-raid-disks               2
chunk-size                  64k
persistent-superblock       1
#nr-spare-disks     0
    device          /dev/sda7
    raid-disk     0
    device          /dev/sdb7
    raid-disk     1
raiddev             /dev/md3
raid-level                  1
nr-raid-disks               2
chunk-size                  64k
persistent-superblock       1
#nr-spare-disks     0
    device          /dev/sda6
    raid-disk     0
    device          /dev/sdb6
    raid-disk     1
0
Comment
Question by:yjh123
  • 3
5 Comments
 
LVL 3

Expert Comment

by:iharding
Comment Utility
post "fdisk -l /dev/????" for all disks
0
 
LVL 17

Expert Comment

by:psimation
Comment Utility
As far as I know, you must have either raid5 or raid10 setup in order to use hot swapping. raid 1 is normal mirroring...
0
 
LVL 1

Expert Comment

by:Moondancer
Comment Utility
yjh123--->  You have TEN open questions, I will update them all with these comments.  Please check the Guidelines and Member Agreement available from the HELP DESK link on the left about the rules for this site.  I will monitor them all for updates and closures.

If you need help from Community Support, let us know.  If no response by the end of next week, I will handle them all and advise Administration.

Your cooperation and understanding is not only appreciated, but necessary.

Moondancer
Community Support Moderator @ Experts Exchange
0
 
LVL 1

Expert Comment

by:Moondancer
Comment Utility
yjh123 logged in after this request was posted but chose not to update or finalize it, so I ask for your input as to the fair way to conclude and close this (award/PAQ or Delete).

Thanks,

Moondancer
Community Support Moderator @ Experts Exchange
0
 
LVL 1

Accepted Solution

by:
Moondancer earned 0 total points
Comment Utility
300 points refunded, question closed.  No response to my requests.
Moondancer - EE Moderator
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

How many times have you wanted to quickly do the same thing to a list but found yourself typing it again and again? I first figured out a small time saver with the up arrow to recall the last command but that can only get you so far if you have a bi…
Linux users are sometimes dumbfounded by the severe lack of documentation on a topic. Sometimes, the documentation is copious, but other times, you end up with some obscure "it varies depending on your distribution" over and over when searching for …
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now