Page 1 of 1
ls: reading directory /var/share/movies/: Input/output error
Posted: Wed Jul 24, 2013 6:36 pm
by mister_v
Hello,
I get the following error when using the ls-command
Code: Select all
ls: reading directory /var/share/movies/: Input/output error
Anyone know what it means?
Re: ls: reading directory /var/share/movies/: Input/output e
Posted: Thu Jul 25, 2013 9:02 am
by Chris
Sounds like you have a read problem (hardware problem).
Try unmounting and remounting your drive.
You can also check dmesg for more info.
Re: ls: reading directory /var/share/movies/: Input/output e
Posted: Sat Jul 27, 2013 2:10 pm
by mister_v
Unmounted the drive and checked it with fdisk:
Code: Select all
# fdisk /dev/sdd
fdisk: cannot open /dev/sdd: Input/output error
Dmesg gives the following:
Code: Select all
dmesg | grep sdd
[1530841.170290] sd 5:0:0:0: [sdd] Unhandled error code
[1530841.170293] sd 5:0:0:0: [sdd]
[1530841.170297] sd 5:0:0:0: [sdd] CDB:
[1530841.170323] sd 5:0:0:0: [sdd] Unhandled error code
[1530841.170326] sd 5:0:0:0: [sdd]
[1530841.170330] sd 5:0:0:0: [sdd] CDB:
[1530841.170354] sd 5:0:0:0: [sdd] Unhandled error code
Doesn't sound good...
Re: ls: reading directory /var/share/movies/: Input/output e
Posted: Tue Aug 27, 2013 7:20 pm
by mister_v
the drive is bad,
but how do I know in linux what drive is connected to what sata-port?
I have 6 drives,
the bad one is /dev/sdd
Re: ls: reading directory /var/share/movies/: Input/output e
Posted: Tue Aug 27, 2013 7:26 pm
by Chris
In the latest version of linux (at least from kernel 3.2)
you can get a list of hard disk id's in /dev/disk/by-id/
Code: Select all
ls -l /dev/disk/by-id/
lrwxrwxrwx 1 root root 9 Aug 27 20:47 scsi-SATA_SAMSUNG_HD103SJS246J9GB303707 -> ../../sdb
lrwxrwxrwx 1 root root 10 Aug 27 20:47 scsi-SATA_SAMSUNG_HD103SJS246J9GB303707-part1 -> ../../sdb1
lrwxrwxrwx 1 root root 10 Aug 27 20:47 scsi-SATA_SAMSUNG_HD103SJS246J9GB303707-part2 -> ../../sdb2
it doesn't tell you which SATA port;
But it does tell you the drive id.
The same number is also printed on a label of the hard disk.
This should help you find the correct disk.