Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > Linux Forums > Server Operation

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 8th January 2007, 05:26
jdkullmann jdkullmann is offline
Junior Member
 
Join Date: Nov 2006
Location: NYC
Posts: 24
Thanks: 2
Thanked 0 Times in 0 Posts
Send a message via AIM to jdkullmann Send a message via Skype™ to jdkullmann
Default postfix/courier/mysql /home/vmail/ problems

I've followed the tutorial, setting up a new debain system with Virtual Users And Domains With Postfix, Courier And MySQL (+ SMTP-AUTH, Quota, SpamAssassin, ClamAV)

Mail sent get delivered to /home/jk/Maildir/ instead of /home/vmail/myserver.com/jk/Maildir/ (myserver.com is my real domain name)

I've quadruple checked all the config files etc. I've even referred back to the older tutorial "Tutorial: ISP-style Email Service with Debian-Sarge and Postfix 2.1" to help educate myself more.

It appears that MYSQL msgs go to /var/log/syslog on this system and there are no errors in that logfile.

Which component of these is the one responsible for actually writing the email into the final destination, and, can I somehow turn on verbose logging for that component so I can see what might be going wrong?
Reply With Quote
Sponsored Links
  #2  
Old 8th January 2007, 15:13
jdkullmann jdkullmann is offline
Junior Member
 
Join Date: Nov 2006
Location: NYC
Posts: 24
Thanks: 2
Thanked 0 Times in 0 Posts
Send a message via AIM to jdkullmann Send a message via Skype™ to jdkullmann
Default

I discovered that this seemingly benign error/warning in mail.log:

Jan 7 22:43:14 server postfix/trivial-rewrite[12609]: warning: do not list domain server.com in BOTH mydestination and virtual_mailbox_domains

was my problem with mail delivery to the /home/vmail/... Maildirs.

I removed my server.com from the mydestinations field in main.cf (i have it in the domains table in the mysql mail database) and mail was then delievered properly.

also i discovered that in addition to adding a new user to the users database i also had to do roughly this:

mkdir /home/vmail/<server.com>/<newuser>
cd /home/vmail/<server.com>/<newuser>
maildirmake Maildir
chown -R vmail:vmail /home/vmail/<server.com>/<newuser>

or else mail would not be delivered. Apparently postfix et al does not create the users or Maildir directories if they are not there. I saw errors like this in the mail.log if I didn't do those creates:

Jan 8 07:36:06 server amavis[6795]: (06795-02) Checking: <jzk@foo.com> -> <kim@server.com>
Jan 8 07:36:06 server amavis[6795]: (06795-02) lookup_sql: 2013, Lost connection to MySQL server during query
Jan 8 07:36:06 server amavis[6795]: (06795-02) NOTICE: Disconnected from SQL server
Jan 8 07:36:06 server amavis[6795]: (06795-02) TROUBLE in check_mail: creating_partsdir FAILED: DBD::mysql::st execute failed: Lost connection to MySQL server during query at (eval 38) line 238, <GEN17> line 97.

Once I created the users dir and Mailbox files and chown'd them to vmail , mail was properly delivered
Reply With Quote
  #3  
Old 25th January 2007, 10:49
Pooch Pooch is offline
Junior Member
 
Join Date: Jan 2007
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I've been going through the same frustrations with setting up a new debain system with Virtual Users And Domains With Postfix, Courier And MySQL (+ SMTP-AUTH, Quota, SpamAssassin, ClamAV)

I can't for the life of me find where the email is going! I can send out no problem but I can't seem to receive to the /home/vmail dir. I did what you suggested with adding the directory but it still doesn't seem to work. Here's a look at my mail log, I can't seem to find any mysql output though.

my domain is viewdo.net and I've created user apuccinelli@viewdo.net

here's the mail log
Jan 25 09:23:23 alpha postfix/smtpd[13159]: connect from an-out-0708.google.com[209.85.132.243]
Jan 25 09:23:23 alpha postfix/smtpd[13159]: 136636B829E: client=an-out-0708.google.com[209.85.132.243]
Jan 25 09:23:23 alpha postfix/cleanup[13163]: 136636B829E: message-id=<9e8976770701250123j418c13f2v6089e9b8deb30faa@m ail.gmail.com>
Jan 25 09:23:23 alpha postfix/qmgr[13084]: 136636B829E: from=<alanpuccinelli@gmail.com>, size=1639, nrcpt=1 (queue active)
Jan 25 09:23:30 alpha postfix/smtpd[13169]: connect from localhost[127.0.0.1]
Jan 25 09:23:30 alpha postfix/smtpd[13169]: 93D576B8302: client=localhost[127.0.0.1]
Jan 25 09:23:30 alpha postfix/cleanup[13163]: 93D576B8302: message-id=<9e8976770701250123j418c13f2v6089e9b8deb30faa@m ail.gmail.com>
Jan 25 09:23:30 alpha postfix/qmgr[13084]: 93D576B8302: from=<alanpuccinelli@gmail.com>, size=2099, nrcpt=1 (queue active)
Jan 25 09:23:30 alpha amavis[9692]: (09692-06) Passed, <alanpuccinelli@gmail.com> -> <apuccinelli@viewdo.net>, Message-ID: <9e8976770701250123j418c13f2v6089e9b8deb30faa@mail .gmail.com>, Hits: 0.024
Jan 25 09:23:30 alpha postfix/smtp[13164]: 136636B829E: to=<apuccinelli@viewdo.net>, relay=127.0.0.1[127.0.0.1], delay=7, status=sent (250 2.6.0 Ok, id=09692-06, from MTA: 250 Ok: queued as 93D576B8$
Jan 25 09:23:30 alpha postfix/qmgr[13084]: 136636B829E: removed
Jan 25 09:23:30 alpha postfix/smtpd[13169]: disconnect from localhost[127.0.0.1]
Jan 25 09:23:31 alpha postfix/smtp[13171]: 93D576B8302: to=<alanpuccinelli@gmail.com>, orig_to=<apuccinelli@viewdo.net>, relay=gmail-smtp-in.l.google.com[66.249.83.27], delay=1, status=sent (250 2.0$
Jan 25 09:23:31 alpha postfix/qmgr[13084]: 93D576B8302: removed

It appears to be delivering. No bounceback, status is sent. Any ideas?

Thanks in advance.
Reply With Quote
  #4  
Old 26th January 2007, 16:34
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,739 Times in 2,574 Posts
 
Default

Quote:
Originally Posted by Pooch
Jan 25 09:23:31 alpha postfix/smtp[13171]: 93D576B8302: to=<alanpuccinelli@gmail.com>, orig_to=<apuccinelli@viewdo.net>, relay=gmail-smtp-in.l.google.com[66.249.83.27], delay=1, status=sent (250 2.0$
It seems the mails are forwarded to a Gmail account.
__________________
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
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
Problems with groups/grpconv linuxfast General 28 21st April 2008 09:35
Empty Recycle Bin jon335 General 40 6th May 2006 11:56
Help! Real newbie having problems installing Linux t-kiss Kernel Questions 5 4th April 2006 15:14
Suse 10.0 Installation Problems protocol Installation/Configuration 16 9th February 2006 05:07
Problems with postfix-mysql Pelle Installation/Configuration 39 13th November 2005 23:25


All times are GMT +2. The time now is 07:21.


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