Xymon Mailing List Archive search

Odd error when running custom script

4 messages in this thread

list Frank Lamoreaux · Wed, 26 Sep 2007 09:15:11 -0600 ·
So I'm getting an error when trying to run a custom script.  I've done this many times but maybe I'm missing something simple?

mail2:/home/hobbit/client/logs # tail -f bb-smart.log
2007-09-26 08:40:55 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory
2007-09-26 08:45:55 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory
2007-09-26 08:50:56 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory
2007-09-26 08:55:57 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory
2007-09-26 09:00:57 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory
2007-09-26 09:05:58 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory

Pretty straight forward, right?  But it's there and owned by user hobbit . . .

mail2:/home/hobbit/client/logs # stat /home/hobbit/client/ext/bb-smart.sh
  File: `/home/hobbit/client/ext/bb-smart.sh'
  Size: 1124            Blocks: 8          IO Block: 4096   regular file
Device: 802h/2050d      Inode: 133492      Links: 1
Access: (0755/-rwxr-xr-x)  Uid: ( 1011/  hobbit)   Gid: (    0/    root)
Access: 2007-09-26 09:06:39.000000000 -0600
Modify: 2007-09-26 08:39:27.000000000 -0600
Change: 2007-09-26 08:40:11.000000000 -0600

Any ideas?

Thanks,
Matt
list Trent Melcher · Wed, 26 Sep 2007 10:39:13 -0500 ·
quoted from Frank Lamoreaux
On Wed, 2007-09-26 at 09:15 -0600, mlist wrote:
So I'm getting an error when trying to run a custom script.  I've done this many times but maybe I'm missing something simple?

mail2:/home/hobbit/client/logs # tail -f bb-smart.log
2007-09-26 08:40:55 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory
2007-09-26 08:45:55 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory
2007-09-26 08:50:56 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory
2007-09-26 08:55:57 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory
2007-09-26 09:00:57 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory
2007-09-26 09:05:58 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory
What happens when you run it manually as the hobbit user?

Trent
quoted from Frank Lamoreaux

Pretty straight forward, right?  But it's there and owned by user hobbit . . .

mail2:/home/hobbit/client/logs # stat /home/hobbit/client/ext/bb-smart.sh
  File: `/home/hobbit/client/ext/bb-smart.sh'
  Size: 1124            Blocks: 8          IO Block: 4096   regular file
Device: 802h/2050d      Inode: 133492      Links: 1
Access: (0755/-rwxr-xr-x)  Uid: ( 1011/  hobbit)   Gid: (    0/    root)
Access: 2007-09-26 09:06:39.000000000 -0600
Modify: 2007-09-26 08:39:27.000000000 -0600
Change: 2007-09-26 08:40:11.000000000 -0600

Any ideas?

Thanks,
Matt

list Galen Johnson · Wed, 26 Sep 2007 12:38:17 -0400 ·
One other thing to consider as well is that particular error could be
coming from the script itself (usually associated with a bad #!
line)...Trent's recommendation should tell you...you may want to add set
-x as the second line as well to dump output for what the script thinks
it's doing.

=G=
quoted from Trent Melcher

-----Original Message-----
From: Trent Melcher [mailto:user-c65e78735b17@xymon.invalid] Sent: Wednesday, September 26, 2007 11:39 AM
To: user-ae9b8668bcde@xymon.invalid
Subject: Re: [hobbit] Odd error when running custom script

On Wed, 2007-09-26 at 09:15 -0600, mlist wrote:
So I'm getting an error when trying to run a custom script.  I've done
this many times but maybe I'm missing something simple?

mail2:/home/hobbit/client/logs # tail -f bb-smart.log
2007-09-26 08:40:55 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory
2007-09-26 08:45:55 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory
2007-09-26 08:50:56 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory
2007-09-26 08:55:57 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory
2007-09-26 09:00:57 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory
2007-09-26 09:05:58 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory
What happens when you run it manually as the hobbit user?

Trent

Pretty straight forward, right?  But it's there and owned by user
hobbit 
. . .

mail2:/home/hobbit/client/logs # stat
/home/hobbit/client/ext/bb-smart.sh
  File: `/home/hobbit/client/ext/bb-smart.sh'
  Size: 1124            Blocks: 8          IO Block: 4096   regular
file
Device: 802h/2050d      Inode: 133492      Links: 1
Access: (0755/-rwxr-xr-x)  Uid: ( 1011/  hobbit)   Gid: (    0/
root)
Access: 2007-09-26 09:06:39.000000000 -0600
Modify: 2007-09-26 08:39:27.000000000 -0600
Change: 2007-09-26 08:40:11.000000000 -0600

Any ideas?

Thanks,
Matt

list Frank Lamoreaux · Wed, 26 Sep 2007 10:51:18 -0600 ·
quoted from Trent Melcher
Trent Melcher wrote:
On Wed, 2007-09-26 at 09:15 -0600, mlist wrote:
  
So I'm getting an error when trying to run a custom script.  I've done this many times but maybe I'm missing something simple?

mail2:/home/hobbit/client/logs # tail -f bb-smart.log
2007-09-26 08:40:55 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory
2007-09-26 08:45:55 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory
2007-09-26 08:50:56 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory
2007-09-26 08:55:57 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory
2007-09-26 09:00:57 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory
2007-09-26 09:05:58 Could not start task disksts using command '/home/hobbit/client/ext/bb-smart.sh': No such file or directory

    
What happens when you run it manually as the hobbit user?

Trent

Very good idea Trent and Galen, that was it - typo.

mail2:/home/hobbit/client/ext # su hobbit
hobbit at mail2:~/client/ext> /home/hobbit/client/ext/bb-smart.sh
bash: /home/hobbit/client/ext/bb-smart.sh: /usr/bin/bash: bad interpreter: No such file or directory

Thanks for the help,

Matt