Skip to content

Commit

Permalink
update installation documentation files
Browse files Browse the repository at this point in the history
  • Loading branch information
sflow committed Oct 25, 2016
1 parent 3088ce0 commit 4c79bd3
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 42 deletions.
25 changes: 7 additions & 18 deletions INSTALL.Docker
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ http://sflow.net/license.html
Compile/install
===============

root> make DOCKER=yes PCAP=yes
root> make FEATURES="DOCKER PCAP"
root> make install

Edit /etc/hsflowd.conf for configuration, then:
Expand All @@ -29,30 +29,19 @@ pcap { dev = docker0 }

so that the traffic to and from the docker containers is
monitored with sFlow. Alternatively, if Open VSwitch is running,
then starting sflowovsd will propagate sFlow configuration to
the v-switch via ovs-vsctl(1):
adding:

root> service sflowovsd start
ovs { }

Debugging
=========
To run in the debugger, compile with:

root> make DOCKER=yes PCAP=yes OPT=-g

and run with the "-d" or "-dd" command line option to
prevent daemonization and increase logging:

root> gdb hsflowd
gdb> set args -dd
gdb> r
will propagate your collector and sampling-rate information
to the switch via ovs-vsctl(1).

Packaging
=========
To build an rpm, try:

% make DOCKER=yes PCAP=yes rpm
% make rpm FEATURES="DOCKER PCAP"

To build a Debian package, try:

% make DOCKER=yes PCAP=yes deb
% make deb FEATURES="DOCKER PCAP"
3 changes: 1 addition & 2 deletions INSTALL.KVM
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,7 @@ Red Hat KVM Hypervisor

To compile for a Red Hat KVM hypervisor:

DDK> export LIBVIRT=yes
DDK> make rpm
% make rpm FEATURES="KVM"

The rpm will be written to /usr/src/redhat/RPMS/<ARCH>/
(where <ARCH> is i386 or x86_64 or ...)
Expand Down
41 changes: 19 additions & 22 deletions INSTALL.Linux
Original file line number Diff line number Diff line change
Expand Up @@ -3,20 +3,17 @@ http://sflow.net/license.html

To compile and install, try this:

% make
% make FEATURES="ALL"
% sudo make install
% sudo make schedule

To compile features that can be enabled in the config:

% make FEATURES="ALL"

Or you can specify them individually:
Features can be specified individually:

% make FEATURES="ULOG NFLOG PCAP DOCKER KVM OVS"
% make FEATURES="ULOG NFLOG PCAP DOCKER KVM OVS TCP"

Edit /etc/hsflowd.conf for configuration. The options are
described in the comments there.
described here:
http://sflow.net/host-sflow-linux-config.php

Module dependencies var from platform to platform, but
the following packages usually have to be installed before
Expand All @@ -34,31 +31,31 @@ To start the daemon, run:

and check the syslog for errors.

To run in the debugger, change the Makefile to compile with -g,
recompile, and then run with the "-dd" command line option to
prevent daemonization:
To run in the debugger, first recompile like this:
% make clean
% make FEATURES="ALL" OPT=-g
% sudo make install

and then run with the "-dd" command line option to
prevent daemonization and increase the logging level:

% sudo gdb hsflowd
gdb> set args -dd
gdb> r

For more detailed logging, using -ddd or -dddd.

To build an rpm from a git repo, try:
To build an rpm, try:

% make rpm FEATURES="..."

To build an rpm from a sources tarball hsflowd-<ver>.tar.gz,
copy the tarball to your rpm SOURCES directory then run:

% rpmbuild -ba hsflowd.spec --define _FEATURES "..."

The rpm will be written to /usr/src/redhat/RPMS/<ARCH>/
(where <ARCH> is i386 or x86_64 or ...)

To build a Debian package, try:

% make deb FEATURES="..."

The hsflowd-<version>-<release>.deb package should appear
in the current directory.
And to use Docker to compile natively on other platforms (if required)
you can try:

% sudo ./docker_build_on <platform>

Where <platform> is a directory under ./docker_build/

0 comments on commit 4c79bd3

Please sign in to comment.