TORRUS_CONFIGSNAPSHOT(8)
π TORRUS_CONFIGSNAPSHOT(8) π
okay bestie, welcome to the torrus section 8 manual, and specifically the configsnapshot page. this one's a whole vibe and honestly kind of a lifesaver, so grab a strawberry drink and let's go π
β¨ NAME β¨
configsnapshot β Generates a configuration snapshot for a Torrus tree.
β¨ SYNOPSIS β¨
torrus configsnapshot --tree=TREENAME [options...]
β¨ DESCRIPTION β¨
so basically this command takes your current datasources and generates a configuration snapshot for tree TREENAME. the output? an XML file, ready for compilation, representing all datasources, monitors and tokensets of a given tree. periodt.
lowkey important deets: the snapshot does not include view definitions. templates and file patterns get expanded inside the file. and it doesn't need any other XML config files β except for defaults.xml and your custom view definitions. that's it, that's the whole shopping list ποΈ
β οΈ warning bestie, listen up:"configsnapshot"from RRFW release 0.1.5 will not work correctly with databases from previous releases. use RRFW release"0.1.4bf2"instead. and heads up β the"configsnapshot"utility from RRFW release0.1.4bf2does not preserve aliases. pick your fighter, know the tradeoffs π
this utility is useful in the Torrus upgrade process. in case when RRD files structure is changing in Torrus default templates, and user(s) demand to preserve the historical data, the following steps could be done:
- Stop the collector and monitor processes.
- Install newest Torrus software and do not run
"compilexml"immediately. - Create snapshots of the trees that you want to preserve for historical reasons:
torrus configsnapshot --tree=myrouters \
--out=/etc/torrus/xmlconfig/myrouters-snapshot.xml
- If needed, move the existing RRD files into different directory. Then change the
"data-dir"parameters in the snapshot XML accordingly. - Create a new tree with only the snapshot file in it. Compile the tree.
- At this stage, it is up to the user to decide whether to continue running the collector and monitor daemons for this new tree. The old data may be preserved for historical reference, and collector may be run with the newest tree structure and definitions.
like, that's the whole glow-up arc for your historical data π¦ main character energy fr fr
β¨ OPTIONS β¨
--tree=TREEβ Mandatory parameter specifying the tree name. mandatory mandatory, no skipping π--out=FILEβ Sets the output file to FILE. Default issnapshot.xml.--param=PARAM--value=VALUEβ Sets the filter on datasource leaves that have to be included in the snapshot. PARAM specifies the name of the datasource parameter, and VALUE sets the matching value. By default the numeric comparison is performed.--op=OPERATORβ Sets the fiter comparison operator. Accepted values:=(numeric),eq(text string comparison), andre(regular expression match). Default is numeric comparison. (yes the original says "fiter", we keep it, it's iconic π)--verboseβ Displays some extra information.--helpβ Displays a help message.
β¨ FILES β¨
/usr/share/torrus/xmlconfig/defaults.xmlβ XML configuration file with default settings for the datasources and tokensets, as well as default view definitions.snapshot.xmlβ Default configsnapshot output file.
β¨ SEE ALSO β¨
torrus(8), torrus_compilexml(8)
β¨ NOTES β¨
See more documentation at Torrus home page: http://torrus.org π
β¨ AUTHOR β¨
Stanislav Sinyagin <ssinyagin@k-open.com> π
and that's a wrap on the torrus 3.00 version of this page, dated 2023-05-02, from the TORRUS_CONFIGSNAPSHOT(8) era π go snapshot those trees bestie, you got this β¨π
π¦ where this page comes from
- debian bookworm: torrus-common 3.00-2
- debian trixie: torrus-common 3.00-2
- ubuntu noble: torrus-common 3.00-2
- ubuntu questing: torrus-common 3.00-2
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms