SANLK-RESET(8)

πŸ’– SANLK-RESET(8) β€” the host reset program, bestie edition πŸ’–

okay so you're looking at sanlk-reset, from the System Manager's Manual, and it is exactly what it sounds like: a whole program whose entire job is resetting hosts. dramatic? yes. iconic? also yes. let's get into it 🫢


✨ SYNOPSIS ✨

sanlk-reset [OPTIONS] action lockspace_name ...

that's the shape of it: some options, an action, and then one or more lockspace names. slay.


🌸 DESCRIPTION 🌸

so what does this thing actually do. The sanlk-reset program sets events in specified sanlock lockspaces. and those events aren't just vibes β€” they're literally defined to cause sanlk-resetd on another host to:

  • use wdmd/watchdog to reset the host
  • use /proc/sysrq-trigger to reboot the host
⚠️ heads up bestie, this is the "make another machine stop existing" part. it's supposed to be dramatic, that's the whole point.

Both hosts must be operational and have continued access to a common lockspace for the reset request to succeed. no ghosting the lockspace, no reset. 😭 After setting the event, the sanlk-reset program monitors the host status in the sanlock lockspace until the target host is dead. like it watches. until it's done. main character energy fr fr.

The sanlk-reset program can also be run on the same host as sanlk-resetd to update which lockspaces the local sanlk-resetd is watching for events. so it's both "reset someone else" and "adjust my own to-do list", versatile queen πŸ’…


πŸŽ€ OPTIONS πŸŽ€

  • --version, -V β€” print version. that's it, that's the whole thing ✨
  • --help, -h β€” print usage. when in doubt, ask for help, we love a queen who asks 🫢

πŸ”₯ Reset another host πŸ”₯

The event is set in each lockspace specified. and pls note: the target host may have a different host id in each lockspace. so don't assume one id fits all, okay?

sanlk-reset reset lockspace_name:host_id ...
  • --host-id, -i num β€” Host id to reset. (Use only with single lockspace name.) ⭐
  • --generation, -g num β€” Generation of host. (Use only with single lockspace name.) ⭐
  • --sysrq-reboot, -b 0|1 β€” Enable/Disable (1/0) use of /proc/sysrq-trigger to reboot. πŸ’€
  • --resource-mode, -R 0|1 β€” Resource leases are used (1) or not used (0) to protect storage.
  • --native-timeout, -t num β€” Disable native timeout by setting to 0. set it to zero and it's gone, periodt.
πŸ’‘ little note bestie: --host-id/-i and --generation/-g are only for when you've got a single lockspace name in play. don't try to be cute and use them with a whole list.

πŸ¦‹ Update the local sanlk-resetd πŸ¦‹

so this is the other mode. same program, different vibe check:

to watch new lockspaces for reset events:

sanlk-reset reg lockspace_name ...

to not watch lockspaces for reset events:

sanlk-reset end lockspace_name ...

to clear all lockspaces being watched:

sanlk-reset clear all

reg, end, clear β€” reg to add, end to remove, clear to wipe the whole watch list. no cap. 🌈


πŸ’œ SEE ALSO πŸ’œ

go read those too, they're all part of the same friend group 🧚


okay that's the whole page! this one came from the System Manager's Manual, dated 2014-08-14, and it's the SANLK-RESET(8) page, so you know exactly what you're reading. stay safe, don't reset anyone you don't mean to reset, and remember: both hosts have to actually be operational for any of this to work. bye bestie, ily πŸ“πŸ’–βœ¨