snap-discard-ns(5)
β¨ NAME β¨
okay so bestie, let me put you on to snap-discard-ns β it's an internal tool for discarding preserved namespaces of snappy applications π
(yes, that's the whole vibe of the snap-discard-ns(5) page, and we're gonna get into it)
π SYNOPSIS π
snap-discard-ns [--snap-already-locked|--from-snap-confine]
SNAP_INSTANCE_NAME
πΈ DESCRIPTION πΈ
So snap-discard-ns is a program that snapd uses internally β like, it's not out here for the general public, it's giving backstage crew energy π§ β and what it does is discard a preserved mount namespace of a particular snap. That's it. That's the job. Slay.
π OPTIONS π
--snap-already-lockedβ this one says "hey, the snap lock has already been taken," andsnap-discard-nswill verify that internally, bestie. no cap, it checks π--from-snap-confineβ this is literally an alias for the option above βοΈ, but it's used only internally, specifically whensnap-confineis the one callingsnap-discard-ns. iykyk.
π¦ ENVIRONMENT π¦
snap-discard-ns responds to the following environment variables:
SNAP_CONFINE_DEBUGβ when this is defined, the program will print additional diagnostic information about the actions being performed. and where does all that output go? π all of it goes tostderr. every last crumb. periodt.
π FILES π
snap-discard-ns uses the following files, so let's get into it:
/run/snapd/ns/$SNAP_INSTNACE_NAME.mnt/run/snapd/ns/$SNAP_INSTNACE_NAME.*.mntβ this is the preserved mount namespace that gets unmounted and removed bysnap-discard-ns. the second form (the one with the*in it) is for the per-user mount namespace π«Ά/run/snapd/ns/snap.$SNAP_INSTNACE_NAME.fstab/run/snapd/ns/snap.$SNAP_INSTNACE_NAME.*.user-fstabβ and these are the current mount profile of a preserved mount namespace, which also gets removed bysnap-discard-ns. iconic cleanup behaviour fr fr π§Ήβ¨
π BUGS π
found something broken? π please report all bugs with:
https://bugs.launchpad.net/snapd/+filebug
π Author π
zygmunt.krynicki@canonical.com β yeah, they ate that π
πΈ Copyright πΈ
Canonical Ltd. β protect the brand bestie π«Ά
and that's the whole page!! this came from snappy 2.36, dated 2018-10-17, and it's the snap-discard-ns(5) manual β mwah, go forth and discard those namespaces responsibly πβ¨π
π¦ where this page comes from
- fedora 44: snap-confine 2.77.1-0.fc44 Β· GPL-3.0-only
- ubuntu resolute: snapd 2.74.1+ubuntu26.04.4 Β· GPL-3.0-only
- ubuntu resolute: snapd 2.76+ubuntu26.04.3 Β· GPL-3.0-only
- ubuntu resolute: snapd 2.76.3+ubuntu26.04
- ubuntu resolute: snapd 2.77.1+ubuntu26.04.2 Β· GPL-3.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms