STASADM(1)
π STASADM(1) β the stasadm manual, but make it make sense
okay bestie, sit down, we're learning stasadm from the STASADM(1) manual page and honestly? it's giving β¨storage appliance services adminβ¨ and I'm obsessed. this is the glow-up version, same facts, way better vibes π
β¨ NAME β¨
stasadm β STorage Appliance Services admin functions π«Ά
πΈ SYNOPSIS πΈ
stasadm [OPTIONS...] {COMMAND} [OPTIONS...]
π DESCRIPTION π
so stasadm is the lil tool you use to configure nvme-stas. and where does all that config go? it gets saved to /etc/stas/sys.conf. periodt π
now here's the cute part β even though nvme-stas keeps its config in /etc/stas/sys.conf, you can still vibe with the config from nvme-cli and libnvme, no drama. nvme-stas lets you save individual parameters like the Host NQN and ID somewhere outside of /etc/stas/sys.conf. like, for example?? you could use the same default Host NQN and ID that nvme-cli and libnvme define in /etc/nvme/hostnqn and /etc/nvme/hostid respectively. iconic tbh π
and how do you tell nvme-stas that's what you want? you just use stasadm's --file=FILE option. that's it. that's the whole trick π¦
π COMMANDS π
here's what this baby understands:
hostnqnβ generates the Host NQN β¨ this is typically used as a post-installation step to generate/etc/nvme/hostnqn.
and listen, the NVMe base specifications says: βAn NQN is permanent for the lifetime of the hostβ. for this reason, the host NQN should only be generated if /etc/nvme/hostnqn does not exist already. no take-backs, bestie π
hostidβ generates the Host ID β¨ typically used as a post-installation step to generate/etc/nvme/hostid.
now, it's not explicitly specified in the NVMe specifications, but the Host ID, like the Host NQN, should be permanent for the lifetime of the host. so only generate the Host ID if /etc/nvme/hostid does not exist. same energy, same rule π
set-symname [SYMNAME]β sets the host symbolic name π
the symbolic name is an optional parameter that can be used for explicit registration with a discovery controller. optional but slay π
clear-symnameβ clears the host symbolic name. bye bye π
π OPTIONS π
here's what this baby understands:
-h,--helpβ prints the help text and exits. your lil safety net π«Ά--versionβ prints the version string and exits. iykyk β-fFILE,--file=FILEβ by default,hostnqnandhostidsave the values to/etc/stas/sys.conf. this option lets you save to a separate file instead π¦
traditionally, nvme-cli and libnvme retrieve the default Host NQN and ID from /etc/nvme/hostnqn and /etc/nvme/hostid respectively. so the --file=FILE option can be used to tell nvme-stas that it should use those same configuration files. matching outfits fr fr π
π₯ EXIT STATUS π₯
on success, 0 is returned; otherwise, a non-zero failure code is returned. bestie either ate or she didn't π
π EXAMPLES π
Example 1. Generate /etc/nvme/hostnqn
$ stasadm hostnqn --file /etc/nvme/hostnqn
Example 2. Generate /etc/nvme/hostid
$ stasadm hostid -f /etc/nvme/hostid
Example 3. Configure the host's symbolic name
$ stasadm set-symname LukeSkywalker
π§ SEE ALSO π§
nvme-stas(7)β go read it, bestie, it's the prequel β¨
and that's the whole page, no notes π
this was nvme-stas 2.4.1, the STASADM(1) manual, and honestly? she ate. go generate those permanent IDs responsibly, mwah πππΈ
π¦ where this page comes from
- ubuntu resolute: nvme-stas 2.4.1-3build1 Β· Apache-2.0
- ubuntu stonking: nvme-stas 2.4.1-3build1 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms