-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Out of memory on package installation #421
Comments
The evaluation can be expensive, especially for |
NixOS now has about 3500 packages, while Gentoo has about 20000. So, when NixOS will have such amount of packages, will it consume 6 GB memory? |
No, everyone will just use -iA from the very beginning… |
NixOS has ~14k packages. And yes, it's memory intensive. As said, we're aiming for |
What is destiny of such functionality if nobody uses it? First you made evaluation of all packages, then you do not use it. Nice 😎 |
Currently the package attribute names slowly converge to their package names; initially Nix language didn't allow attributes named |
You can tell Nix to garbage-collect more aggressively:
With this, nix-env -qa takes 235 MB on my laptop. (Without it, 471 MB.) You can also do:
That should make the fork error go away. |
@edolstra |
I think we should close this issue or wait when nix won't use such amount of memory. |
Because I have the same problem on 1GB of memory. |
As a note for future readers: this happended for me on Hyper-V too, and the suggested overcommit_memory tweak fixed it for me. I assume a change like below in
|
Simple "nix-env -i" is slow and runs out of memory on old computers. NixOS/nix#421
Simple "nix-env -i" is slow and runs out of memory on old computers. NixOS/nix#421
Sometimes on
nix-env -i pkgname
I have such error:There is 1Gb RAM on VirtualBox instance. Is 1Gb memory amount not enough for nix? Any plans to reduce a memory consumption?
The text was updated successfully, but these errors were encountered: