Author Topic: (SOLVED) Connection to external drive suddenly lost.  (Read 1375 times)

Offline besonian

  • Hero Member
  • *****
  • Posts: 829
(SOLVED) Connection to external drive suddenly lost.
« on: February 13, 2010, 04:56:12 AM »
I'm running LXDE but I doubt that's relevant, hence my posting this here. I was doing some regular backing up (using Lucky Backup) to an external USB hard drive when everything suddenly stopped. LuckyBackup told me the connection had suddenly closed. Typing 'df' in a terminal confirmed there was now no connection to the external drive. I checked all cables etc, but no joy. Then I noticed that the following had appeared in the terminal -

Message from syslogd@hostname at Sat Feb 13 11:23:04 2010 ...
hostname kernel: journal commit I/O error

It clearly relates to what had just happened, but though I don't know what to do about it, it looks like I should be concerned. I've consequently removed the external drive and am now testing it out on another machine running KDE4. This fault is on the main machine I work on and I'd obviously like to sort it ASAP.  Any help, advice etc, very gratefully received.
« Last Edit: February 23, 2010, 10:12:49 AM by besonian »
We are here and it is now. Further than that all human knowledge is moonshine.

Offline cyrwyn

  • Hero Member
  • *****
  • Posts: 833
Re: Connection to external drive suddenly lost.
« Reply #1 on: February 13, 2010, 09:18:32 AM »
According to the error message I assume the external drive has a journaling filesystem. Was it still mounted? If not, did you try to mount it? Did you try to run fsck on it unmounted? Does it work on another computer? Otherwise, I don't know what that error means. Did you try Googling it?
Using Linux for over 18 years and still counting.

Offline besonian

  • Hero Member
  • *****
  • Posts: 829
Re: Connection to external drive suddenly lost.
« Reply #2 on: February 13, 2010, 10:16:04 AM »
cyrwyn - it was mounted. I was actually backing up images onto it at the time. Since then I've hooked it up to another computer, also running LXDE and it's been mounted on that for about three hours now while I've done an emergency back-up of other stuff I had on it - and it's behaved perfectly. So I have to conclude - unless some genius here can tell me otherwise - that the fault lies somewhere with the main machine I was using at the time. And no, I hadn't googled it, but I will.
« Last Edit: February 14, 2010, 11:26:26 AM by besonian »
We are here and it is now. Further than that all human knowledge is moonshine.

Offline cyrwyn

  • Hero Member
  • *****
  • Posts: 833
Re: Connection to external drive suddenly lost.
« Reply #3 on: February 13, 2010, 11:30:42 AM »
What I was asking was if the drive unmounted when it gave this error. If df didn't show it, then what state was it in? Could you not access it in any way? Did you try manually unmounting and mounting? Could there have been an OS glitch? Did you shutdown and reboot and try it again? I'd also look for other system error messages when you try these.
Using Linux for over 18 years and still counting.

Offline besonian

  • Hero Member
  • *****
  • Posts: 829
Re: Connection to external drive suddenly lost.
« Reply #4 on: February 13, 2010, 11:42:39 AM »
Sorry - misread you. Yes, it unmounted when the error occurred. I then switched it off (it has an onboard on/off switch) waited a few seconds, then switched it on again. It reappeared in the file manager, I clicked on it and it mounted immediately once more. However - the same thing happened a few minutes later. I suspect it is to do with the OS. The same drive has now been mounted on another machine all afternoon (1840 now) and been accepting backups with no problem.
We are here and it is now. Further than that all human knowledge is moonshine.

Offline cyrwyn

  • Hero Member
  • *****
  • Posts: 833
Re: Connection to external drive suddenly lost.
« Reply #5 on: February 14, 2010, 09:18:45 AM »
You and me are both hero members and should know about running checks. Did you try an fsck on the drive? Does the other machine on which the drive seems to be running OK use a different kernel version? I have no clue what might cause this problem if it is in the OS and not on the drive's filesystem. If it is in the OS I would be worried. Has the system crashed or shown any other problem recently? Could it be USB problem? I'm just trying to think of any suggestion that might shine some light on the problem. Good luck. 
Using Linux for over 18 years and still counting.

Offline besonian

  • Hero Member
  • *****
  • Posts: 829
