# dmidecode --string system-uuid
I'm using the code above get the UUID on each host in my environment. As far as I understand the UUID should not change between different Linux distributions on the same host with the same hardware configuration. But after some tests on different Linux distributions I encountered different uuid with this same command.
It seems that older
dmidecode version will get different UUID result.
dmidecode 2.9 from SLES11.2 result with
string A and
dmidecode 2.12 from Debian 8 result with
How can I get the same uuid no matter the Linux distribution I deploy on my machine?
I wanted to use
dmidecode and not MAC address as UUID because i saw that if I replace my network adapter or some other hardware's settings the UUID will not change.
What I need is some unique identifier that I can have on my machine to identify it across minor hardware changes and different OS. Using
dmidecode cannot be fake in some level I guess instead of just generating UUID and writing it to a file and using it.
I'm working with VMware and machine clones are often used and that's why I need something that will not be replicated with the clone.