Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

report: fix typos in memory limit units #56068

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

technic960183
Copy link

Replace typos "kbytes" with "bytes" in PrintSystemInformation() in src/node_report.cc for "data_seg_size_kbytes", "max_memory_size_kbytes" and "virtual_memory_kbytes", as RLIMIT_DATA, RLIMIT_RSS and RLIMIT_AS from <sys/resource.h> are given in bytes. (ref)

I found this problem when I was testing the limit of virtual memory. When I set it to 32GB, the report showed

"virtual_memory_kbytes": {
  "soft": 34359738368,
  "hard": 34359738368
}

After checking the source codes, I think that it should be in bytes, not kbytes.

Refs: https://www.ibm.com/docs/en/aix/7.3?topic=k-kgetrlimit64-kernel-service

Replace "kbytes" with "bytes" in `PrintSystemInformation()` in
`src/node_report.cc`, as RLIMIT_DATA, RLIMIT_RSS, and RLIMIT_AS are
given in bytes.

Refs: https://www.ibm.com/docs/en/aix/7.3?topic=k-kgetrlimit64-kernel-service
@nodejs-github-bot nodejs-github-bot added c++ Issues and PRs that require attention from people who are familiar with C++. needs-ci PRs that need a full CI run. report Issues and PRs related to process.report. labels Nov 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c++ Issues and PRs that require attention from people who are familiar with C++. needs-ci PRs that need a full CI run. report Issues and PRs related to process.report.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants