Skip to content

Instantly share code, notes, and snippets.

@msis
Last active February 4, 2018 22:54
Show Gist options
  • Save msis/196d3b8838256cc9e5593d90a9d9af2a to your computer and use it in GitHub Desktop.
Save msis/196d3b8838256cc9e5593d90a9d9af2a to your computer and use it in GitHub Desktop.
[snap on lxc error] Running snap inside a lxc container errors. #lxc #snap #squash #squashfuse

When running snap inside lxc container, snap install might fail with the following output for :

$ systemctl status snap-core-2898.mount
● snap-core-2898.mount - Mount unit for core
   Loaded: loaded (/etc/systemd/system/snap-core-2898.mount; enabled; vendor preset: enabled)
   Active: failed (Result: exit-code) since Tue 2017-09-26 15:36:39 UTC; 26s ago
    Where: /snap/core/2898
     What: /var/lib/snapd/snaps/core_2898.snap
  Process: 608 ExecMount=/bin/mount /var/lib/snapd/snaps/core_2898.snap /snap/core/2898 -t sq

Sep 26 15:36:39 mosh-snapcraft systemd[1]: Mounting Mount unit for core...
Sep 26 15:36:39 mosh-snapcraft mount[608]: mount: /snap/core/2898: mount failed: Unknown erro
Sep 26 15:36:39 mosh-snapcraft systemd[1]: snap-core-2898.mount: Mount process exited, code=e
Sep 26 15:36:39 mosh-snapcraft systemd[1]: Failed to mount Mount unit for core.
Sep 26 15:36:39 mosh-snapcraft systemd[1]: snap-core-2898.mount: Unit entered failed state.

This is caused by a missing package squashfuse. Installing this package solves the issue:

apt update && apt install squashfuse
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment