How cacti runs scrit.pl on a remote host ?

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

Moderators: Developers, Moderators

Post Reply
dry
Posts: 2
Joined: Wed Mar 02, 2005 8:37 am

How cacti runs scrit.pl on a remote host ?

Post by dry »

Hello,

sorry formy bad english ..

I would like to know what mecanism cacti uses to execute script.pl (like linux_memory.pl) on the managed host, whereas the script is located on the manager host ?
Need the managed host to have a web server running with php installed ? or any other thing ?

could U explain me ?

I hope u ll be able to understood my question

Thx, Dry
User avatar
rony
Developer/Forum Admin
Posts: 6022
Joined: Mon Nov 17, 2003 6:35 pm
Location: Michigan, USA
Contact:

Post by rony »

Typically for remote hosts, you would use SNMP.

The scripts that are tied to localhost are really only designed for localhost.

But with some ssh/rsh magic, you could execute those scripts on a remote server.
[size=117][i][b]Tony Roman[/b][/i][/size]
[size=84][i]Experience is what causes a person to make new mistakes instead of old ones.[/i][/size]
[size=84][i]There are only 3 way to complete a project: Good, Fast or Cheap, pick two.[/i][/size]
[size=84][i]With age comes wisdom, what you choose to do with it determines whether or not you are wise.[/i][/size]
dry
Posts: 2
Joined: Wed Mar 02, 2005 8:37 am

Post by dry »

ok, understood,

Thx ;)
pbulteel
Cacti User
Posts: 150
Joined: Fri Sep 05, 2003 9:20 am
Location: London
Contact:

Post by pbulteel »

Hi rony,

I assume you mean using public key/private key pairs you could do it. Do you happen to have any examples of how this would be done? I guess you would add a data input method that worked that way.

Have you heard of anyone doing it? I'm curious to try it, so if I do get it working I'll post it here. Maybe it can be added as part of the Cacti Documentation.

-P
uname -a
User avatar
solefald
Posts: 38
Joined: Fri Jun 11, 2004 1:35 pm

Post by solefald »

if you have ssh keys setup correctly and running something like Keychain
( http://www.gentoo.org/proj/en/keychain/ )
to keep your passphrase in the memory you can do something like this

ssh hostname <remote comand and its arguments>
it will login into the remote server, run that command and disconnect

for example i want to run `du -sh /www` on the remote server

Code: Select all

aragorn::~% ssh 192.168.1.3 du -sh /www
18G     /www
aragorn::~%
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests