alloc_ns(9)
π alloc_ns(9) π
okay bestie, welcome to the Kernel API Manual page for alloc_ns. This entry is lowkey iconic β it's giving "allocate, initialize and return a new namespace" energy, and we are keeping every detail exactly where it belongs. no cap. β¨
β¨ NAME β¨
alloc_ns β does exactly what it says on the tin: allocate, initialize and return a new namespace. periodt. π
π¦ SYNOPSIS π¦
struct aa_ns * alloc_ns (const char *prefix , const char *name );
π ARGUMENTS π
prefixβ parent namespace name (MAYBE NULL). so yeah, it's allowed to beNULL, but only maybe. πnameβ a preallocated name (NOT NULL). this one is not optional, bestie β no sneakyNULLname energy here. π«Ά
π₯ RETURN π₯
Hands you back a refcounted namespace, or NULL on failure. slay when it works, NULL when it doesn't. π
π SEE ALSO π
Kernel file ./security/apparmor/policy_ns.c, plus the whole SEE ALSO friend group:
aa_ns_visible(9)aa_ns_name(9)aa_free_ns(9)__aa_lookupn_ns(9)aa_lookupn_ns(9)__aa_find_or_create_ns(9)aa_prepare_ns(9)destroy_ns(9)__aa_remove_ns(9)__ns_list_release(9)aa_alloc_root_ns(9)
mwah π that's the whole page, bestie. It comes from ./security/apparmor, dated October 2026, and the manual page is alloc_ns(9). πΈ
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms