I have a usb drive mounted to a folder in an Ubuntu 9.04 server installation. The mount options are stored in /etc/fstab for easy mounting/dismounting:
# <file system> <mount point> <type> <options> <dump> <pass>
/dev/sdb1 /media/backup ntfs nouser,auto,sync 0 3
(I've since changed the portion to a UUID to see if it would help with the problem). A backup has been copying files to the disk every morning without issue. Just now I tried to copy one of the files to another folder, and ended up with the error:
cp: reading `ts01-even.tgz': Input/output error
I discovered that the problem occured because /dev/sdb had changed to /dev/sdc. If I mount /dev/sdc and try to copy the file again, the drive will change back to /dev/sdb. After changing the fstab file system from /dev/sdX1 to a UUID there was no difference in behavior. Also, I used to be able to list the file contents of the tarball, but attempting to do so now results in the above behavior. Any ideas?
UPDATE:
running the backup script and storing the backup on the usb HD does not produce the problem, but listing the files in the tarball does. Here is the output of the syslog during the tarball command "tar -ztf FILENAME":
Jul 3 15:09:14 ts01 kernel: [308398.446893] Buffer I/O error on device sdc1, logical block 786433
Jul 3 15:09:28 ts01 ntfs-3g[7468]: ntfs_attr_pread_i: ntfs_pread failed: Input/output error
Jul 3 15:09:28 ts01 ntfs-3g[7468]: Failed to read of MFT, mft=5 count=1 br=-1: Input/output error
Jul 3 15:09:28 ts01 kernel: [308412.404579] Buffer I/O error on device sdc1, logical block 786433
Jul 3 15:09:29 ts01 ntfs-3g[7468]: Unmounting /dev/sdc1 (FreeAgent Drive)
Jul 3 15:09:32 ts01 ntfs-3g[29176]: Version 2009.2.1 external FUSE 27
Jul 3 15:09:32 ts01 ntfs-3g[29176]: Mounted /dev/sdb1 (Read-Write, label "FreeAgent Drive", NTFS 3.1)
Jul 3 15:09:32 ts01 ntfs-3g[29176]: Cmdline options: rw,sync
Jul 3 15:09:32 ts01 ntfs-3g[29176]: Mount options: rw,sync,silent,allow_other,nonempty,relatime,fsname=/dev/sdb1,blkdev,blksize=4096
Jul 3 15:10:01 ts01 /USR/SBIN/CRON[29630]: (root) CMD ([ -x /usr/sbin/update-motd ] && /usr/sbin/update-motd 2>/dev/null)
Jul 3 15:11:35 ts01 kernel: [308539.310031] usb 1-1: reset high speed USB device using ehci_hcd and address 38
... (log repeated with a different address)
Jul 3 15:12:47 ts01 kernel: [308611.790038] usb 1-1: reset high speed USB device using ehci_hcd and address 38
Jul 3 15:12:49 ts01 kernel: [308613.148837] end_request: I/O error, dev sdb, sector 84779391
Jul 3 15:12:49 ts01 kernel: [308613.148871] Buffer I/O error on device sdb1, logical block 10597416
... (log repeated with a different address, with the logical block incrementing by 1 each time)
Jul 3 15:12:49 ts01 kernel: [308613.149090] Buffer I/O error on device sdb1, logical block 10597425
Jul 3 15:12:49 ts01 ntfs-3g[29176]: ntfs_attr_pread_i: ntfs_pread failed: Input/output error
Jul 3 15:12:49 ts01 ntfs-3g[29176]: ntfs_attr_pread error reading '/TS01_Backup/ts01-even.tgz' at offset 177012736: 131072 <> -1: Input/output error
Jul 3 15:12:49 ts01 ntfs-3g[29176]: ntfs_attr_pread_i: ntfs_pread failed: Input/output error
Jul 3 15:12:49 ts01 ntfs-3g[29176]: ntfs_attr_pread error reading '/TS01_Backup/ts01-even.tgz' at offset 177012736: 4096 <> -1: Input/output error
I found something that seemed relevant, but following the instructions has not proven fruitful: FreeAgent Drives