[collectd-changes] collectd, the system statistics collection daemon: Changes to 'mc/openvpn'

Florian Forster octo at verplant.org
Fri Sep 25 12:14:51 CEST 2009


New branch 'mc/openvpn' available with the following commits:
commit 23a2bcc3161b53c86208eee7cfdfe2e47a92b3a0
Author: Florian Forster <octo at leeloo.lan.home.verplant.org>
Date:   Fri Sep 25 12:14:11 2009 +0200

    collectd.conf(5): openvpn plugin: Document the "Compression" option.

commit de1e2a768511a63d09e6546afe3d93eaed894b46
Author: Florian Forster <octo at leeloo.lan.home.verplant.org>
Date:   Fri Sep 25 12:11:45 2009 +0200

    AUTHORS: Update Marco's entry.

commit 43f7aab563f215ae349d2af5875ad78c93840c00
Author: Florian Forster <octo at leeloo.lan.home.verplant.org>
Date:   Fri Sep 25 12:10:10 2009 +0200

    openvpn plugin: single_read: Remove one level of indentation.

commit 40a142cd5e5a4e0fd01e32877e0ed73dc8ad191b
Author: Florian Forster <octo at leeloo.lan.home.verplant.org>
Date:   Fri Sep 25 11:58:50 2009 +0200

    openvpn plugin: Use tabs for indentation only.
    
    Whitespace-only commit.

commit d0b50fe4f1a4082f261bdccc9806a9e3b846dd42
Author: Florian Forster <octo at leeloo.lan.home.verplant.org>
Date:   Fri Sep 25 11:49:45 2009 +0200

    openvpn plugin: multi1_read: Replace a hard to read for-loop with a while-loop.

commit 795b23995cb6ca0e0facbc088861437304de1b7b
Author: Florian Forster <octo at leeloo.lan.home.verplant.org>
Date:   Fri Sep 25 11:39:02 2009 +0200

    openvpn plugin: Improve “version_detect”.
    
    Remove “fscanf” with used the insecure “%s” format string. Pass the
    filename rather than the file handle to the function.

commit 5043359b0d21e074b319ff7c961312c6cf8b9885
Author: Florian Forster <octo at leeloo.lan.home.verplant.org>
Date:   Fri Sep 25 09:28:11 2009 +0200

    openvpn plugin: Remove trailing whitespace.

commit 427150df64d4c1401121d91686cf326e80c7e682
Author: Florian Forster <octo at leeloo.lan.home.verplant.org>
Date:   Fri Sep 25 09:27:50 2009 +0200

    openvpn plugin: Don't use negated config options.
    
    “NoCompression” → “Compression”.

commit 0e88144b00dd44516f187953f8c10e1d365846fa
Author: Marco Chiappero <marco at absence.it>
Date:   Fri Sep 25 09:20:56 2009 +0200

    openvpn plugin: Add forgotten frees.
    Florian Forster ha scritto:
    > Hi Marco,
    
    Hi Florian,
    
    > I'm too tired to have a look at this now, I hope to have some time in
    > the next few days. I'll come back to you asap.
    
    That's fine :)
    But sorry, I forgot to recheck a small part of the code after adding and
    moving some stuff around, please apply this patch too.
    
    Regards,
    Marco

commit 72174f6da21dd809e870d1bc7cab6ac5793e2c70
Author: Marco Chiappero <marco at absence.it>
Date:   Fri Sep 25 09:18:02 2009 +0200

    openvpn plugin: Add support for more versions of the “status file” (and more).
    
    Hi all,
    
    I have some news regarding the Openvpn plugin.
    I recently upgraded to 4.7.2 and enabled the new (to me) openvpn plugin,
    but unfortunately it didn't work and I couldn't understand why. So had a
    look at the code and applied some changes. Here a list of things
    added:
    
    - support for multiple vpn/status files
    - support for single endpoint status file and for multicontext version
    1,3 (currently every status file type is supported)
    - status file type auto-detection
    - collection of overhead and compression stats for single mode status files
    - "NoCompression" option to disable compression statistics collection
    - new file naming schema correcting the previous wrong one
    - debug and error output
    
    The plugin has already been tested with my own openvpn setup and many
    different files found on the net, but two major aspects have to be taken
    into consideration. The first one is the new overhead collection and the
    change in the compression statistics (now data is stored as they are
    [1]). However, due to a bug in the previous code, no compression
    collection was working and so the new one is not going to brake backward
    compatibility. Unfortunately backward compatibility is broken by the
    new naming schema, more collectd compliant (and necessary with multiple
    conf/status files support). So plugin_istance is now the status file
    name (or the status entry number), while the plugin_type is now the
    hostname when in multicontext mode or the traffic and overhead when in
    single.
    About the plugin_instance value, I started using numbers like the cpu
    plugin does, but I prefer to use the self explanatory file name, helping
    in finding the right vpn and avoiding to mess things up when adding a
    new status file. The downside is that filenames have to be unique (man
    pages should mention this [2]), therefore I added a check. Nonetheless I
    think it's very unlikely to happen, it is quite rare to find many vpn on
    the same system and it's really hard to have the same log filename
    stored in different dirs rather than the opposite; usually to different
    tunnels should already correspond different status log name.
    However, Florian, feel free to choose the other method if you prefer, I
    can send you a patch to revert to the number based schema.
    Hope you like the code.
    
    Regards,
    Marco
    
    [1] This allows to retrieve multiple informations, not just the pure
    compression ratio. For example we can now calculate the pure compression
    ratio, the global compression level, the byte saved (eg. for a
    overhead vs. saved bytes graph) and so on.
    
    [2] Man pages should be updated as well, but I haven't written anything yet.




More information about the collectd-changes mailing list