Find disk by id in Linux

You may be wondering why linux is not pointing to a standard /dev/sdX for your SATA hard drives. When you come across a reference to a hard-drive in the ID form like this:

disk/by-id/wwn-0x5000cca221d63ffd

Then you can find the actual path in /dev/ by doing a simple command:

root@Gserver:/dev/disk/by-id# ls -la /dev/disk/by-id/wwn-0x5000cca221d63ffd
lrwxrwxrwx 1 root root 9 2011-04-15 00:42 /dev/disk/by-id/wwn-0x5000cca221d63ffd -> ../../sde

This quick method will tell you where the name pointer “wwn-0x5000cca221d63ffd” is actually physically connected to on the motherboard. Helpful for those that need to swap the hard drive and have multiple same-brand, same-size setup like myself in my media server.

Leave a Reply