<br><br><div class="gmail_quote">On Tue, Jul 28, 2009 at 4:42 PM, Mahendra Kutare <span dir="ltr"><<a href="mailto:mahendra.kutare@gmail.com">mahendra.kutare@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="im"><br><div class="gmail_quote">On Tue, Jul 28, 2009 at 4:08 PM, Mariusz Gronczewski <span dir="ltr"><<a href="mailto:xani666@gmail.com" target="_blank">xani666@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hi,<br>
<div>> I am wondering if I have to build libvirt from source along with collectd to<br>
> make this work ? Or is there a way to make it work from RPM installation of<br>
> collectd and libvirt ?<br>
><br>
</div>Do u have libvirt-dev in repo ? Thats enougth to build libvirt plugin<br>
in collectd<br>
<br>
</blockquote></div><br></div>Well I found couple of things which I was missing -<br>
<br>
1. I yum installed <b>collectd-virt</b> which puts collectd version of libvirt.so in my Plugin directory. <br>
This was not there earlier with installation <b>yum install collectd </b>and I would have to install libvirt-devel as mentioned below and then compile collectd from source. <br>
<br>
So this way I just <b>yum install collectd-virt</b> which for now makes it work for me. I believe it takes care of libvirt-devel even if I did not had it earlier installed.<br><br>
Now I have libvirt installed and getting the metrics but the problem I have now is it gets me only CPU metrics by default.<br>
<br>I want to atleast have 2-4 metrics - CPU, Memory, Network and Disk. How do I add these to be fetched from libvirt through collectd ?<br><br>I do not see any options for that in - <br><br>162 <Plugin libvirt><br>
163 Connection "xen:///"<br>164 # RefreshInterval 60<br>165 # Domain "name"<br>166 # BlockDevice "name:device"<br>167 # InterfaceDevice "name:device"<br>168 # IgnoreSelected false<br>
169 HostnameFormat name<br>170 </Plugin><br><br>Do I just uncomment BlockDevice and InterfaceDevice for Disk and Network ? What about memory ?<br></blockquote><div><br>Since I mentioned I was able to get the libvirt working with collectd .. It also requires me to start libvirt daemon and then start collectd ..<br>
For now I am able to get only CPU statistics..but even then I see after a while libvirt deamon just dissappears and no longer running -<br><br>[root@samoa2 ~ 10:07 PM]$ /etc/init.d/libvirtd status<br>libvirtd is stopped<br>
[root@samoa2 ~ 10:07 PM]$ <br><br>but if I do tail on libvirt cpu statistics its still gettings the stats and so I am wondering how is this statistics getting collected by COLLECTD if libvirt daemon is no longer running.<br>
<br>[root@samoa2 ~ 10:07 PM]$ tail -f /var/lib/collectd/csv/Domain-0/libvirt/virt_cpu_total-2009-07-28 <br>1248833348,19386749.000000<br>1248833349,54430218.000000<br>1248833350,11854492.000000<br>1248833351,148050572.000000<br>
1248833352,32229078.000000<br>1248833353,24888903.000000<br>1248833354,15100561.000000<br>1248833355,16550331.000000<br>1248833356,76380175.000000<br>1248833357,25201017.000000<br>1248833358,7488821.000000<br><br>So any idea how is this working and still generating stats ?? Does collectd does require libvirt daemon only for starting libvirt plugin and there on it does not ?<br>
<br>Thanks<br>Mahendra<br> <br></div></div><br>