Re: Connection to external drive suddenly lost.
« Reply #6 on: February 14, 2010, 11:25:31 AM »
I haven't done an fsck check on the external drive, I have to admit. It has however worked perfectly on this other machine over two days now and it's been pretty busy, so I doubt there's a file system problem on it. I suspect it's the OS on the first machine - that's why I suggested in the first post that I felt I should be concerned. The kernel is the same on both, both are running LXDE. The only other thing I can think of is, as you say, a USB problem, maybe that specific port itself. I'll be back on that machine on Tuesday, so will try out those remainging things then. I had hoped that someone like Old Polack might see this thread, then I think we'd have some ideas. It would help of course if either of us knew what the hell the terminal message meant   ;D But thank you for your thoughts. I have now to put this on hold until Tuesday.
We are here and it is now. Further than that all human knowledge is moonshine.

Offline muungwana

  • Hero Member
  • *****
  • Posts: 6235
Re: Connection to external drive suddenly lost.
« Reply #7 on: February 14, 2010, 11:34:48 AM »
you should run "fsck" on that drive. Just because you havent seen any more errors doest mean there are no errors on the drive. You just havent hit areas yet were errors exist.

The problem could be  that you hit bad blocks that couldnt be read/written to and they need to be identified and marked off or there was a software logic error in reading/writing something and the error need to be corrected. Either way, a fsck is required.

Old-Polack would say the same thing ..maybe adding a specific options to fsck.
.. 3 things are certain in life : death, taxes and software bloat ..
.. tell me something i don't know, something i can use as i struggle to reason with the world around me ..

Offline besonian

  • Hero Member
  • *****
  • Posts: 829
Re: Connection to external drive suddenly lost.
« Reply #8 on: February 14, 2010, 03:06:08 PM »
OK. Point taken. I'll do that on Tuesday. And do I do that via the live CD, as you would an internal drive?

In fact, just after writing that above sentence I switched that drive on and it has not appeared in the PCMan file manager.  :'( Tried it again and it's not appearing. I guess somewhere on that is the seat of the trouble - like,it's on its way out. Or has already passed on. Fortunately when it happened the first time on the other machine, the first thing I did was to back up the back up. Anyway, I'll still do that fsck on Tuesday and see what it tells me. Thanks, muungwana.
We are here and it is now. Further than that all human knowledge is moonshine.

Offline muungwana

  • Hero Member
  • *****
  • Posts: 6235
Re: Connection to external drive suddenly lost.
« Reply #9 on: February 14, 2010, 03:40:25 PM »

it is not necessary to do it from the live cd. it is necessary though to make sure the partition you are going to check for errors is not mounted. It is usually necessary to run "fsck" from the livecd when checking root or home partitions because they cant be unmounted on a live system.

There is a command called "dmesg" that prints out what the kernel sees about the hardware you have. It could be useful to run the command after you attach the drive or after you attempt to mount it to see what the kernel reports
.. 3 things are certain in life : death, taxes and software bloat ..
.. tell me something i don't know, something i can use as i struggle to reason with the world around me ..

Online Old-Polack

  • Administrator
  • Super Villain
  • *****
  • Posts: 11562
  • ----IOFLU----
Re: Connection to external drive suddenly lost.
« Reply #10 on: February 14, 2010, 07:30:30 PM »
besonian:

I've been a bit busy the last few days, but have been following along with this thread. You are getting good advise, so far, so really didn't feel the need to jump in until now. About the only thing I would add, is that I would also run a memtest86 test of the RAM on the machine that has been disconnecting.

Ram can do funny things, and cause all sorts of odd behaviors. If you have more than one RAM stick, and errors do show up. test the RAM sticks individually to see which is causing the problem. Sometimes all that is needed is to reseat the RAM sticks to make them behave. Other times they need contact cleaning. The MB RAM sockets can also become dirty, and show up as bad RAM, just because the contacts are no longer tight. Cleaning the sockets regains full contact and the problems go away.

The weirdest thing I have recently come across, was a 1GB stick of DDR RAM that reported errors no matter how clean I got the contacts, or what socket I plugged it into, in any machine it was tested in, so I labeled it bad, and laid it aside. Out of curiosity, I let it sit on my desktop for a week, then retested it. On retest no errors were reported in any socket. (Long overnight tests, in various machines, each night, for a week.) I reinstalled it into my backup computer, where it has been running flawlessly for the past six months. I can only conclude that something caused it to take on a charge that prevented proper paging, and that leaving it out of the system for a week allowed the charge to bleed off. I still consider this a test in progress, as I'd never heard of RAM being reported as bad, then recovering to full functionality before this. I find this rather interesting. ;D
Old-Polack

