Linux - GeneralThis 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
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I am working on a consulting project, to add raid to an existing embeded system.
The system is sarge based, but running a backported kernel from lenny...
The reason is the code was written for sarge, but the latest hardware build uses SATA drives for both hd and cd.
They have a nice build, with a cool backup/bootable restore environment... My job is to add raid.
I successfully moved everything to a raid drive, and got the non-raid grub booting the raid array. When I moved the original drive to raid, that all went well... untill I rebooted... Grub sould start, but not find itself. So I booted a lenny cd in recovery mode, and fixed grub so it worked fine. So in recovery mode I had all drives working, and /boot looked good.
Upon reboot, grub runs fine, /root mounts and boots fine, but now /boot and the rest of the other filesystems will not mount.
I know /boot is good, because it will boot all day long. but I get a error "wrong fs type, bad option, bad superblock, on /dev/md0" when I try to mount it.
I have tried all sorts of fixes, but short of re-making the filesystem, I'm not getting anywhere. Has anyone seen this?
Actually this IS a software raid... The clue there is the /dev/md0 device. Hardware raid is usually /dev/sda (a psudo-scsi device).
In any event I managed to find a tool to fix my problem. The command mdrun would bypass all of the problems and connect the drives so they could be mounted.
I think the source of my problem is that the newer kernel I was running was not providing the same API that the older tools were expecting.
mdrun was supposed to run if the /etc/mdadm/mdadm.conf file was empty or missing, but I tried emptying and deleting it with no lucj, so I just put the command in the md startup scripts in three different places to make sure it ran... I tested it, and it does nothing if run more than once... I'll go back and clean that up later...
The next step is to make a script to create a new system from tarballs of the old system.
The previous engineers used mkcdrec as source material for their backup system... They have an hd2cd.sh script that makes tarballs of the filesystems, then it builds a bootable cd image, and burns it to cdr or cdrw media, or makes the iso available for download. The bootable cd has a cd2hd.sh that will install the complete system... Very sweet! So my next step is to re-write cd2hd.sh to build the raid array. I'm half way done with that, I just have to add the filesystem support to the bootable image.
I already have a simple script to rebuild the array after a drive failure...
After I'm all done I must write up instructions and integrate the instructions with the system so that they are on-hand for every step of the process, so that the tech has in-context guides as he does his field work. This project will be installed in unmanned field stations all over the country.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.