forked from sflow/host-sflow
-
Notifications
You must be signed in to change notification settings - Fork 0
/
INSTALL.XenServer
113 lines (84 loc) · 3.06 KB
/
INSTALL.XenServer
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
This software is distributed under the following license:
http://sflow.net/license.html
Citrix XenServer
================
For XenServer we build a .iso image. If you need
to build it from sources, then there are two
ways. The easier one is to use Docker:
./docker_build_on xenserver
This might be slow the first time, but once it has
constructed and cached the container image then it
will build much faster thereafter. If that works,
or you were able to download a pre-built .iso file,
you can jump straight to the step where you
transfer the .iso package to the hypervisor below
(see INSTALLING .ISO PACKAGE below)
Otherwise, you should follow the Citrix instructions
to download and install the DDK as a new VM on your
hypervisor, and then compile the .iso package there.
For XenServer 7.0 you will need to follow these
three extra steps to prepare the DDK:
(1) enable yum repo /etc/yum.repos.d/CentOS-Base
* - substitute "7" for $releasever everwhere
* - change "enabled=0" to "enabled=1" for each repo
* - uncomment base URL for each repo
(2) download XenServer Developement Packages (binpkg.iso)
and mount somewhere that is URL accessible, then
add a new repo file for it. For example, on a
Linux server with httpd at 10.0.0.23 I ran:
mkdir /var/www/html/binpkg
mount -o loop XenServer-7.0.0-binpkg.iso /var/www/html/binpkg
Then added /etc/yum.repos.d/xen.repo with:
[binpkg]
name=CitrixXenServer7
enabled=1
baseurl=http://10.0.0.23/binpkg
gpgcheck=0
(3) install the extra packages:
yum install xen-libs-devel xen-dom0-libs-devel dbus-devel
Now compile with:
DDK> make xenserver
The Xenserver .iso will now be accessible as
xenserver-ddk/hsflowd-xenserver.iso.
INSTALLING .ISO PACKAGE
=======================
To install, copy it to the XenServer dom0 and run these commands:
mkdir /tmp/iso
mount -o loop hsflowd-xenserver.iso /tmp/iso
cd /tmp/iso
./install
cd
umount /tmp/iso
EDITING /etc/hsflowd.conf
=========================
(1) VM Monitoring
To monitor VMs as well as the hypervisor itself, make sure
/etc/hsflowd.conf has this line:
xen {}
(2) Open vSwitch
If Open VSwitch is running (it is the default virtual switch
in XenServer 6.0 and later), then make sure /etc/hsflowd.conf
has the line:
ovs {}
to enable the OVS module. This will propagate sFlow configuration
from hsflowd to the switch via ovs-vsctl(1). This in turn will
turn on standard sFlow monitoring of all the traffic through
the virtual switch, providing L2-L7 visibility into the traffic
patterns (including MAC, VLAN, ARP, FCoE, IPv4, IPv6, TCP, UDP
and ICMP) as well as providing a feed of standard interface-counter
data for every virtual port on the switch.
(3) DBUS agent
If you include a line:
dbus{}
then hsflowd will install a simple DBUS agent that can report
basic stats (see telemetry scripts in src/Linux/scripts).
STARTING HSFLOWD
================
Now start the daemon. On XenServer 7.0 or later, run:
systemctl daemon-reload
systemctl enable hsflowd
systemctl start hsflowd
Otherwise, run:
chkconfig --add hsflowd
service hsflowd start
Output will go to /var/log/messages.