Zimbra offers Open Source email server software and shared calendar for Linux and the Mac
Go Back   Zimbra :: Forums > Zimbra Collaboration Suite > Administrators

Welcome to the Zimbra :: Forums!
Welcome, if you would like to post a comment please register. We also encourage you to explore all things Zimbra with our team and members of the community.

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 01-25-2009, 08:54 AM
Advanced Member
 
Posts: 220
Cool Unexpected message in the log after zimbra restarting

Hello,

I ran this script:
Code:
#!/bin/bash

# General settings
sudo -u zimbra /opt/zimbra/bin/zmcontrol -v
sudo mkdir -p /opt/backup/tmp
sudo rm -rf /opt/backup/tmp/zimbra

# Stopping zimbra services
sudo -u zimbra /opt/zimbra/bin/zmcontrol stop
sleep 20

# Getting zimbra processes
sudo ps aux | grep zimbra

# Killing zimbra procecees
sudo kill -9 $(ps -u zimbra -o "pid=")

# Gold syncing to backup folder
sudo rsync -avr /opt/zimbra/ /opt/backup/tmp/zimbra

# Compressing backup for space reduction
sudo tar -zcvf $local_backup_dir/01/$backup_full_file_name -C /opt/backup/tmp zimbra

# Zimbra services starting
sudo -u zimbra /opt/zimbra/bin/zmcontrol start
sleep 20

# Zimbra services status
sudo -u zimbra /opt/zimbra/bin/zmcontrol status
This is the status for zmcontrol status
Code:
Host mail.domain.com
	antispam                Running
	antivirus               Running
	ldap                    Running
	logger                  Stopped
		zmlogswatchctl is not running
	mailbox                 Running
	mta                     Running
	snmp                    Stopped
		zmswatch is not running.
	spell                   Running
	stats                   Running
and this is the services status from the log when the script was done

Code:
Jan 25 18:12:05 mail zimbramon[11706]: 11706:info: 2009-01-25 18:12:01, STATUS: mail.domain.com: antispam: Stopped 
Jan 25 18:12:05 mail zimbramon[11706]: 11706:info: 2009-01-25 18:12:01, STATUS: mail.domain.com: antivirus: Stopped 
Jan 25 18:12:05 mail zimbramon[11706]: 11706:info: 2009-01-25 18:12:01, STATUS: mail.domain.com: ldap: Running 
Jan 25 18:12:05 mail zimbramon[11706]: 11706:info: 2009-01-25 18:12:01, STATUS: mail.domain.com: logger: Stopped 
Jan 25 18:12:05 mail zimbramon[11706]: 11706:info: 2009-01-25 18:12:01, STATUS: mail.domain.com: mailbox: Running 
Jan 25 18:12:05 mail zimbramon[11706]: 11706:info: 2009-01-25 18:12:01, STATUS: mail.domain.com: mta: Stopped 
Jan 25 18:12:05 mail zimbramon[11706]: 11706:info: 2009-01-25 18:12:01, STATUS: mail.domain.com: snmp: Stopped 
Jan 25 18:12:05 mail zimbramon[11706]: 11706:info: 2009-01-25 18:12:01, STATUS: mail.domain.com: spell: Stopped 
Jan 25 18:12:05 mail zimbramon[11706]: 11706:info: 2009-01-25 18:12:01, STATUS: mail.domain.com: stats: Stopped
Any help please?

Cheers,

Last edited by snake_eyes; 01-25-2009 at 09:02 AM..
Reply With Quote
  #2 (permalink)  
Old 01-26-2009, 06:41 PM
Advanced Member
 
Posts: 220
Default

Hello,

Any help gentleman about this matter, I'm tired with this error

Cheers,
Reply With Quote
  #3 (permalink)  
Old 01-26-2009, 09:42 PM
Active Member
 
Posts: 32
Default

Please attach messages from

/opt/zimbra/log/mysql_error.log
/opt/zimbra/log/mailbox.log
/opt/zimbra/log/logger_mysql_error.log
Reply With Quote
  #4 (permalink)  
Old 01-26-2009, 10:00 PM
Advanced Member
 
Posts: 220
Default

Kindly check the log files of each one as per your request:

This is the exact time of backup script 18:00

/opt/zimbra/log/mysql_error.log
Code:
090126 18:02:29 [Note] /opt/zimbra/mysql/libexec/mysqld: Normal shutdown

