diff options
| author | Paul Buetow (mars.fritz.box) <paul@buetow.org> | 2014-03-02 13:31:56 +0100 |
|---|---|---|
| committer | Paul Buetow (mars.fritz.box) <paul@buetow.org> | 2014-03-02 13:31:56 +0100 |
| commit | a647d21b81115ef6a81b5644936b725a9aa3bb8e (patch) | |
| tree | eef72bbae11fc3fad70dad004ccbabfb134921d2 /docs/guprecords.pod | |
| parent | da03c49e263ad9562253a01217e2fe5166c97d98 (diff) | |
initial working release
Diffstat (limited to 'docs/guprecords.pod')
| -rw-r--r-- | docs/guprecords.pod | 114 |
1 files changed, 34 insertions, 80 deletions
diff --git a/docs/guprecords.pod b/docs/guprecords.pod index 29ff2bd..951936a 100644 --- a/docs/guprecords.pod +++ b/docs/guprecords.pod @@ -1,116 +1,70 @@ =head1 NAME -guprecords - A template project +guprecords - Global uptime records -=head1 WTF? +Shows uprecord stats of several hosts at once. -You may use this project in order to build your own Debian package for your own project. This has been tested with Debian GNU/Linux Squeeze and Debian GNU/Linux Wheezy. +=head2 Synopsis -Feel free to modify any aspects. This project is just an empty example guprecords. +guprecords [--help] [--total|--all] [--count=i] [--indir=s] -Follow these steps: +=head2 Parameters -=head2 Install required packages +=over -Run the following: +=item --help - sudo aptitude install lintian devscripts dpkg-dev make perl +Shows the help -Todo: Ensure this are the correct packages. In order to test that I would have to setup a blank Debian system. +=item --total -=head2 Compile the project +Aggregates a total uptime for every single host. -Go to the to level directory and run +=item --all - make +Shows every individual uptime of all hosts. -To test run +=item --count=i - ./bin/guprecords +Show i num of entries. Default is 23. -It should print out the version number of the project. +=item --indir=s -=head2 Create a Debian package +Read all the *.records files from dir s. Default is ./ -Go to the to level directory and run +=back - make deb -It will create the files like: +=head2 Quick getting started - ../guprecords_0.0.0.0_all.deb - ../guprecords_0.0.0.0.dsc - ../guprecords_0.0.0.0_amd64.changes - ../guprecords_0.0.0.0.tar.gz +=head3 Uptimed -It should create a debian package in ../. Check and install it, e.g: +Firstival, you need to collect uprecords using the uptimed deaemon. To install it run: - lintian --pedantic ../guprecords_0.0.0.0_all.deb - sudo dpkg -i ../guprecords_0.0.0.0_all.deb + sudo aptitude install uptimed -Run +Please consult the L<uptimed> and L<uprecords> manpages. Please ensure to understand how it works and what it does. - dpkg -L guprecords +uptimed collects uprecords to -to see whats in there. You can now run + /var/spool/uptimed/records - /usr/bin/guprecords +And this file is used by guprecords for further processing. -or for example +=head3 Collect all the uprecords - man guprecords +You may have several hosts with uptimed running already. Collect all the records file to a central repository (e.g. git). Name each file FQDN.records and run -=head2 Read the Makefile + guprecords --indir ./ -Read the Makefile in order to understand what's going on. +You may automate the collecting of all the uprecords using something like cron or puppet. -=head1 Customize +=head1 LICENSE -Now, since you understood everything feel free to customize everything the way you want it. E.g.: +Se package description or project website. - Don't use POD for documentation but LaTeX +=head1 AUTHOR - Compile a C program +Paul Buetow - <http://guprecords.buetow.org> - Include a ./lib dir, add it to the 'install' Makefile rule - - etc etc. - -You should also consider the following: - -=head2 Manual page - -This template is using POD for creating manual pages. Edit ./docs/guprecords.pod and run - - make documentation - -in order to build ./docs/guprecords.1. The page will be included in the resulting debian package automatically. You can review the page with - - man ./docs/guprecords.1 - -=head2 Renaming guprecords into your project name - -Rename all files which have *guprecords* included into your own new package name. You can do that with: - - PROJECTNAME=yourproject - find . -name \*guprecords\* | - while read guprecords; do git mv $guprecords ${guprecords/guprecords/$PROJECTNAME}; done - -Search all content and rename *guprecords* into your own new package name. You can do that with: - - grep -R guprecords . | grep -v .git | - cut -d: -f1 | uniq | xargs sed -i "s/guprecords/$PROJECTNAME/g" - -=head2 Updating ./debian - -Edit the following files accordingly to your new project (e.g. with vim): - - ./debian/control - ./debian/copyright - ./debian/README - -=head2 Update changelog - -Go to the to level directory and run - - dch -i +=cut |
