Lost mdadm.conf
>I've collected an howto somewhere from the 'net:
> >$ cat docs/sysadm/mdadm_recovery.txt > >## define possible devices with arrays >echo 'DEVICE /dev/hd[a-l]* /dev/sd[a-l]*' > mdadm.conf > >## scan >mdadm --examine --scan --config=mdadm.conf >> mdadm.conf > >## review configuration, copy to /etc >cp mdadm.conf /etc/ > >## create devices >MAKEDEV md || { for ((i=0; i <= 31; i++)); do mknod /dev/md$i b 9 $i; done; } > >## start arrays >mdadm --assemble --scan That's a fairly limited script and out of date, I've never used mknod... Simply: # mdadm --detail --scan --verbose And look it over, then: # mdadm --detail --scan --verbose > /etc/mdadm.conf And worry about mountpoints etc now... _______________________________________________ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos |
Lost mdadm.conf
Hi,
it worked (kind of). Thanks. I was able to recreate (the all appear in /proc/mdstat) and in the rescue I've mounted the /boot which maps to /dev/md0. But I can't mount any other partition. they all complain with the same error mount: Mounting /dev/mdX on /tmp/mountpoint failed: no such file or directory Any ideas? On Thu, Dec 31, 2009 at 11:42 AM, Luciano Rocha <strange@nsk.no-ip.org> wrote: On Thu, Dec 31, 2009 at 11:39:25AM -0400, robert mena wrote: > Hi, > > I lost my mdadm.conf (and /proc/mdadm shows nothing useful) and I'd like to > mount the filesystem again. *So I've booted using rescue but I was wondering > if I can do a command like this safely (i.e without losing the data > previously stored). > > mdadm -C /dev/md0 --level=raid0 --raid-devices=2 /dev/sda1 /dev/sdb1 > > Where of course the raid devices and the /dev/x are the correct ones I've collected an howto somewhere from the 'net: $ cat docs/sysadm/mdadm_recovery.txt ## define possible devices with arrays echo 'DEVICE /dev/hd[a-l]* /dev/sd[a-l]*' > mdadm.conf ## scan mdadm --examine --scan --config=mdadm.conf >> mdadm.conf ## review configuration, copy to /etc cp mdadm.conf /etc/ ## create devices MAKEDEV md || { for ((i=0; i <= 31; i++)); do mknod /dev/md$i b 9 $i; done; } ## start arrays mdadm --assemble --scan Best of luck, -- lfr 0/0 _______________________________________________ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos _______________________________________________ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos |
Lost mdadm.conf
2009/12/31 Luciano Rocha <strange@nsk.no-ip.org>:
> On Thu, Dec 31, 2009 at 11:39:25AM -0400, robert mena wrote: >> Hi, >> >> I lost my mdadm.conf (and /proc/mdadm shows nothing useful) and I'd like to >> mount the filesystem again. *So I've booted using rescue but I was wondering >> if I can do a command like this safely (i.e without losing the data >> previously stored). >> >> mdadm -C /dev/md0 --level=raid0 --raid-devices=2 /dev/sda1 /dev/sdb1 >> >> Where of course the raid devices and the /dev/x are the correct ones > I can't say this with 100% certainty but I would of thought that it would been fine. I've lost my mdadm.conf (reinstalled OS) with a separate 4 disk RAID 5 array and re-assembled the array and carried on as if nothing had happened. Use "sudo mdadm -E --scan" do get a list of discovered RAID devices like this example: ARRAY /dev/md0 level=raid0 num-devices=2 UUID=fde94900:3f3f3bf6 Pop the results in your mdadm.conf and that should sort you out after a reboot (I think). Also try something like "sudo mdadm --assemble /dev/md1 /dev/sdb1 /dev/sdc1" to assemble the RAID manually. -- Regards, James ;) Pablo Picasso - "Computers are useless. They can only give you answers." - http://www.brainyquote.com/quotes/authors/p/pablo_picasso.html _______________________________________________ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos |
Lost mdadm.conf
Now you've got your array working give us a fuller picture, how many
hard drives have you got, in what configuration, how many arrays, how many partitions, what file systems, output of "mount" command, fstab details etc etc -- Regards, James ;) Jonathan Swift - "May you live every day of your life." - http://www.brainyquote.com/quotes/authors/j/jonathan_swift.html _______________________________________________ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos |
Lost mdadm.conf
On Thu, Dec 31, 2009 at 12:24:23PM -0400, robert mena wrote:
> Hi, > > it worked (kind of). Thanks. > > I was able to recreate (the all appear in /proc/mdstat) and in the rescue > I've mounted the /boot which maps to /dev/md0. But I can't mount any other > partition. > > they all complain with the same error > > mount: Mounting /dev/mdX on /tmp/mountpoint failed: no such file or > directory Silly question: does /dev/md0 and /tmp/mountpoint exist? -- lfr 0/0 _______________________________________________ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos |
Lost mdadm.conf
On Thu, Dec 31, 2009 at 04:23:52PM +0000, Joseph L. Casale wrote:
> > That's a fairly limited script and out of date, I've never used mknod... Not all rescue environments have MAKEDEV or have it in $PATH, so this should always work. ;) -- lfr 0/0 _______________________________________________ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos |
Lost mdadm.conf
Hi,
Yes. * I have from /devmd0 to /dev/md6 (for some reason it skipped md3). * I do not have the fstab at hand but */*/boot* and /tmp* each map to a different mdX. * I've been able to mount the /boot but no other. One thing, besides the /boot all the other are ext4. *Could it be a problem with the rescue does not supporting this filesystem type. On Thu, Dec 31, 2009 at 12:32 PM, Luciano Rocha <strange@nsk.no-ip.org> wrote: On Thu, Dec 31, 2009 at 12:24:23PM -0400, robert mena wrote: > Hi, > > it worked (kind of). Thanks. > > I was able to recreate (the all appear in /proc/mdstat) and in the rescue > I've mounted the /boot which maps to /dev/md0. But I can't mount any other > partition. > > they all complain with the same error > > mount: Mounting /dev/mdX on /tmp/mountpoint failed: no such file or > directory Silly question: does /dev/md0 and /tmp/mountpoint exist? -- lfr 0/0 _______________________________________________ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos _______________________________________________ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos |
Lost mdadm.conf
On Thu, Dec 31, 2009 at 12:38:51PM -0400, robert mena wrote:
> Hi, > > Yes. > > I have from /devmd0 to /dev/md6 (for some reason it skipped md3). > > I do not have the fstab at hand but > / > /boot > and /tmp > > each map to a different mdX. I've been able to mount the /boot but no > other. > > One thing, besides the /boot all the other are ext4. Could it be a problem > with the rescue does not supporting this filesystem type. Yes, it could. Can you send us the output of dmesg? -- lfr 0/0 _______________________________________________ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos |
Lost mdadm.conf
>Not all rescue environments have MAKEDEV or have it in $PATH, so this should always work. ;)
Really, on my hp's as well? I don't have any /dev/hdx or /dev/sdx on the ones with software raid... Nothing is easier than simply: # mdadm --detail --scan --verbose > /etc/mdadm.conf And that actually *does* work in all environments... _______________________________________________ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos |
Lost mdadm.conf
Dmesg shows (for example when I tried to mount /dev/md2)
*ext4-fs: md2 : not marked OK to use with test code On Thu, Dec 31, 2009 at 12:40 PM, Luciano Rocha <strange@nsk.no-ip.org> wrote: On Thu, Dec 31, 2009 at 12:38:51PM -0400, robert mena wrote: > Hi, > > Yes. > > I have from /devmd0 to /dev/md6 (for some reason it skipped md3). > > I do not have the fstab at hand but > / > /boot > and /tmp > > each map to a different mdX. * I've been able to mount the /boot but no > other. > > One thing, besides the /boot all the other are ext4. *Could it be a problem > with the rescue does not supporting this filesystem type. Yes, it could. Can you send us the output of dmesg? -- lfr 0/0 _______________________________________________ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos _______________________________________________ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos |
| All times are GMT. The time now is 10:05 AM. |
VBulletin, Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.