[SERVER-62183] Support for hostInfo.cpuFrequencyMHz on Graviton Created: 20/Dec/21  Updated: 06/Dec/22

Status: Backlog
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Bug Priority: Major - P3
Reporter: Alex Podelko (Inactive) Assignee: Backlog - Service Architecture
Resolution: Unresolved Votes: 0
Labels: sa-remove-fv-backlog-22
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
Assigned Teams:
Service Arch
Operating System: ALL
Participants:

 Description   

hostInfo doesn't show cpuFrequencyMHz (and some other processor-related information) on Graviton:

"cpuFrequencyMHz" : "",
"cpuFeatures" : "",



 Comments   
Comment by Kelsey Schubert [ 07/Jun/22 ]

I don't think it's particularly urgent. cc bruce.lucas@mongodb.com

Comment by Alex Podelko (Inactive) [ 20/Dec/21 ]

lauren.lewis We are not getting all information about server physical configuration and this info would be missed everywhere we provide it (diagnostic files/tools, etc.).

Comment by Lauren Lewis (Inactive) [ 20/Dec/21 ]

alex.podelko can you provide more information around the impact of this issue?

cc: shameek.ray

Comment by Alex Podelko (Inactive) [ 20/Dec/21 ]

AWS response on reporting ARM frequency information:

Unfortunately Arm64 Linux has made a choice not to share the cpu frequency in /proc/cpuinfo. We place it in dmi data (e.g. `sudo dmidecode`) and you can get it via perf (e.g. ` sudo perf stat -e cpu-clock,cycles ..`) as long as that core isn’t sleeping.

Comment by Alex Podelko (Inactive) [ 20/Dec/21 ]

It looks like that info is not reported by Graviton processors the same was as it is reported by Intel processors - and output between commands is rather inconsistent:

[ec2-user@ip-10-2-0-100 ~]$ cat /proc/cpuinfo
processor : 0
BogoMIPS : 243.75
Features : fp asimd evtstrm aes pmull sha1 sha2 crc32 atomics fphp asimdhp cpuid asimdrdm lrcpc dcpop asimddp ssbs
CPU implementer : 0x41
CPU architecture: 8
CPU variant : 0x3
CPU part : 0xd0c
CPU revision : 1
...

[ec2-user@ip-10-2-0-100 ~]$ lscpu
Architecture: aarch64
Byte Order: Little Endian
CPU(s): 16
On-line CPU(s) list: 0-15
Thread(s) per core: 1
Core(s) per socket: 16
Socket(s): 1
NUMA node(s): 1
Model: 1
BogoMIPS: 243.75
L1d cache: 64K
L1i cache: 64K
L2 cache: 1024K
L3 cache: 32768K
NUMA node0 CPU(s): 0-15
Flags: fp asimd evtstrm aes pmull sha1 sha2 crc32 atomics fphp asimdhp cpuid asimdrdm lrcpc dcpop asimddp ssbs

[ec2-user@ip-10-2-0-100 ~]$ sudo dmidecode --type processor

dmidecode 3.0
Getting SMBIOS data from sysfs.
SMBIOS 2.7 present.
Handle 0x0004, DMI type 4, 42 bytes
Processor Information
Socket Designation: CPU00
Type: Central Processor
Family: <OUT OF SPEC>
Manufacturer: AWS
ID: C1 D0 3F 41 00 00 00 00
Version: AWS Graviton2
Voltage: Unknown
External Clock: Unknown
Max Speed: 2500 MHz
Current Speed: 2500 MHz
Status: Populated, Enabled
Upgrade: None
L1 Cache Handle: Not Provided
L2 Cache Handle: Not Provided
L3 Cache Handle: Not Provided
Serial Number: AWS Graviton2
Asset Tag: AWS Graviton2
Part Number: AWS Graviton2
Core Count: 16
Core Enabled: 16
Thread Count: 16
Characteristics: None

Comment by Alex Podelko (Inactive) [ 20/Dec/21 ]

Copying from STAR-2344 (more details there):

rs0:PRIMARY> db.hostInfo()
{
"system" :

{ "currentTime" : ISODate("2021-11-03T20:13:59.682Z"), "hostname" : "ip-10-2-0-100.ec2.internal", "cpuAddrSize" : 64, "memSizeMB" : NumberLong(63202), "memLimitMB" : NumberLong(63202), "numCores" : 16, "cpuArch" : "aarch64", "numaEnabled" : false }

,
"os" :

{ "type" : "Linux", "name" : "Amazon Linux release 2 (Karoo)", "version" : "Kernel 4.14.232-177.418.amzn2.aarch64" }

,
"extra" : {
"versionString" : "Linux version 4.14.232-177.418.amzn2.aarch64 (mockbuild@ip-10-0-1-185) (gcc version 7.3.1 20180712 (Red Hat 7.3.1-13) (GCC)) #1 SMP Tue Jun 15 20:58:11 UTC 2021",
"libcVersion" : "2.26",
"kernelVersion" : "4.14.232-177.418.amzn2.aarch64",
"cpuFrequencyMHz" : "",
"cpuFeatures" : "",
"pageSize" : NumberLong(4096),
"numPages" : 16179806,
"maxOpenFiles" : 65535,
"physicalCores" : 1,
"mountInfo" : [

{ "mountId" : 19, "parentId" : 41, "major" : 0, "minor" : 19, "root" : "/", "mountPoint" : "/sys", "options" : "rw,nosuid,nodev,noexec,relatime", "fields" : "shared:6", "type" : "sysfs", "source" : "sysfs", "superOpt" : "rw" }
Generated at Thu Feb 08 05:54:24 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.