[Ilugc] Unable to start this script during startup - SU: bin/bash : Permission Denied Error

  • From: nayagam.m@xxxxxxxxx (Murugiah Piramanayagam)
  • Date: Wed Feb 14 14:31:43 2007

Hi all,

The following is my script to start JIRA. I want to start the JIRA service
during bootup itself. I copied this script into /etc/init.d and I gave the
execution permission for all. Also, I created the links in the name of *
S99jira* for this script under /etc/rc3.d, /etc/rc4.d and /etc/rc5.d and
created link in the name of K90jira under /etc/rc0.d. When I start the m/c,
I got SU: bin/bash: Permission denied error. Could you please help me to
solve this as early as possible.

Thanks.

Piramanayagam M

#!/bin/sh
JIRA_HOME=/opt/jira
JIRA_OWNER=jira

if [ ! -f $JIRA_HOME/bin/startup.sh ]
then
    echo "JIRA startup: cannot start"
    exit
fi

start() {
        echo -n "Starting jira: "
        su - $JIRA_OWNER -c "$JIRA_HOME/bin/startup.sh"
}
stop() {
        echo -n "Shutting down httpd: "
        su - $JIRA_OWNER -c "$JIRA_HOME/bin/shutdown.sh"
}

# See how we were called.
case "$1" in
  start)
        start
        ;;
  stop)
        stop
        ;;
  restart)
        stop
        start
        ;;
  *)
        echo "Usage: $0 {start|stop|restart}"
        exit 1
esac

exit 0

Other related posts:

  • » [Ilugc] Unable to start this script during startup - SU: bin/bash : Permission Denied Error - Murugiah Piramanayagam