LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Hardware (https://www.linuxquestions.org/questions/linux-hardware-18/)
-   -   How to know if hard drive is dying? (https://www.linuxquestions.org/questions/linux-hardware-18/how-to-know-if-hard-drive-is-dying-641666/)

alan_ri 05-12-2008 11:05 AM

How to know if hard drive is dying?
 
I'm having very strange problems these days.I could not install 10 diffrenet Linux distros and the errors were everything just not the same.One of them was segmentation fault,then that root fs doesn't exist,then that it can't copy files to partition.The only one I was able to install was Backtrack,but apps just keep crashing and I can't mount any other partition,sometimes it doesn't make it to the login screen,it stops on different lines,like ACPI or eth1 etc.
Could all of this be just because hard drive is dying(because I think that's what's happening)or is more then that?
And I forgot something,on this drive I have XP(just because of my brother,I want to make that clear)and guess what,it's working better then ever.

GrapefruiTgirl 05-12-2008 11:15 AM

Golly, hard to say.. It does look like the problem is drive related at first glance, but.... What about bad memory, or a failing IDE controller? Even a failing power supply can lead to numerous (very weird seeming) problems.

What make & model is the drive, and more importantly, how much mileage is on it?
Same for the motherboard-- what is it, and how old is it? How old is the power supply?

If the drive is SMART enabled, perhaps running the SMART self diagnosis tests (the LONG test) on the drive will give you a better idea if the drive is having issues. Under Linux, the SMART command is 'smartctl', and it has a man page. It is part of 'smartmon_tools' or something similar. You will have no trouble locating the package if you don't have it, using Google. It is hosted on Sourceforge.

Good luck, do let us know if/what you learn, or where this leads.

Sasha

alan_ri 05-12-2008 11:30 AM

Thanks for the quick reply,Sasha.
I did a memory test,and it was ok.I have three slots,and pc came with 256 of RAM and I added 2x256 not so long ago,and I'm sure models are as they should be.The drive is serial ATA IDE and it's about 5 years old,same as motherboard which is VIA P4VT8.Power supply that came with original pc died two weeks ago,so one I'm having now is new.I will check your suggestions.Thanks again!

onebuck 05-12-2008 08:04 PM

Hi,

What was the original PSU size? What did you replace the original with?

alan_ri 05-13-2008 04:42 AM

Hi,onebuck,
The original was ATX 2.03(P4) model 300PA CODEGEN 300W,230V,12V and new one is ATX 1.3/ver.2.03 12V,230V,550W compliant for all kind of CPU and Mainboard.
Today when I booted into Backtrack it said that fs was corrupted and it tried to fix that,and eventually it did.So far things are working and I can mount other partitions,but one thing is strange,it's showing that my root partition is not mounted.Here's the output when I try to mount it;
Quote:

A security policy in place prevents this sender from sending this message to this recipient, see message bus configuration file (rejected message had interface "org.freedesktop.Hal.Device.Volume" member "Mount" error name "(unset)" destination "org.freedesktop.Hal")
I am root,so I need to check this.I have to give a credit to the people of Backtrack,because without it I don't know how would I be able to fix something.These are the distros that failed to install:
Debian Etch,Debian Lenny,Fedora 8,Ubuntu 8.04,sidux,Absolute Linux,PCLinuxOS 2007,Mandriva 2008.1,and I tried with Slackware 12,but I think that cd1 is corrupted,so it just failed to start,I need to check that too.

elliott678 05-13-2008 04:57 AM

Quote:

Originally Posted by GrapefruiTgirl (Post 3150898)
Golly, hard to say.. It does look like the problem is drive related at first glance, but.... What about bad memory, or a failing IDE controller? Even a failing power supply can lead to numerous (very weird seeming) problems.

Don't forget the possibility of a bad IDE cable, that one made me feel stupid.

onebuck 05-13-2008 10:23 AM

Hi,
Quote:

Originally Posted by alan_ri (Post 3151633)
Hi,onebuck,
The original was ATX 2.03(P4) model 300PA CODEGEN 300W,230V,12V and new one is ATX 1.3/ver.2.03 12V,230V,550W compliant for all kind of CPU and Mainboard.

I would check all the supply rails with the PSU loaded. If you have access to a DVM or voltmeter, just make certain all peripheral and system devices are connected at the time of measurement.

Quote:

Originally Posted by alan_ri (Post 3151633)
<snip> I tried with Slackware 12,but I think that cd1 is corrupted,so it just failed to start,I need to check that too.

You should check the md5sum for the downloaded iso file(s), be sure to get the '.md5' file for each iso. Don't depend on the burn application to check.

jiml8 05-13-2008 11:17 AM

That an XP installation on the same drive is working without issue would cause me to look first at things other than the drive.

Since you cannot install a distro, I would look at the CDROM device first; if it is failing that could be a problem. I have seen instances where a corrupted file on a CD/DVD was NOT caught and led me into all kinds of merry problems.

If not the CDROM device, then possibly the IDE cables, as someone else suggested.

It is also possible (though unusual) that a thermal problem in the HD is causing malfunctions over time with long writes (which an installation certainly is). I would not look for this until I had ruled out a lot of other things though.

Corrupted fs on the drive does suggest a HD problem, so maybe trying to keep the drive (and the mobo disk controller) cooler when doing the installation will gain you something.

If you can get your hands on a copy of Spinrite, you should try that. It will tell you pretty definitively what kind of shape your HD is in, and might even go a long way toward making it useable again if in fact it has a problem.

You might also take a look at the linux command badblocks and see what it tells you.

GrapefruiTgirl 05-13-2008 11:29 AM

Dirty CDROM lens?
 
Quote:

Originally Posted by jiml8 (Post 3151948)
...CD/DVD was NOT caught and led me into all kinds of merry problems.

Speaking of 'merry problems', I have experienced MANY caused by not defective hardware or corrupted CDs, but dirty lenses in the CD-ROM and/or DVD-ROM drives. OS's wouldn't install, even the IDE controller would sometimes hang because the optical drives were confused, thereby confusing the controller.

I almost resorted to purchasing new optical drive(s) about a year ago, to replace my several-year-old units, but finally it occurred to me to open up the units and clean the lenses with Isopropyl alcohol and a cotton swab.

The grime on the swab was visible, and once removed, the drives have worked like a charm ever since.

onebuck 05-13-2008 02:29 PM

Hi,
Quote:

Originally Posted by GrapefruiTgirl
;<snip>

I almost resorted to purchasing new optical drive(s) about a year ago, to replace my several-year-old units, but finally it occurred to me to open up the units and clean the lenses with Isopropyl alcohol and a cotton swab.

The grime on the swab was visible, and once removed, the drives have worked like a charm ever since.

I would suggest denatured alcohol vs isopropyl alcohol/rubbing alcohol. The denatured alcohol will not leave a film on the lense.

BTW, how often do you perform maintenance on your system(s)?

GrapefruiTgirl 05-13-2008 02:59 PM

Quote:

Originally Posted by onebuck (Post 3152123)
Hi,
I would suggest .. The denatured alcohol will not leave a film on the lense.

BTW, how often do you perform maintenance on your system(s)?

Good point re: the denatured stuff. I suppose it would be that which should be in a proper head cleaning kit?

And re: maintenance-- was that question directed at me?
If so, I would say my machine is in a somewhat constant state of maintenance :) as far as cleaning out the case, sometimes rearranging wires & cables inside, etc (it's rather spartan inside). However, maintenance (the regular kind) doesn't usually include disassembling individual pieces of hardware like the optical drives for lens cleaning.

I have the case open often (like right now as we speak), to make note of chip ID numbers, pinouts to stuff, motherboard connectors, replacing fans with better ones, cleaning the CPU cooler, that kind of stuff.

When my optical drive began acting up, it was almost 4 years old, having been exposed to 4 years of fireplaces nearby, cooking fumes, cigarette fumes and whatever else. That was the first time I decided to take them apart, and since then (that was about a year ago) I have probably done 2-3 more times whether they needed it or not.

michaelk 05-13-2008 03:18 PM

You want to use 100% Isopropyl alcohol which does not contain the perfume and oil additives. Other good cleaners if you can find them are Freon-TF or 100% grain alcohol.

onebuck 05-13-2008 09:12 PM

Hi,

Quote:

Originally Posted by michaelk (Post 3152179)
You want to use 100% Isopropyl alcohol which does not contain the perfume and oil additives. Other good cleaners if you can find them are Freon-TF or 100% grain alcohol.

Denatured alcohol is a ethyl alcohol with either acetone or methanol added to make the alcohol unfit for consumption. If you choose high purity isopropal alcohol (91%) then that would be usable with electronics.

A lot of people get the 71% and use it for electronics. These drug store varieties are not the best to use. To choose 100% grain alcohol for cleaning and consumption would solve a lot of the problems. I would prefer mine with a coke and not straight up an neat. :)

alan_ri 05-21-2008 11:15 AM

Thank you all for your replies and thoughts.The pc we were talking about is now in the hands of tehnicians,and I don't know how much more will be,but until now they only know that hard drive is bad.Anyway,9 days without computer,it wasn't easy,so after considering all the facts,I can say that now I'm the owner of the brand new beast with AMD Athlon processor,nvidia grafic etc.etc.Since I always had Intel and ATI and not so powerfull computers you can imagine what I'm going thrue now.This AMD thing is amazing.I will inform you about old pc.

GrapefruiTgirl 05-21-2008 02:53 PM

Awesome! A new machine is always fun and exciting, like a new car :-)

