Can I get BIOS UUID and HDD serial number?

(imported topic written by wazty200291)

Hi,

I know Bigfix can get many computer informations through WMI, can it get BIOS UUID and HDD serial number? If it is possible, how to do?

Thanks!

(imported comment written by BenKus)

This worked on one of my computers for HDD serial number… you can try on yours:

string values of selects “SerialNumber from win32_diskdrive” of wmi

I didn’t see a BIOS UUID on my system… if you run in QnA:

q: selects “* from Win32_BIOS” of wmi

on some of your computers, does it show a UUID?

Ben

(imported comment written by wazty200291)

Thanks Ben, selects “* from Win32_BIOS” of wmi cannot list the UUID of computer, and I cannot get HDD serial number, please see the answer below:

Q: string values of selects “SerialNumber from win32_diskdrive” of wmi

E: The expression could not be evaluated: Windows Error: unknown error 0x80041017

(imported comment written by BenKus)

I looked around the Internet a bit and found this:

UUID:

string values of selects “UUID from Win32_ComputerSystemProduct” of wmi

HD Serial Number? (here is another one I found that only seemed to work on some of my computers):

string values of selects “SerialNumber from Win32_PhysicalMedia” of wmi

Ben

(imported comment written by wazty200291)

It works, thank you Ben.

But I find that there are many spaces at the head of the HDD serial number, how can I eliminate these spaces?

(imported comment written by BenKus)

Hey wazty,

Glad it works… if there are only preceding spaces (and not trailing spaces), then try this:

(if exists substring " " of it then (following text of last " " of it) else it) of string values of selects “SerialNumber from Win32_PhysicalMedia” of wmi

Ben

(imported comment written by wazty200291)

It works fine, thank you very much.