[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Error: the executable does not exist 'su'

From: Anoop kumar V
Subject: Re: Error: the executable does not exist 'su'
Date: Tue, 15 Aug 2006 16:53:20 -0400

Thank you Jan-Henrik Haukeland.

I remm reading abt the path variable being stripped.. I should have recollected that.

The "as uid weblogic" will work very well for me... that is perfect.

Also, I have this minor problem... I do not have smtp set up on my server... and I do not want monit to restart my weblogic if it finds that it fails..but I still want it to continue monitoring....
how can i achieve that.. As of now I have "alert" if service is not running... but then when the service is not running, it just unmonitors the process...

All I want to do is monit to strictly monitor the weblogic processes and do nothing if the process is not running - we will keep checking the monit url and if any process if not running we will restart it. (The other problem is that we do not want monit to restart a process if it was brought down by us.. like for a code deployment etc..)

Thanks again,

On 8/15/06, Jan-Henrik Haukeland <address@hidden> wrote:

On 15. aug. 2006, at 20.29, Anoop kumar V wrote:

> # ./monit status
> /etc/monitrc:21: Error: the executable does not exist 'su'

You need to specify the full path to the su command. Monit sets a
very spartan path variable which may not contain this command.

> check host Remediation_Test with address
>         group www
>         start program = "su - weblogic -c /opt/bea/user_projects/
> domains/cap2test/start"

Write instead (assuming su is in /usr/bin):
         start program = "/usr/bin/su - weblogic -c /opt/bea/

On a side note, monit also support user id and group id switch upon
starting a program, if you run monit as root. That is you could also
write the above as

         start program = "/opt/bea/user_projects/domains/cap2test/
start" as uid weblogic and gid weblogic

See also the tomcat config example here,

Monit will then run the server as the weblogic user.

>         start program = "cd /opt/bea/user_projects/domains/cap2dev;
> su weblogic -c \"nohup

The start/stop command only takes a program with arguments. You
cannot run a script directly. If you want to run a script you must
start a shell like so

         start program = "/bin/bash -c 'cd /opt/bea/user_projects/
domains/cap2dev; su weblogic -c ..'

> What I am trying to do is this:
>  Run some processes as another user (weblogic). So for that I use
> "su weblogic"

Jan-Henrik Haukeland

To unsubscribe:

Thanks and best regards,
reply via email to

[Prev in Thread] Current Thread [Next in Thread]