Linux - HardwareThis forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?
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'm beginning to think I'm having some disk hardware problems. I was having sporadic problems with the /var directory, (hardware locatlon /dev/hda5). I ran fsck on it, and had a huge number of disconnected inodes. It seemed to have cleaned them up, and put them in /lost+found, but now, when I do an ls on lost+found, sometimes there are files there, and sometimes, there aren't.
Are there any disk utilities that come with RH 8.0 that I can use for running some hardware diagnostics on /dev/hda5?
I manually ran badblocks from root on the / filesystem, physical drive /dev/hda3.
It came up with three bad blocks.
How do I get fsck to recognize these, move whatever is on these blocks somewhere else, and make sure the file system doesn't try and use these blocks any more?
I ran shutdown -rF, and it ran fsck on all the drives at boot time without any problem. I want to try and force fsck to do a full badblock check on all the partitions, and fix whatever's underneath, ideally at reboot time, when nothings mounted.
I dug around in the docs, and found the following possible command, and was wondering if this would do the trick:
e2fsck -cypf /dev/hda3
I _think_ this should:
c - run badblocks
y - say yes to all questions
p - preen/repair the filesystem
f - force checking
Now, my only problem is how to unmount the root directory. It seems that when the system is running, there are several programs that have open files, which makes it impossible to unmount "/".
My questions are:
Is the above command correct to do what I want to do (identify badblocks, fix the file system, mark the blocks as unusable)?
How do I get the system in a state where I can safely execute that command?
I can't help you with the first question, but to answer your second question, you need to boot your computer in rescue mode. This explains how you do that:
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.