[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [hobbit] Antwort: RE: [hobbit] Howto delete abandoned datafiles



On Wed, Feb 25, 2009 at 04:50:25PM +0100, thorsten.erdmann (at) daimler.com wrote:
> No. I export the data from our inventory and simply regenerate the bbhosts 
> files. So old hosts simply are missing in the new bbhosts files. So I 
> don't know which hosts were deleted. Therefore I would need to store the 
> old export file and compare it to the new one to find the differences and 
> use the "drop host" command. I find that very complicated. 

"bbhostshow" lists the full bb-hosts file, with all of the includes
done. Or you can query the hobbitd daemon with
   bb 127.0.0.1 "hobbitdboard test=info fields=hostname"
to get a list of the currently known hosts.

Matching that against the directory names in ~hobbit/data/rrd/ would be
fairly trivial, and then you can use the 
   bb 127.0.0.1 "drop HOSTNAME"
to completely cleanup those hosts that no longer exist.


Regards,
Henrik