LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 08-17-2004, 11:50 AM   #1
denniz
Member
 
Registered: Apr 2004
Location: amsterdam
Distribution: Debian (Sarge and Woody)
Posts: 49

Rep: Reputation: 15
Problem when converting to RAID!!! STUCK!


Hello,

I'm trying to get my system RAID1. I'm following the Root Raid Doc How-TO for this. All the steps seem to go nicely until step 4.4 Edit /etc/fstab so that you mount your new RAID partition on boot up. I've added the suggested line in /etc/fstab and rebooted. However, when I run mount it does NOT give a line showing /dev/md0 is mounted on /mnt/md0. What gives?
 
Old 08-17-2004, 11:57 AM   #2
LinuxLala
Senior Member
 
Registered: Aug 2003
Location: New Delhi, India
Distribution: Fedora 7
Posts: 1,305

Rep: Reputation: 45
I am sure you must have done this but does
mount /dev/md0 /mnt/md0
give any errors?

If you indeed have the directory /mnt/md0 then after the mount command do
cd /mnt/md0

What happens then?
 
Old 08-18-2004, 07:34 AM   #3
denniz
Member
 
Registered: Apr 2004
Location: amsterdam
Distribution: Debian (Sarge and Woody)
Posts: 49

Original Poster
Rep: Reputation: 15
LinuxLala, this is interesting:

I fired her up again, issued mount. md0 was not there in the list. Here's the list:
/dev/hda1 on / type ext3 (rw,errors=remount-ro)
proc on /proc type proc (rw)
sysfs on /sys type sysfs (rw)
devpts on /dev/pts type devpts (rw, gid=5, mode=620)
tmpfs on /dev/shm type tmpfs (rw)
usbfs on /proc/bus/usb type usbfs (rw)
(perhaps anything unusual in here?)


I can succesfully cd /mnt/md0
If I do ls in here, there are no files.