090126 18:02:29  InnoDB: Starting shutdown...
090126 18:02:31  InnoDB: Shutdown completed; log sequence number 0 82535611
090126 18:02:31 [Note] /opt/zimbra/mysql/libexec/mysqld: Shutdown complete

090126 18:02:31  mysqld ended

090126 18:13:04  mysqld started
090126 18:13:05  InnoDB: Started; log sequence number 0 82535611
090126 18:13:05 [Note] /opt/zimbra/mysql/libexec/mysqld: ready for connections.
Version: '5.0.51a-log'  socket: '/opt/zimbra/db/mysql.sock'  port: 7306  Source distribution
/opt/zimbra/log/mailbox.log
When I try to open it, it gives that couldn't specify the characters encoding, couldn't open it

/opt/zimbra/log/logger_mysql_error.log
Code:
090126 18:02:33 [Note] /opt/zimbra/logger/mysql/libexec/mysqld: Normal shutdown

090126 18:02:35  InnoDB: Starting shutdown...
090126 18:02:36  InnoDB: Shutdown completed; log sequence number 0 43655
090126 18:02:36 [Note] /opt/zimbra/logger/mysql/libexec/mysqld: Shutdown complete

STOPPING server from pid file /opt/zimbra/logger/db/mysql.pid
090126 18:02:36  mysqld ended
090126 18:02:36  mysqld ended


Starting mysqld daemon with databases from /opt/zimbra/logger/db/data
090126 18:13:03  mysqld started
090126 18:13:04  InnoDB: Started; log sequence number 0 43655
090126 18:13:04 [Note] /opt/zimbra/logger/mysql/libexec/mysqld: ready for connections.
Reply With Quote
  #5 (permalink)  
Old 01-26-2009, 10:16 PM
Active Member
 
Posts: 32
Default

Logger - Zimbra ::Wiki
It is recommended to checkout this link first. May be it could help to solve your problem.
Reply With Quote
  #6 (permalink)  
Old 01-26-2009, 10:26 PM
Advanced Member
 
Posts: 220
Default

I've searched the whole forums, found solutions, tried them... but, nothing seems to work
could you please check my script carefully, is there something wrong with it? specially the Zimbra shutting down and starting.

Cheers,
Reply With Quote
  #7 (permalink)  
Old 01-26-2009, 10:52 PM
Active Member
 
Posts: 32
Default

It seems that some kind of pid files problems exists.

sudo kill -9 $(ps -u zimbra -o "pid=")

Make sure that after this command there are no processes and pid files associated with killed services remain in the system. Especially mysql pid.
Reply With Quote
  #8 (permalink)  
Old 01-26-2009, 11:04 PM
Advanced Member
 
Posts: 220
Default

Great,

1. What's you suggestion with this command, Is there another way to kill the left over processes?

2. What about this:
Code:
PROX=(`ps -u zimbra | awk '{print $1}' | grep -v PID`)
if [ "$PROX" ]
then
 ps -u zimbra | awk '{print $1}' | grep -v PID | xargs kill -s 15
else
 echo "Nothing to kill"
fi
Waiting your feedback, and thanks in advance...

Cheers,
Reply With Quote
  #9 (permalink)  
Old 01-26-2009, 11:22 PM
Active Member
 
Posts: 32
Default

Second piece of code looks more complicated It should work perfectly.
Second phase is to kill remaining pid files if any other. Are there any pid files in /opt/zimbra/ after executing this code?
Some kind of
find /opt/zimbra -name *.pid

We have similar problems with logger and it were assiciated with pid files problems
__________________
With best regards,
Reply With Quote
  #10 (permalink)  
Old 01-26-2009, 11:44 PM
Advanced Member
 
Posts: 220
Default

Actually I don't recognize, while the script is working the cron.

Look I ran this command from my script above:
Code:
sudo ps aux | grep zimbra
it show me more than 6 PID

and this also from my script above:
Code:
sudo kill -9 $(ps -u zimbra -o "pid=")
It gives noting, that means no PID remaining, all were killed

Unlike when it executed from the cron

Cheers,
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads

Why Join?

Registering let's you ask questions, makes it easier to search, displays any files attached to posts, and notifies you about replies.

blog.zimbra.com




 

SEO by vBSEO ©2011, Crawlability, Inc.