Hi!
I am using vSphere perl API for monitoring datastores inside cacti monitoring system.
Every 5 minutes I ask vCenter for capacity and free space of all datastores in datacenter.
| Code Snipet |
|---|
$log->info("saving datastore data"); my $datastores = $dc_view->datastore;
my $dslog = Log::Log4perl->get_logger("DATASTORE"); foreach my $ds (@{$datastores}){ my $datastore = Vim::get_view(mo_ref => $ds); if( $datastore->summary->accessible ){ my $ds_name = $datastore->summary->name; my $logstr = sprintf("Name = %-13s Capacity = %9.3f GB Free = %9.3f GB Type=%-10s", $ds_name, $datastore->summary->capacity / $Gbyte, $datastore->summary->freeSpace / $Gbyte, $datastore->summary->type); $dslog->trace($logstr);
if($datastore->info->url =~ /volumes\/(.+)\/$/){ $ds_dataset_ref->{$1}{name} = $ds_name; $ds_dataset_ref->{$1}{typeFS} = $datastore->summary->type; $ds_dataset_ref->{$1}{capacity} = $datastore->summary->capacity; $ds_dataset_ref->{$1}{freeSpace} = $datastore->summary->freeSpace; $ds_dataset_ref->{$1}{url} = $datastore->info->url; } } } |
I have the problem of having some false alarms triggered.
Above we have graph made inside cacti monitoring system and graph seen in vCenter perfromance tab. The correlation is obvious but there are differences seen - we see that by the way how I save the data in cacti,
I get more alarms. And compered to vSphere graph we can say that they are false alarms.In "purple" area I get a spike that should not be and as well in yellow area.
My question is, would anybody know what could be the reason for this?
