swift-recon(1)

πŸ’– swift-recon β€” the manual, but make it make sense πŸ’–

okay bestie, sit down, hydrate, and let me tell you about swift-recon, aka the OpenStack Swift recon middleware cli tool. yes it's a mouthful. yes it's iconic. this is the page for section 1 of the manual, so buckle up πŸŽ€


✨ NAME ✨

swift-recon β€” OpenStack Swift recon middleware cli tool πŸ¦‹


🌸 SYNOPSIS 🌸

like, here's the whole vibe in one block:

swift-recon  <server_type> [-v] [--suppress] [-a] [-r] [-u] [-d] [-l]
[-T] [--md5] [--auditor] [--updater] [--expirer] [--sockstat]

copy it exactly, no cap, every bracket matters πŸ’…


πŸ‘‘ DESCRIPTION πŸ‘‘

so the swift-recon cli tool is literally the girl who goes and retrieves various metrics and telemetry information about a cluster that has been collected by the swift-recon middleware. she's the messenger. she's the main character. she does not generate the data, she just shows up with receipts ✨

and here's the tea: if you actually wanna use the swift-recon middleware, you gotta update the object-server.conf file and enable the recon middleware by adding a pipeline entry and setting its option(s). the example section below has the details, so don't skip it, i'm watching 🫢


πŸ’… OPTIONS πŸ’…

every single one, in order, no skipping. this is a full send.

  • <server_type> β€” your options are account | container | object. if you don't say anything it just Defaults to object server. she picks for you, she's confident like that πŸ’
  • -h, --help β€” shows this help message and then dips. exit. gone. 😌
  • -v, --verbose β€” print verbose information, aka she tells you everything. oversharing as a service πŸ—£οΈ
  • --suppress β€” suppress most connection related errors. we're keeping it chill, we're not gonna spiral over every little hiccup πŸ™ˆ
  • -a, --async β€” get async stats πŸ“Š
  • --auditor β€” get auditor stats πŸ”
  • --updater β€” get updater stats πŸ”„
  • --expirer β€” get expirer stats ⏳
  • -r, --replication β€” get replication stats πŸͺž
  • -R, --reconstruction β€” get reconstruction stats 🧩
  • -u, --unmounted β€” check the cluster for unmounted devices 🚨
  • -d, --diskusage β€” get disk usage stats πŸ’Ύ
  • --top=COUNT β€” also show the top COUNT entries in rank order. leaderboard behavior, we love a ranking πŸ†
  • --lowest=COUNT β€” also show the lowest COUNT entries in rank order. someone's gotta be at the bottom, and we're gonna name names πŸ“‰
  • --human-readable β€” use human readable suffix for disk usage stats. numbers that actually fit in your brain, thank god 🧠
  • -l, --loadstats β€” get cluster load average stats βš–οΈ
  • -q, --quarantined β€” get cluster quarantine stats 🦠
  • --validate-servers β€” validate servers on the ring βœ…
  • --md5 β€” get md5sum of servers ring and compare to local copy. checksum girlies rise πŸ”
  • --sockstat β€” get cluster socket usage stats 🧦
  • --driveaudit β€” get drive audit error stats πŸ”Ž
  • -T, --time β€” check time synchronization ⏰
  • --swift-versions β€” check swift version 🏷️
  • --all β€” perform all checks. and it's equivalent to -arudlqT --md5 --sockstat --auditor --updater --expirer --driveaudit --validate-servers --swift-versions. that's the whole menu, the whole platter, the entire vibe ✨
  • --region=REGION β€” only query servers in specified region πŸ—ΊοΈ
  • -z ZONE, --zone=ZONE β€” only query servers in specified zone 🎯
  • -t SECONDS, --timeout=SECONDS β€” time to wait for a response from a server. patience is a virtue but it is also a finite resource ⏱️
  • --swiftdir=PATH β€” Default = /etc/swift πŸ“

🌈 EXAMPLE 🌈

here's her in her natural habitat, serving looks:

ubuntu:~$ swift-recon -q --zone 3
=================================================================
[2011-10-18 19:36:00] Checking quarantine dirs on 1 hosts...
[Quarantined objects] low: 4, high: 4, avg: 4, total: 4
[Quarantined accounts] low: 0, high: 0, avg: 0, total: 0
[Quarantined containers] low: 0, high: 0, avg: 0, total: 0
=================================================================

and then, finally β€” the way that you'd also wanna track asynchronous pending's β€” you will need to setup a cronjob to run the swift-recon-cron script periodically:

*/5 * * * * swift /usr/bin/swift-recon-cron /etc/swift/object-server.conf

that's the cron line. every 5 minutes. she's punctual. she has a schedule. she's booked and busy πŸ’…


πŸ“š DOCUMENTATION πŸ“š

more documentation about OpenStack Swift can be found at https://docs.openstack.org/swift/latest/

also, more specific documentation about swift-recon can be found at https://docs.openstack.org/swift/latest/admin_guide.html

go read. i'll wait. bestie homework πŸ“–βœ¨


🫢 SEE ALSO 🫢

object-server.conf(5), β€” yes she's the one you gotta edit, we already said it, but the cross-reference is right there 🌸


okay that's the whole page!! this one was Linux, 8/26/2011, and it's filed under swift-recon(1) if you ever need to find her again. go forth, run your checks, and remember: rank order is a love language πŸŽ€πŸ’– bye bestie!!