Have fun!!

Sasha

QuickSHADOWMAN 05-24-2008 02:55 PM

Aww....a new machine. I want one, too! But first, I need to get my house, then my stuff moved into it, and then after all that is done, get broadband, and find the parts to build my new machine, since my old one is over 7 years old.

Right now I am using an old library machine running, yuck, windows 2000. I have to say, that it is torture, not being on my wonderful old box running Debian Etch.

alan_ri 05-24-2008 10:47 PM

Do you know what I find really strange thing to be with that old machine?It's that no matter if you run it from the hard drive or live cd,the same thing happens,it chrashes and it's coming back to the login window.Anyway,I have spend few days trying to solve this issue,with no luck,and technicians that are now working on it still don't know any more then I do;that hard drive is bad,and I had to say that I already changed few places where my machine is being repaired,since the technicians in the originial store where the machine was made as configuration didn't do nothing in more then a week,and do you know what I found to be funny and sad thing in the same time;it's that I had to tell these technicians what a live cd and Linux is.

GrapefruiTgirl 05-25-2008 07:24 PM

Not surprising, Alan_ri about the 'funny & sad' part..

Interestingly (to me anyhow) I was driving into Truro a few months ago; Truro is the nearest 'large city-like place' to where I currently live in rural N.S. and is a rather conservative area. I don't really know how to get to more than the few places I go to regularly in that area (groceries, tobacco, etc), so I generally drive the same routes when I go there. Anyhow, this one day when I was somewhere near Truro, I passed a little computer shop of some sort, kinda like a residence but with a storefront-- I don't know if it was a sales place, a repair place, or what.. But I was very pleased to see on the outside of the place 3 little signs beside the door: A 'Windows' sign, a little apple sign for Mac, and... Tux the pengy! A Linux sign! :D

