0

I'd like to organize my many micro SD cards in a Excel table, to know what is on which micro SD card.

It's very difficult to stick a physical label on it (too small, and they always go away after a few months of handling it), so I'm looking for a software solution:

Is there a unique identifier (UUID) that stays on a given micro SD card, forever, and doesn't change even if we flash a new ISO Linux image on it? (for example Raspberry, but this is just one example)

If so, how to easily read this UUID from Windows and Linux?

Basj
  • 1,489
  • 7
  • 47
  • 90
  • See https://unix.stackexchange.com/questions/196899/finding-a-unique-identifier-for-sd-cards . Also https://superuser.com/questions/1627622/how-to-read-sd-card-cid-on-windows-10 – Reddy Lutonadio Jun 17 '23 at 08:07
  • Calculate a checksum over the disk image or the card itself and use it as filename for example. In your excel then store the checksum + some details about the file / disk image. Getting a truly unique ID like CID isn't very straight forward and a USB card reader may not even support it. – Joep van Steen Jun 17 '23 at 10:05
  • 1
    BTW, SD Cards aren't a wise choice for longer term storage. – Joep van Steen Jun 17 '23 at 10:17
  • @JoepvanSteen Thanks but it's not for long term storage, I manage a RasPi distribution, and I have dozens of SD card with different test versions, so I want to quickly remember which test version is on which SD card – Basj Jun 17 '23 at 10:49

1 Answers1

1

The high-tech solution is to read the Card Identification (CID) Register, which is a 16-byte code that contains information that uniquely identifies the SD card, including the card serial number (PSN), manufacturer ID number (MID) and manufacture date (MDT). The CID register is set when the card is manufactured and cannot be changed after it is set.

Unfortunately, not all manufacturers can be depended upon to burn a unique CID into each and every SD card that they fabricate.

If interested, see these sources :

The low-tech solution would be to write a unique number on the card with indelible ink, and keep a list of the cards and their contents using utilities such as Excel or even Notepad.

harrymc
  • 455,459
  • 31
  • 526
  • 924