HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials

HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials (http://www.howtoforge.com/forums/index.php)
-   Server Operation (http://www.howtoforge.com/forums/forumdisplay.php?f=5)
-   -   Not getting Quota Reports - Perfect Serv/Ubuntu 7.10 (http://www.howtoforge.com/forums/showthread.php?t=21616)

tonydm 22nd March 2008 21:52

Fixed! - Not getting Quota Reports - Perfect Serv/Ubuntu 7.10
 
Greetings,

I wonder if someone might have some suggestions on this. I have installed and have a functioning mail server based on falko's wonderful how-to - http://www.howtoforge.com/virtual-us...ix-ubuntu-7.10. I have a couple of problems with the Quotas. As the admin I get the Quota report emailed to postmaster each day. However, there is no quota information in the report, simply the template. Also, I had a user/email address that began to have mail bounced due to over quota. The bounced email had the "User is over quota..." tag, but my user never got a quota warning. I've looked at the perl script /usr/loca/sbin/quota_notify (755) and all looks as the how-to, including the %'s that were added to the original script. I know it's being called and processed as I said I get the Quota report (although only a template of it, as seen below). I don't know much perl so it's a stretch for me to really see what's going on. But it appears that it is reading the virtual mail directory and sub dir and reading username/maildirsize. I don't see where it is reading the mysql user table and the quota size (or that is should or needs to). I also don't see any maildirsize information in the vmail dirs. So I not sure how to go about troubleshooting this other than what I have done - verify 1) the script looks correct and 2) that it is being called and executed each day. Both are true. Any help would gratefully accepted. Thank you.


Edit:

I just came across another post about a quota problem. A command quota -avug was referred too for checking quota state. I ran the command and got "The program 'quota' is not currently installed. You can install....". So I must not have quota installed? I'll check further.

Edit:
Looking back at the how-to I see this: (I don't specifically see quota, is it in there? Are we using some other derivative?)
HTML Code:

3 Apply The Quota Patch To Postfix

We have to get the Postfix sources, patch it with the quota patch, build new Postfix .deb packages and install those .deb packages:

apt-get install build-essential dpkg-dev fakeroot debhelper libgdbm-dev libldap2-dev libpcre3-dev libssl-dev libsasl2-dev postgresql-server-dev-8.2 po-debconf dpatch libmysqlclient15-dev lsb-release libcdb-dev libdb4.5-dev

cd /usr/src
apt-get source postfix

(Make sure you use the correct Postfix version in the following commands. I have Postfix 2.4.5 installed. You can find out your Postfix version by running

postconf -d | grep mail_version

The output should look like this:

root@server1:~# postconf -d | grep mail_version
mail_version = 2.4.5
milter_macro_v = $mail_name $mail_version
root@server1:~#

)

wget http://vda.sourceforge.net/VDA/postfix-2.4.5-vda-ng.patch.gz
gunzip postfix-2.4.5-vda-ng.patch.gz
cd postfix-2.4.5
patch -p1 < ../postfix-2.4.5-vda-ng.patch
dpkg-buildpackage

Edit:
Found this ref as directed by falko: http://www.howtoforge.com/forums/sho...ldirsize+quota
and I do indeed have this in my main.cf file.
Code:

virtual_create_maildirsize = yes
virtual_mailbox_extended = yes

Edit:
Tried this http://www.howtoforge.com/forums/showthread.php?t=19765 and it didn't correct the overall problem. I did get the maildirsize file created in each users directory, restarted postfix, and ran quota_notify. Still no info in the report.

tonyd

Code:

DAILY QUOTA REPORT:

----------------------------------------------
| % USAGE |            ACCOUNT NAME          |
----------------------------------------------

--
MyDomain

Edit: :)
Ok, following thecaoticone's steps all is working just fine. At first I thought it didn't fix anything from my edit above but the report didn't show anything because every user was under 1% usage. I sent a test email/attachment to ensure 50% and re-ran quota_notify. It works! Thanks Falko, Volksman, thecaoticone, and any others who contributed not only to this problem but to the many others. THANKS!

tonyd


All times are GMT +2. The time now is 18:32.

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