Downed Device Detection issue...

Post general support questions here that do not specifically fall into the Linux or Windows categories.

Moderators: Developers, Moderators

Post Reply
gasperazzo
Posts: 29
Joined: Wed Oct 08, 2008 11:51 am

Downed Device Detection issue...

Post by gasperazzo »

Hellow all...

So... I installed cacti 0.8.7.d into an Ubuntu 9.0.4 box. Then i install wmic-client to queries windows servers with wmi.

When I add a windows box to cacti and create the graphs for this host I recived an error that the rra file wans`t created.

I found the problem, but not ways to resolve it.

The problem is about the Downed Device Detection method. I`m not able to install snmp service in the production windows servers. So i need to query that servers using wmi. Because this, I cannot use the SNMP method.. Ill need to use PING or PING OR SNMP method....

If I specify the SNMP Downed Device Detection, the graph is created. But if i select anyone other method, the graph ins`t created.

It looks like that cacti don't query this host.

Anyone have a fix?
User avatar
BSOD2600
Cacti Moderator
Posts: 12171
Joined: Sat May 08, 2004 12:44 pm
Location: USA

Post by BSOD2600 »

When using the ping, what ping type are you using? Does the windows box respond to the type of ping you're using? Look in the cacti.log why the box failed the ping.
User avatar
TheWitness
Developer
Posts: 17004
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

BSOD2600,

This looks like a first good project:

1) Add WMI ping to Ping Options. (lib/ping.php, include/global_arrays.php, include/global_constants.php)
2) Integrate Generic WMI as an official Data Input Method
3) Now wouldn't it be nice to have a WMI Module for PHP. Would make things very simple.

TheWitness

$sp = wmi_connect(host, user, password, domain);
$array = wmi_fetch_assoc($sp, $select_statement);
$array = wmi_fetch_row($sp, $select_statement);
$value = wmi_fetch_cell($sp, $select_statement);
$bool = wmi_disconnect($sp);

optionally:

$boolean = wmi_set_value($sp, $update_statement);
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
gasperazzo
Posts: 29
Joined: Wed Oct 08, 2008 11:51 am

Post by gasperazzo »

BSOD2600,

I had test all ping types without success to graph. But the ping result (at the device page) was succeed...

When I look the log, looks like the cacti won't query the host... I'm home now... Tomorrow Ill post the log.


TheWitness,

I wrote some perl scripts using wmic to query cpu, memory, pagefiles, partitions from windows hosts from linux servers.

I'll try to write the scripts that u suggested, wmi ping... But wmic is a crazy program whitout regulars output...


Did anybody have a suggestion for my question? :(
User avatar
TheWitness
Developer
Posts: 17004
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

What poller type. If spine use 087e and if using icmp make sure spine is setuid and owned by root.. If cmd.php we need yor log.

TheWitness
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
User avatar
BSOD2600
Cacti Moderator
Posts: 12171
Joined: Sat May 08, 2004 12:44 pm
Location: USA

Post by BSOD2600 »

TheWitness:

Agreed it would be handy to have. Although, since WMI uses Windows authentication, it requires a user account which the web server service uses (assuming no sane admin will be using domain\local Administrator). Additionally, to specify an additional account for WMI to function, a user must punch holes for them in the firewall for DCOM (tcp port 135), WMI security (wmimgmt.msc) and DCOM security (dcomcnfg).

Lastly, I thought there was a few plugins which were starting to implement WMI in a generic sense so it can be used from linux/windows.
User avatar
TheWitness
Developer
Posts: 17004
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

Correct, Jimmy pushed one a while ago. I believe there is also a php module, but only for windows, if my memory serves me right.

TheWitness
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
gasperazzo
Posts: 29
Joined: Wed Oct 08, 2008 11:51 am

Post by gasperazzo »

Hi TheWitness,

I'm using spine 087c. Do u recommend the update to 087e?

Whats mean "setuid"? The spine file is owned by root...

I don't remember, but in a oldest version of cacti, I needed to edit a php file (don't remember the file name) to adjust this issue.

The log from" ./spine --verbosity=5" command:

07/07/2009 01:31:43 PM - SPINE: Poller[0] Host[13] PING: Result ICMP: Host is Alive
07/07/2009 01:31:43 PM - SPINE: Poller[0] Host[13] RECACHE: Processing 1 items in the auto reindex cache for '172.xxx.xxx.xxx'
07/07/2009 01:31:43 PM - SPINE: Poller[0] Host[13] DEBUG: HOST COMPLETE: About to Exit Host Polling Thread Function
gasperazzo
Posts: 29
Joined: Wed Oct 08, 2008 11:51 am

Post by gasperazzo »

After running the "chmod u+s /usr/local/bin/spine" to setuid to spine... The problem persist and i recived any errors to query localhost.

07/07/2009 03:25:02 PM - SPINE: Poller[0] Host[1] ERROR: Empty result [127.0.0.1]: 'perl /var/www/cacti/scripts/unix_processes.pl'
07/07/2009 03:25:02 PM - SPINE: Poller[0] Host[1] ERROR: Empty result [127.0.0.1]: 'perl /var/www/cacti/scripts/unix_users.pl '
07/07/2009 03:25:02 PM - SPINE: Poller[0] Host[1] ERROR: Empty result [127.0.0.1]: 'perl /var/www/cacti/scripts/loadavg_multi.pl'
07/07/2009 03:25:02 PM - SPINE: Poller[0] Host[1] ERROR: Empty result [127.0.0.1]: 'perl /var/www/cacti/scripts/linux_memory.pl SwapFree:'
07/07/2009 03:25:02 PM - SPINE: Poller[0] Host[1] ERROR: Empty result [127.0.0.1]: 'perl /var/www/cacti/scripts/linux_memory.pl MemFree:'


I tried to use cmd.php with same problem...
gasperazzo
Posts: 29
Joined: Wed Oct 08, 2008 11:51 am

Post by gasperazzo »

Solved... I updated spine to 087e and now i get the graphs...

Thanks :-)
Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests