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

Ram loss in vfs when accessing rump fs #3983

Closed
Cochimetl opened this issue Jan 12, 2021 · 7 comments
Closed

Ram loss in vfs when accessing rump fs #3983

Cochimetl opened this issue Jan 12, 2021 · 7 comments

Comments

@Cochimetl
Copy link
Contributor

When reading many large files from a rump ext2fs fs, vfs demands more RAM.
It seems the used RAM increases in large portions (~2M stepts) in repos/dde_rump/src/lib/vfs/rump/vfs_rump.cc line 134 in a rump_sys_pread call.

This was observed under 20.08.

@Cochimetl
Copy link
Contributor Author

Quadrupled amount of files read, needed RAM never went above 16M despite having needed 12M beforehand. So it's probably ok?

@chelmuth
Copy link
Member

@ssumpf @cnuke do you have any thoughts about this?

@ssumpf
Copy link
Member

ssumpf commented Jan 13, 2021

@Cochimetl: The back end allocator in repos/dde_rump/src/include/util/allocator_fap.h will allocate 2MB chunks on demand (which are super pages on x86_64) until VM_SIZE or RAM quota is reached in case it runs out of memory. VM_SIZE is 256MB on 32 bit and 4GB on 64 bit systems.

@nfeske
Copy link
Member

nfeske commented Jan 25, 2021

I wonder, what is the state of this issue? Is it resolved by @ssumpf's comment, or is there the need for further steps?

I think that the stated upper limit of 256 MiB is rather high. E.g., the limit is certainly not anticipated by Sculpt OS, which assigns merely 64 MiB to the file-system server. On the other hand, I haven't run into the reported issue myself. It would be really nice to have an artificial work load to reproduce the greedy behavior.

@cnuke
Copy link
Member

cnuke commented Jan 25, 2021

@nfeske in Sculpt the amount of memory rump is supposed to consume is limited by setting the ram attribute to 48 MiB and it should stay below this limit. The VM_SIZE is the theoretical maximum rump can consume if not limited. So if rump_set_memlimit, which is used to enfource this limit, works as intended we should be fine.

@nfeske
Copy link
Member

nfeske commented Jan 26, 2021

@cnuke Thanks for dispelling my worries. ;-)

This leaves only the question of how to go about this issue?

@Cochimetl I wonder, are you using the ram attribute mentioned by @cnuke already?

@Cochimetl
Copy link
Contributor Author

Ram attribute was used and set to 7M. This fits the observed behaviour (three increases of 2M).
Thanks for the help and the explanations.

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

No branches or pull requests

5 participants