guidelines to program a module
Hi guys!
I'm stuck in a problem with a raid. I want to start a software raid from IMAGES of disks, not the actual disks. I setup the raidtab with the files that are the images of the HDs, but when I start the raid device, it complains because it can't lock the devices: From dmesg: Code:
md: could not lock [dev 00:00], zero-size? Marking faulty. So.... my crack-inspired brain (just kidding ;)) thinks it's because they are not actual block devices... but normal mortal files. So... I wonder how difficult it would be to program a module so they looked like block devices under /dev/ I don't intend to program anything "stable", so to speak. I just want to READ the data contained in the raid that was made by those four images so I can restore the data in them. That's it. I'm willing to program it myself... but I don't want to start learning from scratch how to deal with a module... but get a guide instead (if there's one available) that could ease the process. |
I don't need to write a module that does that anymore. losetup can make loop devices from files. ;) Couldn't you just have said that?
Anyway... in case you want to program a module someday, take a look at the linux kernel module programming guide at www.tldp.org It's very hands-on and easily "digestible"... from what I read just yesterday! |
|
All times are GMT -5. The time now is 03:54 AM. |