Try as I might, and I have, I have not been able to find the place again.. LOL. I don't even know what street it was on. I drove around and around a week or two ago, determined to finally stop in and check it out, but no luck.

:Pengy:
Sasha

alan_ri 05-26-2008 11:20 AM

I understand,Sasha.
So,you know what you have to do next time.Write it down somewhere,street or store name,cause now you now that those kind of stores are hard to find.
About my old machine,still no news,so I wonder,is it that bad?

sonichedgehog 05-26-2008 07:13 PM

I have old Microstar motherboard and similar issues, an old XP worked OK but there was a laugh a minute with DSL, and best we can do on Linux is a very slow version of Debian Lenny. Watch out for sysmontools, old HD's generally show prefails even when they're working- not to say that all failed HD's are really OK, you'd need to see it working as slave in another box.

I guess a 6 yr old windows works better on some old systems than newer Linux distros.

onebuck 05-26-2008 09:20 PM

Hi,
Quote:

Originally Posted by sonichedgehog (Post 3165440)
I have old Microstar motherboard and similar issues, an old XP worked OK but there was a laugh a minute with DSL, and best we can do on Linux is a very slow version of Debian Lenny. Watch out for sysmontools, old HD's generally show prefails even when they're working- not to say that all failed HD's are really OK, you'd need to see it working as slave in another box.

