Get HDD Serial Number on Linux

Get serial number of hard disk use command 「hdparm」and grep 「Serial」 string.

jerry@jerry-P5Q-office:~$ sudo hdparm -I /dev/sda | grep Serial
[sudo] password for jerry:
	Serial Number:      L22K64AG

All information we can get from hdparm command.

jerry@jerry-P5Q-office:~$ sudo hdparm -I /dev/sda 


ATA device, with non-removable media
	Model Number:       Maxtor 6L080M0                          
	Serial Number:      L22K64AG            
	Firmware Revision:  BACE1G10
	Used: ATA/ATAPI-7 T13 1532D revision 0 
	Supported: 7 6 5 4 
	Logical		max	current
	cylinders	16383	16383
	heads		16	16
	sectors/track	63	63
	CHS current addressable sectors:   16514064
	LBA    user addressable sectors:  156301488
	LBA48  user addressable sectors:  156301488
	Logical/Physical Sector size:           512 bytes
	device size with M = 1024*1024:       76319 MBytes
	device size with M = 1000*1000:       80026 MBytes (80 GB)
	cache/buffer size  = 8192 KBytes (type=DualPortCache)
	LBA, IORDY(can be disabled)
	Standby timer values: spec'd by Standard, no device specific minimum
	R/W multiple sector transfer: Max = 16	Current = 0
	Advanced power management level: 254
	Recommended acoustic management value: 192, current value: 192
	DMA: mdma0 mdma1 mdma2 udma0 udma1 udma2 udma3 udma4 *udma5 
	     Cycle time: min=120ns recommended=120ns
	PIO: pio0 pio1 pio2 pio3 pio4 
	     Cycle time: no flow control=120ns  IORDY flow control=120ns
	Enabled	Supported:
	   *	SMART feature set
	   *	Power Management feature set
	   *	Write cache
	   *	Look-ahead
	   *	WRITE_VERIFY command
	   *	WRITE_BUFFER command
	   *	READ_BUFFER command
	   *	NOP cmd
	   *	Advanced Power Management feature set
	    	SET_MAX security extension
	   *	Automatic Acoustic Management feature set
	   *	48-bit Address feature set
	   *	Device Configuration Overlay feature set
	   *	Mandatory FLUSH_CACHE
	   *	SMART error logging
	   *	SMART self-test
	   *	General Purpose Logging feature set
	   *	Gen1 signaling speed (1.5Gb/s)
	   *	Software settings preservation
Checksum: correct


在下方填入你的資料或按右方圖示以社群網站登入: Logo

您的留言將使用 帳號。 登出 / 變更 )

Twitter picture

您的留言將使用 Twitter 帳號。 登出 / 變更 )


您的留言將使用 Facebook 帳號。 登出 / 變更 )

Google+ photo

您的留言將使用 Google+ 帳號。 登出 / 變更 )

連結到 %s