You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We have Linux server which have two physical CPUs, how to get processor ids of both two?
CentralProcessor.getProcessorID() is returning a wrong value, I read the source code looks the value is generated by createProcessorID.
I manual run dmidecode -t system it didn't contain Processor Information, but dmidecode -t processor does:
Handle 0x0094, DMI type 4, 48 bytes
Processor Information
Socket Designation: SOCKET 0
Type: Central Processor
Family: Xeon
Manufacturer: Intel
ID: XX XX XX XX XX XX XX XX
...
Handle 0x0098, DMI type 4, 48 bytes
Processor Information
Socket Designation: SOCKET 1
Type: Central Processor
Family: Xeon
Manufacturer: Intel
ID: XX XX XX XX XX XX XX XX
...
Hi, @atealxt . Sorry for the delay in working on this.
You correctly pointed out that we used the wrong dmidecode type for this query. It should be 4 (processor) rather than 1 (system). (Plus root permissions.) That will be fixed in #480 in less than a minute.
As for the multiple physical CPUs, I'm going to say no on that temporarily.
I would expect in most cases where there are two physical cpu packages, they likely share the same processor id (which simply encodes the stepping, model, family, and flags). Since you've obfuscated your CPUIDs I can't tell whether your two processors had different IDs.
That said, #418 requests data that must be per-package or per-core and it's entirely reasonable to include (possibly different) processor IDs when that's implemented. So I'll make a note on that Issue and track the multi-package implementation there. Note that probably will be part of a 4.0.0 rewrite which is at some undetermined pointe in the future, so if you want it earlier you'll have to get involved to help. :)
Activity
dbwiddis commentedon Apr 18, 2018
Hi, @atealxt . Sorry for the delay in working on this.
You correctly pointed out that we used the wrong
dmidecodetype for this query. It should be 4 (processor) rather than 1 (system). (Plus root permissions.) That will be fixed in #480 in less than a minute.As for the multiple physical CPUs, I'm going to say no on that temporarily.
I would expect in most cases where there are two physical cpu packages, they likely share the same processor id (which simply encodes the stepping, model, family, and flags). Since you've obfuscated your CPUIDs I can't tell whether your two processors had different IDs.
That said, #418 requests data that must be per-package or per-core and it's entirely reasonable to include (possibly different) processor IDs when that's implemented. So I'll make a note on that Issue and track the multi-package implementation there. Note that probably will be part of a 4.0.0 rewrite which is at some undetermined pointe in the future, so if you want it earlier you'll have to get involved to help. :)