As we transition to the new Hyland Community, some post links may be temporarily disrupted as we finalize redirects. We apologize for the inconvenience and are working to resolve this as quickly as possible. Details.
/etc/init.d/alfresco start
#!/bin/sh # # Startup script for Alfresco # # chkconfig: 345 96 14 # description: Tomcat Servlet Engine running Alfresco # processname: tomcat # pidfile: /opt/alfresco/alfresco.pid # # User under which tomcat will run TOMCAT_USER=root JAVA_HOME=/opt/java/jdk RETVAL=0 # start, debug, stop, and status functions start() { # Start Tomcat in normal mode SHUTDOWN_PORT=`netstat -vatn|grep LISTEN|grep 8005|wc -l` export JAVA_HOME=$JAVA_HOME if [ $SHUTDOWN_PORT -ne 0 ]; then echo "Alfresco already started" else echo "Starting alfresco…" sudo -u $TOMCAT_USER /opt/alfresco/alf_start.sh SHUTDOWN_PORT=`netstat -vatn|grep LISTEN|grep 8005|wc -l` while [ $SHUTDOWN_PORT -eq 0 ]; do sleep 1 SHUTDOWN_PORT=`netstat -vatn|grep LISTEN|grep 8005|wc -l` done RETVAL=$? echo "Alfresco started" [ $RETVAL=0 ] && touch /var/lock/subsys/alfresco fi } stop() { SHUTDOWN_PORT=`netstat -vatn|grep LISTEN|grep 8005|wc -l` export JAVA_HOME=$JAVA_HOME if [ $SHUTDOWN_PORT -eq 0 ]; then echo "Alfresco already stopped" else echo "Stopping alfresco…" sudo -u $TOMCAT_USER /opt/alfresco/alf_stop.sh SHUTDOWN_PORT=`netstat -vatn|grep LISTEN|grep 8005|wc -l` done RETVAL=$? echo "Alfresco stopped" [ $RETVAL=0 ] && rm -f /var/lock/subsys/alfresco /opt/alfresco/alfresco.pid fi } status() { SHUTDOWN_PORT=`netstat -vatn|grep LISTEN|grep 8005|wc -l` if [ $SHUTDOWN_PORT -eq 0 ]; then } echo "Alfresco stopped" else echo "Alfresco running" fi } case "$1" in start) start ;; stop) stop ;; restart) stop start ;; status) status ;; *) echo "Usage: $0 {start|stop|restart|status}" exit 1 esac exit $RETVAL