Skip to content

nix install on linux can fail with "cloning builder process: Operation not permitted" #1030

@simonmichael

Description

@simonmichael

The nix command for installing hledger, on the download page, can fail with an error like:

cloning builder process: Operation not permitted

since nix requires some kernel permission that GNU/Linux distros may not grant by default (NixOS/nix#2633). The workaround is to run a command similar to:

sudo sysctl kernel.unprivileged_userns_clone=1

before running nix-env.

Is it safe to leave this permission enabled ? https://security.stackexchange.com/questions/209529/what-does-enabling-kernel-unprivileged-userns-clone-do thinks not. So maybe you should disable it again after running nix-env:

sudo sysctl kernel.unprivileged_userns_clone=0

This all seems pretty lame, presumably nix will fix eventually.

Metadata

Metadata

Assignees

No one assigned

    Labels

    docsDocumentation-related.packagingDependencies, version constraints, packaging..platform-nix

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions