View Single Post
  #39 (permalink)  
Old 04-13-2011, 04:44 PM
secnix secnix is offline
Active Member
 
Posts: 28
Default

Hi,

The script works now when I modify the zimbra start function below
Code:
zimbra_start() {
if [ "$2" = "--no-start" ]
then
  # If --no-start is set ignore starting Zimbra
  echo "`date "+%Y-%m-%d %H:%M:%S"` - Zimbra services not starting, --no-start is set." >> $ZimLogFile
  echo "Zimbra services not starting, --no-start is set."
else
 # Starting Zimbra
 if [ $ZimLogEnable = 'yes' ]
  then
   # Sending task start time to log
   echo "`date "+%Y-%m-%d %H:%M:%S"` - Zimbra services starting..." >> $ZimLogFile
   
   # Starting Zimbra
   sudo -u zimbra /opt/zimbra/bin/zmcontrol start  >> $ZimLogFile
   
   # Send task stop time to log
   echo "`date "+%Y-%m-%d %H:%M:%S"` - Zimbra services started." >> $ZimLogFile

  else

   # Starting Zimbra
   sudo -u zimbra /opt/zimbra/bin/zmcontrol start

  fi
fi
}
I replace all the command
Code:
sudo -u zimbra /opt/zimbra/bin/zmcontrol start
with the command
Code:
su zimbra -c "zmcontrol start"
and now the logger service can start successfully after the backup occurs. I'm not sure why, because I'm not good at Linux :P. But it works for me although both commands do look the same .

Thanks anyway,
SN
Reply With Quote