I guess a 6 yr old windows works better on some old systems than newer Linux distros.

I have linux on several older machines. You just need to know how and what needs to be done to the system. Legacy hardware can be tough at times with current Linux distributions. I prefer to use SlackwareŽ on older equipment but have used other distro to get a operating piece of equipment.

You just need to know the OS and what needs to be done. As for the HDD, I have no problems with older drives. If it is a failure then generally it is a hard HDD failure. Usually a IDE problem. Not worth it to repair the IDE board with cheap HDDs today. I've still got some systems with HDD MFM but don't think I'll use them, just keep them and fire them up for old times sake.

alan_ri 05-27-2008 03:24 AM

I agree with you onebuck,but what when we are trying to recognize a failure?That's a thing I'm having some doubts about,because when 10 different distros are showing different errors and sometimes the same distro upon reboot is showing different errors,then I wonder,what now?I know,different distros have different kernels which is a hand to my hardware,so one can expect different errors,but then again,if a hardware failure is the same for all distros,shouldn't errors be alike?How come I couldn't install 9 distros and only 1 I could.I have no doubt that good understanding of kernel itself could help in this matter.
Also,I agree that generally is a HDD failure.

onebuck 05-27-2008 01:00 PM

Hi,

If I suspect a HDD problem then I will run diagnostics on the piece of equipment. With the HDD I will start with the manufactures HDD diagnostic set. Easily obtained via a google of the manufacture then use their support.

sonichedgehog 05-27-2008 04:47 PM

Hi
If it helps with the current problem, the story of my ailing machine is on http://www.linuxquestions.org/questi...rboard-640144/

It's moved on a bit- I upgraded completely to testing as part of an experiment with ipod software, later versions were required for the m4a's, and, having worked OK with stable (yes quickshadowman I agree etch is great, it's just that some hardware asks for later versions), it then went slow again. I believed that the HDD was OK despite showing prefails because it worked fine as primary in another box. (Going back to a point discussed earlier in the thread, I have also had problems with dirty/malfunctioning cd drives.)

Onebuck, I agree entirely on the use of Linux with older hardware, as I have been able to build several viable systems with 10+ year old kit. (My only reason for not using slackware is that dynamic package management is one of my favourite Linux features.) But I suspect that age and wear are not the whole problem, both for alan ri, and also in my thread noted above; and the item in the present thread that really caught my attention was the possibility that a system could run on windows but encounter problems with Linux. I'm sure there's much to learn from this and wish I knew how.

The box in question is not my oldest but it's the only one that plays this trick: when running testing (not etch, that was OK), boots quickly as far as "waiting for /dev to become fully populated"- and from then on, very slow. Here's a puzzle- on one occasion, I lost power (nothing technical, I fell over the lead:tisk:) in mid install. The next boot was very fast- then I ran dpkg --configure -a to finish the job and went back to slow again. There's no clue in dmesg or ps -u root as to any process that's getting in the way.

The box I refer to is an experiment, expendable and will probably be recycled soon, Linux members have been very helpful. I'm not in a mess and I wouldn't ask for any more time to be spent, however I would like to find out for future reference whether the "/dev" problem is telling us something other than "chuck out the HDD".

H_TeXMeX_H 05-28-2008 09:31 AM

Quote:

Originally Posted by GrapefruiTgirl (Post 3160649)
Awesome! A new machine is always fun and exciting, like a new car :-)

Have fun!!

Sasha

if only more girls thought like that ;)

