GOT RID OF "modprobe: FATAL: Could not load /lib/modules/2.6.28-11-generic/modules.dep" error!!! (i will post how i did it and explanation below)
i followed instructions at http://ubuntuforums.org/showthread.php?t=148710&page=2 post #19 by El Marcel to unpack the initrd image file at /boot/initrd.img-2.6.28-11-generic (initrd.img-2.6.28-11-generic is specific to my filesystem, the equivalent for your system is the command
Code:
/boot/initrd.img-`uname -r`
)
`uname -r` spawns a subshell and runs the command which returns the kernel version that you are working with, and replaces `uname -r` with the kernel version returned by the command
ok, on to instructions! im gonna make em as easy to understand as i can because i had a ton of googling to do with this subject and it was murder piecing it all together! do the following code in any directory unless otherwise specified, also if you are denied access, try running the command with sudo (the copy commands need sudo):
1.
Code:
cp /boot/initrd.img-`uname -r` /boot/initrd.img-`uname -r`.bak
This will make a backup of your initrd.img file in the same directory in case something goes wrong.
2.
Code:
mv /boot/initrd.img-`uname -r` /tmp/initrd.old.gz
This will move your initrd image into /tmp/initrd.old.gz
/tmp is a directory which is removed every log out or restart i believe. i restarted and my old files werent there anymore so this i assume
initrd.img is a g zip archive of a cpio archive (i know what a g zip archive is but not a cpio archive)
3.
Code:
gzip -dc /tmp/initrd.old.gz >/tmp/initrd.old.img
this will unpack the initrd image so its just a cpio archive
4.
Code:
mkdir /tmp/initrd-image
makes a directory under /tmp called initrd-image
5.
Code:
cd /tmp/initrd-image
change directory into the initrd-image directory inside /tmp
6.
Code:
cpio -i < /tmp/initrd.old.img
unpack the cpio archive into the initrd-image directory you should be in
7.
Code:
cp /lib/modules/`uname -r`/modules.dep /tmp/initrd-image/lib/modules/`uname -r`/modules.dep
this copies your existing modules.dep file that is in /lib/modules/`uname -r` into the image file you are about to repackage
8.
Code:
find . | cpio -H newc -o > /tmp/initrd.new.img
repackages the directories and files in the current directory you should be in (/tmp/initrd-image) into /tmp/initrd.new.img
9.
Code:
gzip -c /tmp/initrd.new.img >/tmp/initrd.new.gz
repackage the cpio archive as a g zip archive
10.
Code:
cp /tmp/initrd.new.gz /boot/initrd.img-`uname -r`
this will copy your new initrd image into the spot your old one used to be and the same directory the old one should be in
11. Reboot, and hopefully the ugly error is gone, but if any errors occur and you cant boot, then pop in your ubuntu cd, boot into live cd mode and mount the filesystem so you can remove the /boot/initrd.img-`uname -r` and remove the .bak extension from /boot/initrd.img-`uname -r`.bak and then reboot into your old initrd
unfortunately this doesnt fix the problem i was hoping it would, fixing my problem where i can suspend successfully once and then when i resume gnome-power-manager tells me that its "Unable to get data..." and i cant suspend again, but hey! i fixed one error progress not perfection. and i had fun nerding out and figuring it out anyways im linking to this on some other threads i ran across, proofreading and constructive feedback are welcome hopefully this helps another out in the future!
now... time to work on the softresets failed and my gnome-power-manager error... *runs to google*
Bookmarks