HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials

HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials (http://www.howtoforge.com/forums/index.php)
-   HOWTO-Related Questions (http://www.howtoforge.com/forums/forumdisplay.php?f=2)
-   -   Ubuntu 8.04 Virtual Mail: user directories not creating, etc... (http://www.howtoforge.com/forums/showthread.php?t=34495)

dbdawsonjr 4th May 2009 16:05

Ubuntu 8.04 Virtual Mail: user directories not creating, etc...
 
Hi all,

I followed the How-To for "the perfect server" and followed up with the "virtual mail w/ squirrel mail, etc." how-to. I am having some problems, they may be easy and I may be slow. I am fairly new to Linux as well.

Problem 1: The user directories are not being created when I mailx a message to the user.

Problem 2: From /etc/postfix/mail.log - (mydomain) substitued for my actual domain.
to=<root@(mydomain).com>, relay=none, delay=0.12, delays=0.02/0/0.1/0, dsn=5.4.6, status=bounced (mail for mail.mydomain.com loops back to myself)

And if an email is sent from a different working email server to the new server, I receive the "Mail Delivery System [MAILER-DAEMON@(mydomain).com] reply error message:
"...I'm sorry to have to inform you that your message could not
be delivered to one or more recipients. It's attached below..."

Problem 3: Squirrel mail fails with imap connection being dropped. I suspect this is a result of the directory not being created for the user.

I appreciate all help AND your patience with a "noob"

Thanks

EDIT: I have spent some more time scanning the forums and have determined at least one mistake I was making. I was trying to use my domain (lets call it thefqdn.com) as the virtual domain. I have tried to fix that with the /etc/host and the /etc/hostname folder and running:
hostname
and
hostname -f

have diplayed the new hostname: theqdn.net

Still no luck.

falko 5th May 2009 19:03

Quote:

Originally Posted by dbdawsonjr (Post 186035)
Problem 2: From /etc/postfix/mail.log - (mydomain) substitued for my actual domain.
to=<root@(mydomain).com>, relay=none, delay=0.12, delays=0.02/0/0.1/0, dsn=5.4.6, status=bounced (mail for mail.mydomain.com loops back to myself)

Please add mail.mydomain.com to the mydestination line in /etc/postfix/main.cf and restart Postfix.

dbdawsonjr 6th May 2009 13:53

Thanks for the reply,

I have reloaded the entire server (I have it down to 3 hours now) since I figured out that you can't have your primary domain virtual as well. With the reload, I am getting different errors, mostly involving the connectiing to the SQL tables.

I will hide the the localhostname the localdomain and the virtualdomain name but here is the most recent log info:

May 6 07:35:44 localhostname postfix/cleanup[18174]: warning: E3679A4553: virtual_alias_maps map lookup problem for postmaster@localhostname.localdomain.net
May 6 07:35:44 localhostname postfix/smtpd[18170]: disconnect from localhost[127.0.0.1]
May 6 07:35:44 localhostname postfix/smtpd[18172]: EA014A4553: client=localhost[127.0.0.1]
May 6 07:35:44 localhostname postfix/cleanup[18175]: warning: connect to mysql server 127.0.0.1: Access denied for user 'UNKNOWN_USER'@'localhost' (using password: YES)
May 6 07:35:44 localhostname postfix/cleanup[18175]: warning: EA014A4553: virtual_alias_maps map lookup problem for ddawson@virtualdomain.com
May 6 07:35:44 localhostname amavis[4771]: (04771-16) Negative SMTP resp. to data-dot (<ddawson@virtualdomain.com>): 451 4.3.0 Error: queue file write error
May 6 07:35:44 localhostname amavis[4771]: (04771-16) (!)FWD via SMTP: <root@localhostname.localdomain.net> -> <ddawson@virtualdomain.com>,BODY=7BIT 451 4.6.0 Failed, id=04771-16, from MTA([127.0.0.1]:10025): 451 4.3.0 Error: queue file write error
May 6 07:35:44 localhostname amavis[4771]: (04771-16) Blocked MTA-BLOCKED, <root@localhostname.localdomain.net> -> <ddawson@virtualdomain.com>, Message-ID: <20090505192046.65316A454E@localhostname.localdomain.net>, mail_id: 7zlBLHkhvaBj, Hits: 2.152, size: 324, 19255 ms
May 6 07:35:44 localhostname postfix/cleanup[18174]: warning: F1627A4553: virtual_alias_maps map lookup problem for postmaster@localhostname.localdomain.net
May 6 07:35:44 localhostname postfix/smtpd[18172]: disconnect from localhost[127.0.0.1]
May 6 07:35:45 localhostname postfix/smtp[18161]: 08DE3A4549: to=<ddawson@virtualdomain.com>, relay=127.0.0.1[127.0.0.1]:10024, delay=61432, delays=61413/0.02/0.01/19, dsn=4.3.0, status=deferred (host 127.0.0.1[127.0.0.1] said: 451 4.3.0 Error: queue file write error (in reply to end of DATA command))
May 6 07:35:45 localhostname postfix/smtp[18162]: 65316A454E: to=<ddawson@virtualdomain.com>, relay=127.0.0.1[127.0.0.1]:10024, delay=58760, delays=58740/0.05/0.01/19, dsn=4.3.0, status=deferred (host 127.0.0.1[127.0.0.1] said: 451 4.3.0 Error: queue file write error (in reply to end of DATA command))

I think this is progress from before. So far I have checked the rights for user mail_admin, reset the password, verified it in all the /etc/postfix/virtual*.cf files, and flushed privileges in the SQL DB.

dbdawsonjr 6th May 2009 16:30

EDIT:

Found a typo in /etc/postfix/mysql-virtual_email2email.cf that confused the "user" field.

Added a forward in mysql to forward ddawson@virtualdomain.com to ddawson@virtualdomain.com. It may be redundant, but I wasn't sure.

Also added a forward in mysql to forward postmaster@localhostname.localdomain.net to postmaster@virtualhost.com

The /etc/postfix/mail.log now reads:

May 6 10:23:45 localhostname postfix/master[19264]: terminating on signal 15
May 6 10:23:46 localhostname postfix/master[19395]: daemon started -- version 2.5.1, configuration /etc/postfix
May 6 10:28:46 localhostname postfix/qmgr[19398]: CFFB1A4555: from=<root@localhostname.localdomain.net>, size=806, nrcpt=1 (queue active)
May 6 10:28:46 localhostname postfix/smtp[19407]: fatal: valid hostname or network address required in server description: virtualhost.com
May 6 10:28:47 localhostname postfix/qmgr[19398]: warning: private/smtp socket: malformed response
May 6 10:28:47 localhostname postfix/qmgr[19398]: warning: transport smtp failure -- see a previous warning/fatal/panic logfile record for the problem description
May 6 10:28:47 localhostname postfix/master[19395]: warning: process /usr/lib/postfix/smtp pid 19407 exit status 1
May 6 10:28:47 localhostname postfix/master[19395]: warning: /usr/lib/postfix/smtp: bad command startup -- throttling
May 6 10:28:47 localhostname postfix/error[19409]: CFFB1A4555: to=<ddawson@virtualhost.com>, relay=none, delay=402, delays=401/1.1/0/0.03, dsn=4.3.0, status=deferred (unknown mail transport error)

dbdawsonjr 6th May 2009 17:27

Yeah!
 
I got it running after some more careful inspection, I clearly had mislabeled the transport field in the sql db. Wrapped that up and voila!

Thank You for all your help and the excellent how-tos and advice.

Regards,

David


All times are GMT +2. The time now is 03:46.

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