Of what use be there for joy, if not for the sharing thereof?



Lest we forget...

Offline besonian

  • Hero Member
  • *****
  • Posts: 829
Re: Connection to external drive suddenly lost.
« Reply #11 on: February 15, 2010, 02:41:57 PM »
muungwana - OK, I've now done an fsck on the drive - result is -

/dev/sda1: clean, 39426/19537920 files, 51365636/78142160 blocks

Which presumably means the file system is OK. Does it also mean the drive itself is in good shape and not about to fall over? I'll run a drive diagnostic disk when I get back to the other machine tomorrow.

And old-polack - nice to have your input and glad to know I was being pointed in the right directions. But there are inconsistencies here which are puzzling me. I'd go into them now except I've been out all day, only just go back - 2140 in UK - and I'm all in. I'll be at the original machine tomorrow and will try sometime in the day to list this drive's behaviour which is confusing me. But at least I guess the file system's in OK order. Thank you guys and good night.
We are here and it is now. Further than that all human knowledge is moonshine.

Offline muungwana

  • Hero Member
  • *****
  • Posts: 6235
Re: Connection to external drive suddenly lost.
« Reply #12 on: February 15, 2010, 08:33:20 PM »
muungwana - OK, I've now done an fsck on the drive - result is -

/dev/sda1: clean, 39426/19537920 files, 51365636/78142160 blocks

Which presumably means the file system is OK. Does it also mean the drive itself is in good shape and not about to fall over? I'll run a drive diagnostic disk when I get back to the other machine tomorrow.
If the problem is with the partition, the problem will show up on any system. I have no reason to not trust fsck so it it says all is well, then i will have to go with what it says but it wont hurt running another application to check it out. Dont forget to run run "dmesg" when the error shows up again for more info.
.. 3 things are certain in life : death, taxes and software bloat ..
.. tell me something i don't know, something i can use as i struggle to reason with the world around me ..

Offline besonian

  • Hero Member
  • *****
  • Posts: 829
Re: Connection to external drive suddenly lost.
« Reply #13 on: February 17, 2010, 02:32:49 AM »
This may - just may - be the end of this - yesterday I returned to the machine on which the problem first occurred. I started to back some more images up and on two occasions, connection to the drive was lost. OK- the file system's alright, I knew that. So next I installed the drive - a 320gb Maxtor IDE - into another machine and booted with Seagate's disk-checking facility. In both the quick and the long test (2 hours) it passed.

I put the drive back into its enclosure, and connected it up to the main machine again but this time changed the USB cable. The back up this time went without hitch. So it may be back to OP's comments about the often weirdness of computers and their components. If - and I can't yet be sure of this - that's the problem sorted, it could be the USB cable. On the other hand it could be some quirk of the connections in the drive's enclosure which was eradicated when I first disconnected, then re-connected the drive. And yet again, it still might not be the end of it.

As I can't yet be sure, I'll leave the thread open for the time being. I'll be doing some more backups during the week and will report back here one way or the other.
We are here and it is now. Further than that all human knowledge is moonshine.

Offline ThirdOfSix

  • Hero Member
  • *****
  • Posts: 745
Re: Connection to external drive suddenly lost.
« Reply #14 on: February 17, 2010, 03:03:12 AM »
besonian,

This may be irrelevant but maybe not.

One of my machines has both USB 1  and USB 2 ports on it.

I sometimes forget which are which. With some of my external drives it really matters.

Is there any chance that you plugged it into a different port the last time?

Also, along the same lines, the early USB cables were not designed for USB 2 speeds and may give intermittent results on USB 2.

Of course, since they did not know that there was going to be a USB 2 coming along, the cables are not marked as USB 1 only.

If you have multiple cables around, you might want to put a label on the one that you were using when it did not work.

It can be very frustrating to work on a problem for days and then remember that you had seen that same problem months ago and then realize that you are now using that same cable of questionable quality that you were using then.

« Last Edit: February 17, 2010, 03:05:03 AM by ThirdOfSix »