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

Increase Stat() buffer size #547

Merged
merged 1 commit into from
Jul 10, 2023
Merged

Increase Stat() buffer size #547

merged 1 commit into from
Jul 10, 2023

Conversation

SuperQ
Copy link
Member

@SuperQ SuperQ commented Jul 10, 2023

Increase the /proc/stat scanner tokens size from the default of 65k to 1024k. This allows for scanning of large intr lines with > 65k columns.

  • Increase the scanner buffer from the default 4kB to 8kB bytes at a time.

Fixes: #546

Copy link
Member

@discordianfish discordianfish left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Increase the /proc/stat scanner tokens size from the default of 65k to
1024k. This allows for scanning of large `intr` lines with > 65k
columns.
* Increase the scanner buffer from the default 4kB to 8kB bytes at a time.

Fixes: #546

Signed-off-by: SuperQ <superq@gmail.com>
@SuperQ SuperQ merged commit 4b2218e into master Jul 10, 2023
@SuperQ SuperQ deleted the superq/stat_buffer branch July 10, 2023 10:46
jritter pushed a commit to jritter/procfs that referenced this pull request Jul 15, 2024
Increase the /proc/stat scanner tokens size from the default of 65k to
1024k. This allows for scanning of large `intr` lines with > 65k
columns.
* Increase the scanner buffer from the default 4kB to 8kB bytes at a time.

Fixes: prometheus#546

Signed-off-by: SuperQ <superq@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Couldn't parse \"/proc/stat\": bufio.Scanner: token too long
2 participants