CSVINFO.CGI(1)
π CSVINFO.CGI(1) π
okay bestie, welcome to the General Commands Manual era, this one's about csvinfo.cgi and it's actually so useful, no cap π«Ά
β¨ NAME β¨
csvinfo.cgi β a CGI program that shows you host information pulled straight out of a CSV file π
πΈ SYNOPSIS πΈ
csvinfo.cgi
that's it. that's the whole synopsis. she's lowkey minimal π
π¦ DESCRIPTION π¦
so csvinfo.cgi doesn't get called directly β she gets invoked as a CGI script through the csvinfo.sh CGI wrapper, okay? that's her whole entrance. π«
based on the parameters she receives, she goes and searches a comma-separated file for the host that matches, and then presents all the info she found as a table. it's giving organized. it's giving neat. β¨
csvinfo.cgi gets handed a QUERY_STRING environment variable with these parameters in it:
keyβ the string to search for, typically the hostname πcolumnβ the column number to search, default is0dbβ the name of the CSV database file, living in$XYMONHOME/etc/, default ishostinfo.csvdelimiterβ the delimiter character for columns, default is the semi-colon
CSV files are genuinely so easy to make, like you can just take a spreadsheet and export it in CSV format and boom, you're done. π you should have one host per line, and the first line should hold the column headings. and here's the plot twist: despite the whole "comma-separated" name situation, the default delimiter for CSV files is actually the semi-colon. so if you need a different delimiter, you invoke csvinfo.cgi with "delimiter=<character>" in the query string. periodt. π
π Example usage π
this example shows how you can use the csvinfo CGI. it assumes you've got a CSV-formatted file with info about the hosts stored as $XYMONHOME/etc/hostinfo.csv, and that the hostname is chillin' in the first column of the file. π
β Use with the xymongen --docurl
the --docurl option to xymongen(1) sets up all of the hostnames on your Xymon webpages so they act as links to a CGI script. iconic behavior honestly. π«Ά
to invoke the csvinfo CGI script, you run xymongen with this option:
--docurl=/cgi-bin/csvinfo.sh?db=hostinfo.csv&key=%s
π SEE ALSO π
hosts.cfg(5), xymonserver.cfg(5), xymongen(1)
and that's the whole page bestie, you ate that reading session fr fr π this was Xymon, Version 4.3.30, dated 4 Sep 2019 β go forth and slay those host lookups ππ
π¦ where this page comes from
- debian bookworm: xymon 4.3.30-1+b2 Β· GPL-2.0-only WITH OpenSSL exception
- debian trixie: xymon 4.3.30-4 Β· GPL-2.0-only WITH OpenSSL exception
- ubuntu jammy: xymon 4.3.30-1build2 Β· GPL-2.0-only WITH OpenSSL exception
- ubuntu jammy: xymon 4.3.30-1ubuntu0.1 Β· GPL-2.0-only WITH OpenSSL exception
- ubuntu noble: xymon 4.3.30-2build3 Β· GPL-2.0-only WITH OpenSSL exception
- ubuntu noble: xymon 4.3.30-2ubuntu0.1 Β· GPL-2.0-only WITH OpenSSL exception
- ubuntu questing: xymon 4.3.30-4
- ubuntu resolute: xymon 4.3.30-5 Β· GPL-2.0-only WITH OpenSSL exception
- ubuntu stonking: xymon 4.3.30-6 Β· GPL-2.0-only WITH OpenSSL exception
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms