RECAPTOOL(8)

✨ RECAPTOOL ✨

okay bestie, so this is recaptool, section 8 of the System Manager's Manual β€” it's giving sysadmin, it's giving log-archaeology, it's giving let me read your recap logs and tell you the vibes πŸ’…


🌸 NAME 🌸

recaptool β€” parses the logs and prints specific information about memory, processes, network connections or queries to a mysql db. no cap, that's literally the whole job description 🫢


πŸŽ€ SYNOPSIS πŸŽ€

recaptool OPTIONS...

πŸ¦‹ DESCRIPTION πŸ¦‹

recaptool is a parsing tool for recap logs that shows specific information like processes, memory, network or querycount. it's lowkey iconic for spotting trends on a particular option in the logs β€” like, you wanna see how something's been moving over time? this is the girl for the job. periodt. ✨


πŸ’… OPTIONS πŸ’…

Note: Different options can be combined to get more information. mix and match, bestie, she ate that πŸ’–
  • -m, --mem PROCESS_NAME β€” shows the memory consumption for PROCESS_NAME from the logs. how much RAM is she eating? we're finding out πŸ“
  • -p, --proc PROCESS_NAME β€” shows the amount of processes found for PROCESS_NAME from the logs. like a headcount but for processes 🧚
  • -b, --memproc PROCESS_NAME β€” shows both process count and memory consumption for PROCESS_NAME from the logs. it's giving two-for-one, it's giving combo meal πŸ‘‘
  • -c, --connections PORT β€” shows the amount of connections to PORT from the logs πŸ”₯
  • -e, --established PORT β€” shows the amount of ESTABLISHED connections to PORT from the logs. established, as in they're officially in a relationship, no situationships here 😭
  • -q, --querycount β€” shows the amount of mysql connections from the logs. database girlies rise 🫢
  • -d, --path PATH β€” overrides the recap log PATH. the default uses BASEDIR /var/log/recap/ (and yes, that can be changed in the config file β€” she's flexible like that) πŸ’œ
  • -V, --version β€” print version and exit. just a lil flex πŸ’…
  • -h, --help β€” prints the help information and exit. when in doubt, ask for help, that's main character energy 🌈

🌈 FILES 🌈

  • /var/log/recap/*.log (unless overridden by the path option)

⭐ EXAMPLES ⭐

okay so here's where it gets fun, watch her work 🎬

show the memory and amount of processes running for httpd:

$ sudo recaptool --memproc http
Information: Using /var/log/recap as recap log path
Information: Executing memproc http
2016-10-07_00:00:01     1101    3032.535 M
2016-10-07_00:10:01     1120    3132.832 M
2016-10-07_00:20:01     1128    3186.153 M

show the amount of established connections on port 443:

$ sudo recaptool -e 443
Information: Using /var/log/recap as recap log path
Information: Executing established 443
2016-10-07_00:00:01     302
2016-10-07_00:10:01     311
2016-10-07_00:20:01     312

show the amount of query connections to the mysql db:

$ sudo recaptool --querycount
Information: Using /var/log/recap as recap log path
Information: Executing querycount
2016-10-07_00:00:01     124
2016-10-07_00:10:01     125
2016-10-07_00:20:01     128

show all of the above in a single command:

$ sudo recaptool --memproc http -e 443 --querycount
Information: Using /var/log/recap as recap log path
Information: Executing memproc http
2016-10-07_00:00:01     1101    3032.535 M
2016-10-07_00:10:01     1120    3132.832 M
2016-10-07_00:20:01     1128    3186.153 M

Information: Executing established 443
2016-10-07_00:00:01     302
2016-10-07_00:10:01     311
2016-10-07_00:20:01     312

Information: Executing querycount
2016-10-07_00:00:01     124
2016-10-07_00:10:01     125
2016-10-07_00:20:01     128
one command, three whole answers. she's efficient, she's organized, she's the moment πŸ’–

😭 REPORTING BUGS 😭

found a bug? not the vibe, but okay, we handle it. bugs and issues are to be submitted via github at <https://github.com/rackerlabs/recap/issues>. go tell the devs bestie, they wanna know 🫢


πŸ‘‘ AUTHOR πŸ‘‘

the recap scripts are maintained by Rackspace, and the list of contributors is available at <https://github.com/rackerlabs/recap/blob/master/CHANGELOG.md#contributors>. legends only, honestly 🌟


🧚 SEE ALSO 🧚


and that's the whole page, bestie β€” this one's dated Aug 18, 2017, straight outta the System Manager's Manual, RECAPTOOL(8) era. go parse some logs and slay πŸ’…βœ¨