LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 03-29-2006, 04:56 PM   #1
jrdioko
Member
 
Registered: Oct 2002
Distribution: Debian 6.0.2 (squeeze)
Posts: 944

Rep: Reputation: 30
Dar and cat: Input/output error (possible drive problems)


I recently used dar to make a backup of my system, and was given the following error halfway through the process:

Code:
Error while saving /home/myuser/.thunderbird/default.bnf/Mail/News & Blogs/News: Error while reading from file: Input/output error
I emailed the error to dar's support mailing list, and was told to try cat'ing the file to /dev/null and making a backup of just that single file, to see if the problem recurred. I did both (99% sure I typed everything right), and wasn't given any errors.

I then tried the full backup again, and was given the same error again. I tried the cat and single backup again, and this time get IO errors on both:

Code:
> cat /home/myuser/.thunderbird/default.bnf/Mail/News\ \&\ Blogs/News > /dev/null
cat: /home/myuser/.thunderbird/default.bnf/Mail/News & Blogs/News: Input/output error

> dar [just that one file] > /dev/null
Adding file to archive: /home/myuser/.thunderbird/default.bnf/Mail/News & Blogs/News
Error while saving /home/myuser/.thunderbird/default.bnf/Mail/News & Blogs/News: Error while reading from file: Input/output error
Writing archive contents...


 --------------------------------------------
 0 inode(s) saved
 with 0 hard link(s) recorded
 0 inode(s) changed at the moment of the backup
 0 inode(s) not saved (no file change)
 1 inode(s) failed to save (filesystem error)
 38 files(s) ignored (excluded by filters)
 0 files(s) recorded as deleted from reference backup
 --------------------------------------------
 Total number of file considered: 39
 --------------------------------------------
 EA saved for 0 file(s)
 --------------------------------------------
I don't like the sound of "filesystem error" very much...

What would cause an IO error like this to happen? Should I worry about general filesystem corruption, or is this just some quirk with that one file? If it matters, running "file" on it gives me:

Code:
.thunderbird/default.bnf/Mail/News & Blogs/News: UTF-8 Unicode English text, with very long lines, with CRLF, LF line terminators
I can also edit the file with vim and view all of it with no problems.

Thanks in advance.

--EDIT--
If it helps, here's the end of the result of running strace on the cat command:

Code:
read(3, "\n        padding: 0;\n      }\n   "..., 4096) = 4096
write(1, "\n        padding: 0;\n      }\n   "..., 4096) = 4096
read(3, 0x804e3b0, 4096)                = -1 EIO (Input/output error)
write(2, "cat: ", 5cat: )                    = 5
write(2, ".thunderbird/default.bnf/Mail/Ne"..., 47.thunderbird/default.bnf/Mail/N                                                                                     ews & Blogs/News) = 47
open("/usr/share/locale/en_US/LC_MESSAGES/libc.mo", O_RDONLY) = -1 ENOENT (No suc                                                                                     h file or directory)
open("/usr/share/locale/en/LC_MESSAGES/libc.mo", O_RDONLY) = -1 ENOENT (No such f                                                                                     ile or directory)
write(2, ": Input/output error", 20: Input/output error)    = 20
write(2, "\n", 1
)                       = 1
close(3)                                = 0
close(1)                                = 0
exit_group(1)                           = ?
--EDIT 2--
Some more relevant info: I checked /var/log/messages, and I don't really know what I'm looking for, but I don't see anything interesting there. Also, when I try to cat the file without sending it to /dev/null, I get most of the file printed and then the IO error:

Code:
lots of things fly by
...
      iframe {
        position: fixed;
        top: 0;
        right: 0;
        bottom: 0;
        left: 0;
        border: none;
      }

    </style>
  </head>
  <body>
    
    <iframe id ="_mailrssiframe" src="http://www.cat: News: Input/output error
--EDIT 3--
Sorry for writing this post as I go...

I tried viewing the same part of the file in vim, and I notice the "<body>" tag in the error above is the very last thing that appears in the file in vim, on line 17511.

--EDIT 4--
Well, it looks like about the worst thing that can happen has... I just checked my /var/log/syslogs, and I get the following fun error:

Code:
> grep dma /var/log/syslog*
syslog:Mar 28 00:20:58 mymachine kernel: hda: dma_intr: status=0x51 { DriveReady SeekComplete Error }
syslog:Mar 28 00:20:58 mymachine kernel: hda: dma_intr: error=0x40 { UncorrectableError }, LBAsect=49213032, sector=29088304
syslog:Mar 29 13:05:42 mymachine kernel: hda: dma_intr: status=0x51 { DriveReady SeekComplete Error }
syslog:Mar 29 13:05:42 mymachine kernel: hda: dma_intr: error=0x40 { UncorrectableError }, LBAsect=49213032, sector=29088304
syslog:Mar 29 13:05:46 mymachine kernel: hda: dma_intr: status=0x51 { DriveReady SeekComplete Error }
syslog:Mar 29 13:05:46 mymachine kernel: hda: dma_intr: error=0x40 { UncorrectableError }, LBAsect=49213032, sector=29088312
syslog:Mar 29 14:41:04 mymachine kernel: hda: dma_intr: status=0x51 { DriveReady SeekComplete Error }
syslog:Mar 29 14:41:04 mymachine kernel: hda: dma_intr: error=0x40 { UncorrectableError }, LBAsect=49213032, sector=29088304
syslog:Mar 29 14:41:08 mymachine kernel: hda: dma_intr: status=0x51 { DriveReady SeekComplete Error }
syslog:Mar 29 14:41:08 mymachine kernel: hda: dma_intr: error=0x40 { UncorrectableError }, LBAsect=49213032, sector=29088312
Most things I read online say this means the drive is physically bad and needs to be replaced, although a couple point to filesystem corruption that could be fixed. I've backed up what I can and I'll continue to do that so I make sure nothing gets lost, and I'm wondering what my next step should be. What exactly is this error, and should I try fsck or something else. I have a ReiserFS filesystem.

--EDIT 5--
I just read over the above errors again, and it appears they only appeared when I was making a backup that tried to read that file or when I was doing the testing on it with cat (as opposed to being random or periodic) if that makes any difference.

--EDIT 6--
I just booted up a Live CD to do a little drive checking. I ran reiserfsck --check and was told the filesystem was clean with no problems. I then ran badblocks on the partition which returned with no output, I assume meaning that none were found. What am I to make of this? Do I believe the kernel logs which are indicating drive problems, or believe badblocks, which is supposed to check if they exist? Is there a chance the default badblocks configuration will not detect some bad blocks?

Last edited by jrdioko; 03-29-2006 at 11:02 PM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
aplay: pcm_write:1029: write error: Input/output error mimithebrain Linux - Software 2 12-04-2007 11:51 AM
cat /dev/ttyS0: Input/output error lionking_x Linux - Hardware 3 01-06-2006 11:16 PM
cp - error reading /mnt/cdrom/mpegav/avseq01.dat input/output error manishsingh4u Linux - General 2 10-17-2005 05:02 AM
Cat input output error zaicheke Slackware 15 12-26-2004 09:08 PM
what is input output error? paschim Linux - Newbie 2 10-24-2004 05:53 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 08:21 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration