0 Replies Latest reply on Jul 7, 2014 8:22 PM by neerajoshi

    cold fusion 10 root access to start stop

    neerajoshi

      hi there,

       

      urgent help required,,, we got new Linux server and need to install CF 10 on them,,,as we were told by our former team that we need to have vtier sudo access on the server. Now the team that provides access is saying that if a server has vtier account, CF should be started/stopped using vtier account only and root access to vtier will not be provided. As per them, if sudo access to vtier is must for starting/stopiing CF, then there is need to install/configure the CF for vtier account only....vtier account is runtime user...and in filesystem it is /opt/app/<vtierName>.

       

      I checked the start/stop script for CF and found this:

       

      1-     it is clearly mentioned that one must be root to start CF. (highlighted in RED)

       

      if [ "`uname`" = "Darwin" ]; then

                  # nothing, on OSX we don't care about the user name.  We assume that the user running it has permission to do everything

      IS_MAC="true"

      elif [ ! $ID -eq 0 ]; then

      echo "You must be root to start ColdFusion ."

              exit 1

      fi

       

      2- Where it actually tries to start CF with CFSTART, it looks for /sbin/runuser, if it finds out that it start CF with ‘/sbin/runuser –s’ with RUNTIME_USER that is already defined in script as vtier account.

      Linux)

      OS=Linux

      PSCMD="ps -ef"

      LD_LIBRARY_PATH="$CF_DIR/lib:$CF_DIR/lib/_ilnx21/bin:$JAVA_LIBRARY_PATH"

      SUCMDFILE=su

      if [ -x /sbin/runuser ]; then

      SUCMDFILE=/sbin/runuser

      fi

       

              CFSTART='$SUCMDFILE -s /bin/sh $RUNTIME_USER -c "export LD_LIBRARY_PATH=$LD_LIBRARY_PATH; cd $CF_DIR/bin; nohup $JAVA_EXECUTABLE -classpath $CLASSPATH $JVM_ARGS com.adobe.coldfusion.bootstrap.Bootstrap -start &"'

              CFSTOP='$SUCMDFILE -s /bin/sh $RUNTIME_USER -c "env -i; cd $CF_DIR/bin;$JAVA_EXECUTABLE -classpath $CLASSPATH $JVM_ARGS_NODEBUG com.adobe.coldfusion.bootstrap.Bootstrap -stop"'

       

      I tried to modify the script, commented the root part condition as in point 1, but looks not possible to amend the part 2 where it actually starts the CF.

      Now my question is:

       

      1- Do we really need root access to vtier account (runtime user) to start/stop CF?

      2- If we really don't need root access, how can we modify the script and/or do other changes?

       

      Your help is much appreciated.