IssueRaiser

nix-env uses a ton of memory

## Issue description nix-env uses so much memory that it fails on allocation when querying packages; far more than should be for a simple package manager. ### Steps to reproduce On a system with 2gb or less: [demo@nixos:~]$ nix-env -qa GC Warning: Out of memory - trying to allocate requested amount (336 bytes)... GC Warning: Header allocation failed: dropping block GC Warning: Failed to expand heap by 8388608 bytes GC Warning: Failed to expand heap by 65536 bytes GC Warning: Out of Memory! Heap size: 736 MiB. Returning NULL! error: out of memory ## Technical details Please run `nix-shell -p nix-info --run "nix-info -m"` and paste the results. - system: `"x86_64-linux"` - host os: `Linux 4.14.32, NixOS, 18.03.131807.489a14add9a (Impala)` - multi-user?: `yes` - sandbox: `no` - version: `nix-env (Nix) 2.0

Posted by kstenerud on Apr 9, 2018, 7:56 AM

Tags

Related issues

Raise real-world problems, find people facing the same issue, and discuss solutions.4,000 issues0 comments

github (Sysadmin)

nix-env uses a ton of memory

kstenerudApr 9, 2018, 7:56 AM

## Issue description nix-env uses so much memory that it fails on allocation when querying packages; far more than should be for a simple package manager. ### Steps to reproduce On a system with 2gb or less: [demo@nixos:~]$ nix-env -qa GC Warning: Out of memory - trying to allocate requested amount (336 bytes)... GC Warning: Header allocation failed: dropping block GC Warning: Failed to expand heap by 8388608 bytes GC Warning: Failed to expand heap by 65536 bytes GC Warning: Out of Memory! Heap size: 736 MiB. Returning NULL! error: out of memory ## Technical details Please run `nix-shell -p nix-info --run "nix-info -m"` and paste the results. - system: `"x86_64-linux"` - host os: `Linux 4.14.32, NixOS, 18.03.131807.489a14add9a (Impala)` - multi-user?: `yes` - sandbox: `no` - version: `nix-env (Nix) 2.0

Comments (0)

No comments yet. Start the discussion.

Comment on this issue