unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
* guix --container is RAM hungry
@ 2024-03-21 21:44 Edouard Klein
  2024-03-25  9:27 ` raingloom
  2024-03-28 23:30 ` Ludovic Courtès
  0 siblings, 2 replies; 7+ messages in thread
From: Edouard Klein @ 2024-03-21 21:44 UTC (permalink / raw)
  To: guix-devel

Dear Guixers,

I'm a huge fan of guix --container, and I created a system to use those
by default for network services. But the VPS these services run on has
only 2GB of RAM, and I just realized that a container, by default,
requires at least 200MB.

Try it:
guix shell time which -- bash -c "$(which time) -v guix shell
--container"

Then Ctrl-D, and look for this line:
	Maximum resident set size (kbytes): 291300

291MB of RAM to run bash.


By contrast, removing the --container option from above yields:
	Maximum resident set size (kbytes): 64496

64MB, still a lot, but I can live with that.

I tried various calls to unshare, but got no significant increase of
RAM.

From an outsider's point of view, the --container option is a wrapper
for unshare, and the dependency resolution is done by guix shell with
or without the --container option, so I don't understand where the RAM
explosion come from.
I mean no implication that '--container' is simple or trivial to
implement, I just wrestled with namespaces for a few weeks and I know
they're a pain, to stay polite. I'm thankful for the tool and would like
to use it more, but I can't in its current state.


Any ideas ?

Thanks in advance,

Edouard.


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2024-04-10 14:03 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-03-21 21:44 guix --container is RAM hungry Edouard Klein
2024-03-25  9:27 ` raingloom
2024-03-26 20:37   ` Ricardo Wurmus
2024-03-28 23:30 ` Ludovic Courtès
2024-03-30  2:33   ` Maxim Cournoyer
2024-04-02 20:33     ` Edouard Klein
2024-04-10 14:02       ` Ludovic Courtès

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).