When I did mount /dev/md0 /mnt/md0 yesterday, it gave nothing so I figured it worked.
When I do the same just now (but it's already mounted right?) it says:
/dev/md0: Invalid argument
mount: you must specify the filesystem type

I don't get it...
 
Old 08-18-2004, 10:04 AM   #4
LinuxLala
Senior Member
 
Registered: Aug 2003
Location: New Delhi, India
Distribution: Fedora 7
Posts: 1,305

Rep: Reputation: 45
Well, after each restart or whatever you need to issue the mount command again. A simple cd would never show the contents as it does not mount. If you do mount /dev/md0 /mnt/md0 and then cd /mnt/md0 and ls I am sure all will be fine.

If it is fine, you can add a line in your fstab file. Get back if it does or does not work
 
Old 08-18-2004, 04:39 PM   #5
denniz
Member
 
Registered: Apr 2004
Location: amsterdam
Distribution: Debian (Sarge and Woody)
Posts: 49

Original Poster
Rep: Reputation: 15
Thanks for replying again LinuxLala. When I reboot, and do mount /dev/md0 /mnt/md0 it says this:
Code:
/dev/md0: invalid argument
mount: you must specify the filesystem type
Now that can't be right, right? It didn't say that before the reboot.
 
Old 08-19-2004, 01:58 AM   #6
denniz
Member
 
Registered: Apr 2004
Location: amsterdam
Distribution: Debian (Sarge and Woody)
Posts: 49

Original Poster
Rep: Reputation: 15
When I go back a few steps in the How-To (after undoing some (stopping md0, zero the superblock)) and redo those (reset partition type to fd (linux raid auto), create raid device and format it (ext3)), it seems to go fine. Mounting it and copying hda to it all go fine (or so it seems, judging from all the harddisk activity). I've added a line to fstab to mount md0 at startup and reboot.

The same thing happens after reboot. Mount doesn't show md0 mounted. When I do mount, it says same as in previous post (invalid argument, must specify filytype) but it didn't say that when I mounted it before reboot.

I'm stuck now. Did I declare something wrong? Partitioned it incorrectly? Something else????
 
Old 08-19-2004, 01:59 AM   #7
LinuxLala
Senior Member
 
Registered: Aug 2003
Location: New Delhi, India
Distribution: Fedora 7
Posts: 1,305

Rep: Reputation: 45
This is wierd. Now we are sure that the device is actually /dev/md0 'coz you successfully mounted it the other day. And we also know that you have created a directory named mdo under /mnt.

So I am as perplexed as you are. How about trying the following command
mount /dev/md0 /mnt/floppy

What error message do you get now, if any?
 
Old 08-20-2004, 11:00 AM   #8
denniz
Member
 
Registered: Apr 2004
Location: amsterdam
Distribution: Debian (Sarge and Woody)
Posts: 49

Original Poster
Rep: Reputation: 15
Hi LinuxLala. Sorry for the slow reply. Had a really busy day+evening...

This is strange. I boot the machine, then do mount /dev/md0 and it says this:
EXT3-fs: unable to read superblock
mount: wrong fs type, bad option, bad superblock on /dev/md0, or too many mounted file systems (could this be the IDE device where you in fact use ide-scsi so that sr0 or sda or so is needed?)


If I do mount /dev/md0 /mnt/floppy it says:
/dev/md0: invalid argument
mount: you must specify the filesystem type
In other words, the same error as trying to mount it to /mnt/md0!
The bad superblock has got something to do with it perhaps?
 
Old 08-21-2004, 01:21 AM   #9
LinuxLala
Senior Member
 
Registered: Aug 2003
Location: New Delhi, India
Distribution: Fedora 7
Posts: 1,305

Rep: Reputation: 45
This sounds silly. I'll ask at my LUG about this too and then I'll get back, but I believe somethings gone bad during setup. I am sorry to say this but I think you should try this again from scratch.
 
Old 08-21-2004, 02:59 AM   #10
denniz
Member
 
Registered: Apr 2004
Location: amsterdam
Distribution: Debian (Sarge and Woody)
Posts: 49

Original Poster
Rep: Reputation: 15
Right, well I think I'm going to try to redo the whole procedure then: stopping the md0, and start from repartitioning the device (hdc)... If you could ask your LUG (what is LUG?) and get back, that'd be great. Thanks
 
Old 08-21-2004, 06:47 AM   #11
LinuxLala
Senior Member
 
Registered: Aug 2003
Location: New Delhi, India
Distribution: Fedora 7
Posts: 1,305

Rep: Reputation: 45
LUG == Linux Users Group

All cities have their own LUG. Check out the Linux Users Group forum here at LQ so that you can find a LUG in your city. If you can't find one, make a post titled Any LUG in Amsterdam or whatever.

I'll ask and get back. Sorry to have you waiting.
 
Old 08-23-2004, 02:21 PM   #12
denniz
Member
 
Registered: Apr 2004
Location: amsterdam
Distribution: Debian (Sarge and Woody)
Posts: 49

Original Poster
Rep: Reputation: 15
Thanx for explaining LinuxLala.
Well, the waiting is not so bad as I am heading to Belgium for a seminar and won't return until sunday. When I return I will check the forum here ofcourse

AND I will retry the whole routine. From scratch. See if that gives any different results.
Speak to you soon.
 
Old 08-23-2004, 05:10 PM   #13
LinuxLala
Senior Member
 
Registered: Aug 2003
Location: New Delhi, India
Distribution: Fedora 7
Posts: 1,305

Rep: Reputation: 45
Have fun. I am sure something will come up by then.

Cheers.
 
Old 09-05-2004, 03:13 PM   #14
denniz
Member
 
Registered: Apr 2004
Location: amsterdam
Distribution: Debian (Sarge and Woody)
Posts: 49

Original Poster
Rep: Reputation: 15
back! Linuxlala, I have tried it again from scratch... Steps 1-9 worked ok, but I listed them so you can see what I have done exactly. It went wrong at 10... This time I have zero-ed the superblock before creating the raid md0. In the appendix XII of the how-to recommends doing this always before creating a raid (no word of this in the step-by-step how-to (before 3.3)). Let's see if this makes a difference... So here's what I've been doing:


1. cat /proc/mdstat shows that raid is built into my kernel (its got different raid personalities)
2. I copied the partitions from hda to hdc: sfdisk -d /dev/hda | sfdisk /dev/hdc
3. Using cfdisk /dev/hdc I changed the partition type to Linux Raid autodetect.
4. Rebooted and rechecked partition type (ok).
5. before creating the raid device, I zero-ed the superblock: mdadm --zero-superblock /dev/hdc1
6. Created the raid device: mdadm --create /dev/md0 --level=1 --raid-disks=2 missing /dev/hdc1
7. Formatted the raid device. It autodetected it as ext2, but I want it ext3, so: mkfs.ext3 /dev/md0
8. Created a mount point: mkdir /mnt/md0
9. Mounted the raid device: mount /dev/md0 /mnt/md0

So far so good, it mounts! Hurrah!
cat /proc/mounts lists a line "/dev/md0 /mnt/md0 ext3 rw 0 0"

10. Now, before copying all the data, I added "/dev/md0 /mnt/md0 ext3 rw 0 0" to fstab. To check if md0 gets mounted after reboot.

This is where things go wrong:
when I reboot it does NOT mount! In /var/log/dmesg I find a (disturbing) line "EXT3-fs: unable to read superblock". This I do not understand. When I formatted md0 to ext3 (see step 5), it wrote all superblocks nicely and started the fs without problems. Now cat /proc/mdstat doesn't show any md0 devices running.

And we're back at the point of all the errors mentioned above. Any idea what could be wrong?

cheers,
denniz
 
Old 09-08-2004, 08:59 AM   #15
denniz
Member
 
Registered: Apr 2004
Location: amsterdam
Distribution: Debian (Sarge and Woody)
Posts: 49

Original Poster
Rep: Reputation: 15
Anyone who has any idea/suggestion/direction/solution?
I'm really stuck now and can't continue configuring my server....
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
username problem converting from NT mstouffel Linux - General 1 11-29-2005 04:20 PM
Raid Problem Fedora Core 3, RAID LOST DISKS ALWAYS icatalan Linux - Hardware 1 09-17-2005 03:14 AM
Converting an ordinary partition to RAID 1 or RAID 5? krishvij Linux - Newbie 1 03-20-2005 09:39 PM
stuck in a problem kickidiot Linux - Software 2 10-03-2004 05:53 PM
Converting Software to Hardware RAID LuCiDoLoGiSt Linux - Software 12 07-16-2004 07:02 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 03:34 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration