Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > ISPConfig 2 > Installation/Configuration

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #21  
Old 2nd February 2008, 18:57
wpwood3 wpwood3 is offline
Senior Member
 
Join Date: Oct 2007
Location: Atlanta, GA USA
Posts: 197
Thanks: 21
Thanked 31 Times in 21 Posts
Exclamation This is a problem!

Quote:
Originally Posted by till
We will have a look at this. Falko already added it to the bugtracker.
This issue shows "not a bug" in the bugtracker.

How can this be? All of my maillog files only show entries from 23:59 to 04:06. There is most certainly a problem!
Attached Images
 
__________________
CentOS 5.4 64bit (the Perfect Setup)
ISPConfig 2.2.40
WP3 Photography

Last edited by wpwood3; 2nd February 2008 at 19:11.
Reply With Quote
Sponsored Links
  #22  
Old 3rd February 2008, 20:11
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,749 Times in 2,579 Posts
Default

I've reopened it again.
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #23  
Old 26th February 2008, 12:36
jbravo jbravo is offline
Member
 
Join Date: Nov 2007
Location: Poland
Posts: 81
Thanks: 12
Thanked 3 Times in 2 Posts
Default /var/log/mail.ispconfigsave rotation?

One question related:
Is it safe to logrotate /var/log/mail.ispconfigsave file and still have all mail statistics?
Reply With Quote
  #24  
Old 27th February 2008, 13:22
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,749 Times in 2,579 Posts
Default

Yes, that's no problem.
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #25  
Old 27th February 2008, 14:46
jbravo jbravo is offline
Member
 
Join Date: Nov 2007
Location: Poland
Posts: 81
Thanks: 12
Thanked 3 Times in 2 Posts
Default

Quote:
Originally Posted by falko
Yes, that's no problem.
Should i insert some postrotate job? It seems to me that this log file is used only by cronscript so it is not needed.
Reply With Quote
  #26  
Old 28th February 2008, 10:26
xrat xrat is offline
Member
 
Join Date: Nov 2006
Location: Vienna, Austria
Posts: 56
Thanks: 69
Thanked 17 Times in 13 Posts
Default

Quote:
Originally Posted by jbravo
Should i insert some postrotate job? It seems to me that this log file is used only by cronscript so it is not needed.
This is right. No postrotate job is needed. Of course, the rotation should not be done while the ISPconfig cron job is running, which should be at midnight. HTH.
Reply With Quote
  #27  
Old 20th March 2008, 09:42
make-fun make-fun is offline
Member
 
Join Date: Jan 2008
Posts: 92
Thanks: 8
Thanked 8 Times in 7 Posts
Default

Hi folks,

unfortunatly I did not find this thread earlier and so far I can only confirm that this is also a problem with Ubuntu 6.06 (perfect setup) and ISPConfigVersion: 2.2.21
http://www.howtoforge.com/forums/sho...698#post114698

Cheers
Reply With Quote
  #28  
Old 20th March 2008, 10:48
Morons Morons is offline
Senior Member
 
Join Date: Aug 2006
Posts: 199
Thanks: 8
Thanked 15 Times in 7 Posts
Wink Logrotation, Postgrey and other issues on Ubuntu

Hi people, I have implemented a quick and very effective workaround for the broken logrotation on all my Ubuntu boxes, I have the last 2 Ubuntu versions all upgraded to latest via apt-get. It also make sure the postgrey does not die on me. Perhaps this posting may help Postgrey users to solve the constant dying issues on Ubuntu.

In crontab
Code:
22 06 * * * /bin/kill -9 `/usr/bin/pgrep postgrey-check.rc`
37 06 * * * echo "Daily logrotation." >/root/boot-reason
38 06 * * * /sbin/shutdown -r now
Note: The idea is to "fix" the broken parts of the logrotation, therefore killing my own checking scripts before the logrotation at 23 06 and restarting the stuff after logrotation, yes in this case via re-boot witch helps a lot. I have an mail sent to me each time the server statrup with the reason given the content of an file called "/root/boot-reason". this way all my scripts etc can send me notes if they re-started the server and for what reason.

First the Postgrey Fix
in the file postgrey-check.rc i have
Code:
#!/bin/bash
LOGFILE=/var/log/syslog
(
while read ans
do
        DUMMY=
done
#echo "Going to main loop"
while :
do
        read ans
        if [ "$ans" = "" ]
        then
                sleep 1
        else
                problem=`echo $ans | grep 'Server configuration problem'`
                if [ "$problem" != "" ] && grep "$problem" $LOGFILE > /dev/null
                then
                /usr/sbin/invoke-rc.d postgrey restart
                /usr/sbin/invoke-rc.d postfix restart
                echo 'Postgrey broken!' 2>&1 |/usr/bin/mailx -s "`uname -n` Postgrey And Postfix re-started" root@domain.tld
                fi
        fi
done
) < $LOGFILE
Note: I loop through the logfile constantly grep for the error, then imediatly act! As this does not reboot the server I have to mail myself some message of this error occuring. The funny thing is since I actually re-boot the server just after each log-rotation Postgrey never have issues. Apearently Postgrey run into file access rights on Ubuntu after logrotation, I cannot confirm this but it does seem so. After re-booting Postgrey re-start properly.

Now the Startup
In the file /etc/rc.local
Code:
cat /root/boot-reason 2>&1 |/usr/bin/mailx -s "`uname -n` Server restarted" root@domain.tld
echo "No reason given" >/root/boot-reason
/usr/bin/postgrey-check.rc >/dev/null &
to get mailx use apt-get install mailx

Last edited by Morons; 20th March 2008 at 10:56. Reason: Fixed the postgrey script with correct version that include the mailing
Reply With Quote
The Following User Says Thank You to Morons For This Useful Post:
falko (21st March 2008)
  #29  
Old 7th April 2008, 17:41
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,749 Times in 2,579 Posts
Default

I think I've finally fixed the log rotation problem in ISPConfig.
The fix will be available with the next ISPConfig version.
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #30  
Old 7th April 2008, 23:32
xrat xrat is offline
Member
 
Join Date: Nov 2006
Location: Vienna, Austria
Posts: 56
Thanks: 69
Thanked 17 Times in 13 Posts
 
Default

This is good news Can you say a word or two about how you approached it?
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
log fie rotation hans2512 Installation/Configuration 1 3rd April 2007 12:29
log files, rotation and emailing them hairydog2 General 65 11th October 2006 14:18
Accesslog daily rotation... Ben Developers' Forum 2 1st August 2006 11:58
mail.log is cut arnaud Installation/Configuration 1 6th July 2006 12:58
mail.log : admispconfig@localhost what is that? lyndros Installation/Configuration 1 29th June 2006 14:07


All times are GMT +2. The time now is 01:58.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.