<HTML>
<HEAD>
<TITLE>Re: [Nagios-users] help with executing remote command</TITLE>
</HEAD>
<BODY>
<FONT FACE="Verdana, Helvetica, Arial"><SPAN STYLE='font-size:12.0px'><BR>
Try this in your service definition: (the ONLY thing you need to pass is the arg itself as the command is already defined in the checkcommandscfg)<BR>
<BR>
check_command check_remote_disk!/ <BR>
<BR>
Separate args with ! And no spaces. I cant test now, but I assume their is a default warning and critical defintion as you don’t specify. <BR>
<BR>
Hth<BR>
calvin<BR>
<BR>
<BR>
<BR>
<BR>
On 4/27/05 6:35 PM, "Leonardo Murúa Jiménez" <leonardox@aullox.com> wrote:<BR>
<BR>
</SPAN></FONT><BLOCKQUOTE><FONT FACE="Verdana, Helvetica, Arial"><SPAN STYLE='font-size:12.0px'><BR>
checkcommands.cfg <BR>
<BR>
# 'check_remote_disk' command definition<BR>
define command{<BR>
command_name check_remote_disk<BR>
command_line $USER1$check_by_ssh -H $HOSTADDRESS$ -C '/usr/local/bin/check_disk -p $ARG1$'<BR>
<BR>
"services.cfg"<BR>
<BR>
define service{<BR>
host_name nfsserver<BR>
service_description DISK Remote<BR>
check_command check_remote_disk! -H 10.0.2.10 -C '/usr/local/bin/check_disk -p /'<BR>
max_check_attempts 3<BR>
normal_check_interval 5<BR>
retry_check_interval 3<BR>
check_period 24x7<BR>
notification_interval 30<BR>
notification_period 24x7 <BR>
notification_options w,c,r<BR>
contact_groups linux-admins<BR>
}<BR>
<BR>
<BR>
<BR>
<BR>
-------------------------------------------------------<BR>
SF.Net email is sponsored by: Tell us your software development plans!<BR>
Take this survey and enter to win a one-year sub to SourceForge.net<BR>
Plus IDC's 2005 look-ahead and a copy of this survey<BR>
Click here to start! <a href="http://www.idcswdc.com/cgi-bin/survey?id=105hix">http://www.idcswdc.com/cgi-bin/survey?id=105hix</a><BR>
_______________________________________________<BR>
Nagios-users mailing list<BR>
Nagios-users@lists.sourceforge.net<BR>
https://lists.sourceforge.net/lists/listinfo/nagios-users<BR>
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue.<BR>
::: Messages without supporting info will risk being sent to /dev/null<BR>
<BR>
</SPAN></FONT></BLOCKQUOTE><FONT FACE="Verdana, Helvetica, Arial"><SPAN STYLE='font-size:12.0px'><BR>
</SPAN></FONT>
</BODY>
</HTML>