I have an Ubuntu installation which has a lot of hard drives. Two of these drives have hiccups and SMART is reporting errors. However, I cannot figure out how to determine which drive is ata1.00 and which is ata12.00. Is it possible to retrieve their serial numbers, as this would be easiest way to find the correct drives?
lshw -C disk
will get you drives, their product ids, and mount points.
description: ATA Disk product: XXXX vendor: Seagate physical id: 0 bus info: scsi@0:0.0.0 logical name: /dev/sda version: JC4B serial: XXXYYY size: 931GiB (1TB) capabilities: partitioned partitioned:dos configuration: ansiversion=5 signature=0006ded4
You can then find their most recent mount info in /var/log/syslog, with something like (e.g. looking for disk /dev/sda)
cat /var/log/syslog | grep 'sda' -A 5 -B 5
for other info, you can also try