29

I'm running Ubuntu on a laptop and am shopping to upgrade to an SSD.

Based on the specs for this drive for example, it seems like I should figure out what version of SATA my computer will support before I buy.

I don't want so shell out the big bucks for a really fast drive if my SATA controller will be the bottleneck anyway. Does this make sense?

Newegg presents this as SATA 2 (SATA II) running at 3Gbps and SATA 3 (SATA III) running at 6 Gbps.

What tools can I use in Ubuntu to determine if my computer will support SATA 3?

Oliver Salzburg
  • 89,072
  • 65
  • 269
  • 311
Sean
  • 478

5 Answers5

35

Try dmesg | grep SATA, this is a little faster than lspci as it will print out the kernel buffer logs from boot/after boot with the SATA speeds right there. You should see something like this:

[1.236431] ahci 0000:00:1f.2: AHCI 0001.0300 32 slots 6 ports 3 Gbps 0x33 impl SATA mode

Again this is only your controller so it's not guaranteed. And it'll show your current hd

[1.577525] ata1: SATA link up 3.0 Gbps (SStatus 123 SControl 300) 

This is your drive's ultimate connection, i.e. SATA revision the drive is running at.

d a i s y
  • 109
18

This command gives you the version exactly:

sudo smartctl -a /dev/sda | grep SATA
SATA Version is:  SATA 2.6, 3.0 Gb/s (current: 3.0 Gb/s)

d a i s y
  • 109
iman
  • 301
5

lspci will tell you all the controllers and devices, take a look at your SATA controller, it should give you a model. Take that model and look up the specs for it. You will probably need elevated privileges (su/sudo) for lspci to work for you.

BloodyIron
  • 2,041
4

This site has a great walk through to get any data about your drives you might want.

It expands on other answers here with little tricks like:

dmesg | grep -i sata | grep 'link up'

And:

sudo hdparm -I /dev/sda | egrep "Model|speed|Transport"
Giacomo1968
  • 58,727
Alvin
  • 275
1

You can read the currently active SATA link speeds by checking the read-only data in /sys/class/ata_link. For example, print all active link speeds with grep -v unknown /sys/class/ata_link/link*/*sata_spd*

root@debian:~# grep -v unknown /sys/class/ata_link/link*/*sata_spd*
/sys/class/ata_link/link1/sata_spd:1.5 Gbps