And as for how to know if a HDD is failing, run a test on it using smartctl, if your HDD is SMART capable, and it is enabled in the BIOS:
Code:

smartctl -t long /dev/hda
Remember to use you HDD device node (/dev/hda is just an example) Wait for it to finish then run:
Code:

smartctl -a /dev/hda
Then read these links to interpret the output:
http://en.wikipedia.org/wiki/Self-Mo...ing_Technology
http://www.hdsentinel.com/smart/index.php

pusrob 05-28-2008 10:46 AM

Hi everybody!
Quote:

Originally Posted by onebuck
With the HDD I will start with the manufactures HDD diagnostic set.

Well I agree with this. The best way to run such diagnostic tools is to download and use the UBCD (Ultimate Boot CD). It is a bootable CD with tons of free system diagnostic tools (for motherboard, RAM, HDD, etc...). To be more specific, there are HDD tools provided by manufacturers, all in one place.

If there is a hardware related problem in my (and others') PC, this is the tool I use to search for the problem(s). Here is the homepage of the UBCD.

Last week I used it to find out what was the problem with my friend's PC. The symptom was: windows just didn't boot suddenly (he's still a win user :( ). So here's what I did:

1: check if the IDE and power cable was connected to the HDD as needed. They were, but to be sure I pulled them out and put back again.
This is a useful procedure on old hardware, since the surface of pins become oxidized after some time, resulting in high drop of conductivity. Pulling out and putting back components remove the oxidized layer, so it fixes the problem.

2: checked if the HDD was accessible: boot up Mepis live CD and mount partitions, open some random files.
Opening randomly selected files makes you sure the HDD can be accessed, and also makes clear if the OS is still there or not.

3. booted UBCD, and run the appropriate HDD and RAM diagnostic tool.
This made me sure there are no physical and hidden problems with the HDD or RAM.

After putting all info pieces together I concluded that the HDD and all the computer hardware is in good health, so it must be a software related problem. My attention went to the boot sector. I put in the Win install CD, and boot from it. Here chose the recovery console, and run the fixboot command, which rewrote the MBR. After this pull out CD, reboot, and wait. Win started up as needed.

The conclusion: without Linux and free tools it would've been much harder to find and fix the problem.


An analogy: fixing a friend's computer is much like healing his/her pet. You have to find the problem without knowing anything but symptoms seen from the outside. Neither PCs, neither pets can tell you what doesn't work as it should be, you can only rely on your knowledge and symptoms shown be PCs and pets. In all two cases you first search for all possible problems based on the symptoms, and then think what the cure can be. So next time you go and fix a PC, you can think that you're something what can be called "computer vet" :D .

alan_ri 05-28-2008 12:11 PM

Quote:

Originally Posted by sonichedgehog (Post 3166358)
and the item in the present thread that really caught my attention was the possibility that a system could run on windows but encounter problems with Linux. I'm sure there's much to learn from this and wish I knew how.

Well it's not what it seems to be,because HD was dying and Windows that were already installed were also giving their last simptoms of life,but since I was trying to install Linux I didn't spend much time with my brother's Windows,but after I have succeed to install Backtrack I went back to Windows and guess what;blue screen came up and Backtrack was still somehow able to bring OS to the login window and after login there was still a little time to try and fix or see something before apps start to crash.Interesting thing is as I already stated,that 9 other distros failed to install,because they were unable to copy files to HD or because of some other error.and for things to be more interesting,I couldn't run a live cd because apps were crashing,but untill then I had no problems with cd-rom and it was clean because I was cleaning it regulary.So could it be that HD and cd-rom have died on the same day?
Anyway I'm still waiting for an answer from guys in the repair place.
As for SMART,I didn't check my BIOS to see if HDD was capable for it or not,but after reading online about it,I will check my BIOS on this new machine that I have now and see for all options and things you can do with BIOS,cause I never really played with it long enough.There are some interesting things about manufactures tools for checking,configuring your HDD,for example I didn't know that you can change your drive speed with some tools,of course depending on manufacturer.


All times are GMT -5. The time now is 06:57 AM.