Learn about the Wavefront OpenBSD Host Integration.

OpenBSD Host Integration

OpenBSD is a free and open-source Unix-like operating system. Monitoring OpenBSD hosts is easy with Wavefront. This integration steps you through installing and configuring the Wavefront proxy and Collectd. Collectd is a Unix daemon capable of collecting, processing, aggregating, and sending metrics to a Wavefront proxy in Graphite data format.

In addition to setting up the metrics flow, this integration also installs a dashboard. Here are the Summary and CPU sections of a dashboard displaying OpenBSD host metrics.


OpenBSD Host Setup

Step 1: Install and Configure the Wavefront Proxy Manually

  1. Create a directory wavefront-proxy and change the directory:
    mkdir wavefront-proxy
    cd wavefront-proxy
  2. Download the Wavefront proxy jar:
    curl -o proxy-uber.jar https://wavefront-cdn.s3-us-west-2.amazonaws.com/bsd/proxy-uber.jar
  3. Create a directory conf and download the wavefront.conf, log4j2.xml and preprocessor_rules.yaml files into the conf directory:
    mkdir conf
    curl -o ./conf/wavefront.conf https://wavefront-cdn.s3-us-west-2.amazonaws.com/bsd/wavefront.conf
    curl -o ./conf/log4j2.xml https://raw.githubusercontent.com/wavefrontHQ/wavefront-proxy/master/pkg/etc/wavefront/wavefront-proxy/log4j2.xml.default
    curl -o ./conf/preprocessor_rules.yaml https://raw.githubusercontent.com/wavefrontHQ/wavefront-proxy/master/pkg/etc/wavefront/wavefront-proxy/preprocessor_rules.yaml.default
  4. Open the conf/wavefront.conf file for edit, add the following proxy properties:
    server = https://YOUR_CLUSTER.wavefront.com/api/
    token = YOUR_API_TOKEN
    hostname = "HOSTNAME"
    graphitePorts = 2003
    graphiteFormat = 2
    graphiteDelimiters = _
  5. Start the Wavefront proxy service:
    java -XX:OnOutOfMemoryError="kill -1 %p" \
    -Dlog4j.configurationFile=./conf/log4j2.xml -Djava.util.logging.manager=org.apache.logging.log4j.jul.LogManager \
    -Djavax.net.debug=summary -jar ./proxy-uber.jar \
    -f conf/wavefront.conf \
    --preprocessorConfigFile ./conf/preprocessor_rules.yaml &


    • If Java is not installed, run pkg install openjdk8 to install jdk and set the path.
    • If the proxy fails to start with an Error requesting exclusive access to the buffer lock file, execute the below command and start the proxy (Step 5)
       mkdir -p /var/spool/wavefront-proxy
  6. Verify that the proxy has registered with the Wavefront server.

Step 2: Install and Configure the Collectd Daemon Manually

  1. Run the command pkg_add -v collectd to install the Collectd package.
  2. Open the /etc/collectd.conf file for edit, add the following information, and save the file.
    # Global settings for the daemon.
    Hostname    "HOSTNAME"
    FQDNLookup   true
    BaseDir     "/var/collectd"
    PIDFile     "/var/collectd/collectd.pid"
    PluginDir   "/usr/local/lib/collectd"
    TypesDB     "/usr/local/share/collectd/types.db"
    # When enabled, plugins are loaded automatically with the default options.
    AutoLoadPlugin true
    # Enable logging
    <Plugin logfile>
         LogLevel info
         File "/var/log/collectd.log"
         Timestamp true
         PrintSeverity false
    # Enable cpu input plugin
    <Plugin cpu>
        ReportByCpu true
        ReportByState true
        ValuesPercentage true
        ReportNumCpu true
    # Enable df input plugin
    <Plugin df>
        MountPoint "/"
        ReportByDevice true
        ReportInodes true
        ValuesAbsolute true
        ValuesPercentage true
    # Enable disk input plugin
    <Plugin disk>
    # Enable interface input plugin
    <Plugin interface>
    # Enable load input plugin
    <Plugin load>
        ReportRelative true
    # Enable memory input plugin
    <Plugin memory>
        ValuesAbsolute true
        ValuesPercentage true
    # Enable processes input plugin
    <Plugin processes>
        CollectContextSwitch true
    # Enable swap input plugin
    <Plugin swap>
        ValuesAbsolute true
        ValuesPercentage true
    # Enable uptime input plugin
    <Plugin uptime>
    # Enable users input plugin
    <Plugin users>
    # Enable graphite output plugin
    <Plugin write_graphite>
       <Node "HOSTNAME">
           Port "2003"
           Protocol "tcp"
           ReconnectInterval 10
           LogSendErrors true
           Prefix "openbsd."
           StoreRates false
           AlwaysAppendDS false
           EscapeCharacter "_"
           SeparateInstances true
  3. Restart the Collectd daemon by running the following command: /etc/rc.d/collectd restart