#1  
Old 31st May 2008, 17:01
spaceuser spaceuser is offline
Junior Member
 
Join Date: May 2008
Posts: 20
Thanks: 0
Thanked 0 Times in 0 Posts
Default Virtual users... Ubuntu 8.04

I'm running Ubuntu Server 8.04 as guest OS on VMWare server and installed the mailserver, Virtual Users And Domains With Postfix, Courier, MySQL And SquirrelMail (Ubuntu 8.04 LTS). On page 4, it says
Quote:
12 Test Postfix

To see if Postfix is ready for SMTP-AUTH and TLS, run

telnet localhost 25

After you have established the connection to your Postfix mail server type

ehlo localhost

If you see the lines

250-STARTTLS

and

250-AUTH LOGIN PLAIN

everything is fine:

root@server1:/usr/local/sbin# telnet localhost 25
Trying 127.0.0.1...
Connected to localhost.localdomain.
Escape character is '^]'.
220 server1.example.com ESMTP Postfix (Ubuntu)
ehlo localhost
250-server1.example.com
250-PIPELINING
250-SIZE 10240000
250-VRFY
250-ETRN
250-STARTTLS
250-AUTH LOGIN PLAIN
250-AUTH=LOGIN PLAIN
250-ENHANCEDSTATUSCODES
250-8BITMIME
250 DSN
quit
221 2.0.0 Bye
Connection closed by foreign host.
root@server1:/usr/local/sbin#
When I do the same, I receive only this:

root@mailserver:~# telnet localhost 25
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
220 mailserver.vas.net ESMTP Postfix (Ubuntu)
ehlo localhost
250-mailserver.vas.net
250-PIPELINING
250-SIZE 10240000
250-VRFY
250-ETRN
250-STARTTLS
250-AUTH PLAIN LOGIN
250-AUTH=PLAIN LOGIN
250-ENHANCEDSTATUSCODES
250-8BITMIME
250 DSN
quit
221 2.0.0 Bye
Connection closed by foreign host.
root@mailserver:~#

Therefore I wonder why the 250-STARTTLS and 250-AUTH LOGIN PLAIN wont show up.

I would appreciate any comment on this.

TIA
Reply With Quote
Sponsored Links
  #2  
Old 1st June 2008, 10:19
thecaoticone thecaoticone is offline
Member
 
Join Date: Nov 2007
Posts: 89
Thanks: 1
Thanked 18 Times in 16 Posts
Default

From what you posted everything is there.

Quote:
When I do the same, I receive only this:

root@mailserver:~# telnet localhost 25
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
220 mailserver.vas.net ESMTP Postfix (Ubuntu)
ehlo localhost
250-mailserver.vas.net
250-PIPELINING
250-SIZE 10240000
250-VRFY
250-ETRN
250-STARTTLS
250-AUTH PLAIN LOGIN

250-AUTH=PLAIN LOGIN
250-ENHANCEDSTATUSCODES
250-8BITMIME
250 DSN
quit
221 2.0.0 Bye
Connection closed by foreign host.
root@mailserver:~#
Reply With Quote
  #3  
Old 1st June 2008, 15:58
spaceuser spaceuser is offline
Junior Member
 
Join Date: May 2008
Posts: 20
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Uh... silly me!! Seem to need new glasses obviously

Thanx
Reply With Quote
  #4  
Old 1st June 2008, 20:52
spaceuser spaceuser is offline
Junior Member
 
Join Date: May 2008
Posts: 20
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Since I've received a lot of the same errors that more folks around here, I did check them first to see if they would solve my problem, but they didn't.

When I tried to login using Squirrelmail I receive this in the /var/log/mail.err file:

Jun 1 20:35:01 mailserver imapd: authentication error: Input/output error
Jun 1 20:35:39 mailserver postfix/trivial-rewrite[11518]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:35:39 mailserver postfix/trivial-rewrite[11519]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:36:40 mailserver postfix/trivial-rewrite[11520]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:36:40 mailserver postfix/trivial-rewrite[11521]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:37:41 mailserver postfix/trivial-rewrite[11522]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:37:41 mailserver postfix/trivial-rewrite[11523]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:38:42 mailserver postfix/trivial-rewrite[11524]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:38:42 mailserver postfix/trivial-rewrite[11525]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:39:43 mailserver postfix/trivial-rewrite[11537]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:39:43 mailserver postfix/trivial-rewrite[11538]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:40:44 mailserver postfix/trivial-rewrite[11539]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:40:44 mailserver postfix/trivial-rewrite[11540]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:41:45 mailserver postfix/trivial-rewrite[11543]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:41:45 mailserver postfix/trivial-rewrite[11544]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:42:46 mailserver postfix/trivial-rewrite[11548]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:42:46 mailserver postfix/trivial-rewrite[11549]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:43:47 mailserver postfix/trivial-rewrite[11552]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:43:47 mailserver postfix/trivial-rewrite[11553]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:44:48 mailserver postfix/trivial-rewrite[11556]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:44:48 mailserver postfix/trivial-rewrite[11557]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:45:49 mailserver postfix/trivial-rewrite[11563]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:45:49 mailserver postfix/trivial-rewrite[11564]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:46:46 mailserver authdaemond: failed to connect to mysql server (server=localhost, userid=mail_admin): Access denied for user 'mail_admin'@'localhost' (using password: YES)
Jun 1 20:46:46 mailserver imapd: authentication error: Input/output error
Jun 1 20:46:50 mailserver postfix/trivial-rewrite[11569]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:46:50 mailserver postfix/trivial-rewrite[11570]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:47:51 mailserver postfix/trivial-rewrite[11595]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 20:47:51 mailserver postfix/trivial-rewrite[11596]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem


Anyone that could give me a hint or two?

PS... later. It seems that I may have missunderstood some courier and postfix config files. It says often "=mail_admin" and "=mail_admin_password". Should I replace these with my own of what? In Ubuntu I logged in as with a local user name/password, should I use that? Sorry for that question but I'm a newbie here, so please bare with me

PS... even later! Changed all "mail_admin" to my name, which is a local user on this computer, and the "mail_admin_password" to my local password on all places mentioned in the HowTo article, but with no luck. Still gives me the following in the /var/log/mail.err:

Jun 1 21:20:16 mailserver imapd: authentication error: Input/output error
Jun 1 21:20:27 mailserver authdaemond: failed to connect to mysql server (server=localhost, userid=lars): Access denied for user 'lars'@'localhost' (using password: YES)
Jun 1 21:20:27 mailserver imapd: authentication error: Input/output error
Jun 1 21:20:53 mailserver postfix/trivial-rewrite[12101]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 21:21:54 mailserver postfix/trivial-rewrite[12102]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem
Jun 1 21:22:55 mailserver postfix/trivial-rewrite[12103]: fatal: proxy:mysql:/etc/postfix/mysql-virtual_domains.cf(0,lock|fold_fix): table lookup problem


TIA

Last edited by spaceuser; 1st June 2008 at 21:26.
Reply With Quote
  #5  
Old 2nd June 2008, 02:04
thecaoticone thecaoticone is offline
Member
 
Join Date: Nov 2007
Posts: 89
Thanks: 1
Thanked 18 Times in 16 Posts
Default

From the error it looks like the first problem is in /etc/postfix/mysql-virtual_domains.cf

I would re-check the entire file for errors. With this setup, voice of experience now talking,
any little typo will cause problems. It is usually the password. It must be identical ( MyPassworD is not the same as mypassword ).


Make sure MySQL is running by issuing the command:


netstat -tap | grep mysql


If it is running you should see something like:


tcp 0 0 localhost.localdo:mysql *:* LISTEN 6177/mysqld



As far as the user and password, you will set that in MySQL, page 1 of the guide. It can be anything you want. This will be your mail adminisrtator.



GRANT SELECT, INSERT, UPDATE, DELETE ON mail.* TO 'who_ever_I_choose'@'localhost' IDENTIFIED BY 'My_Secret_PassWord';
GRANT SELECT, INSERT, UPDATE, DELETE ON mail.* TO 'who_ever_I_choose'@localhost.localdomain' IDENTIFIED BY 'My_Secret_PassWord';
FLUSH PRIVILEGES;



The user and password you specify here is the same user and password you will need to use throughout the entire setup.

It will need to be indentical in the following files:

/etc/postfix/mysql-virtual_domains.cf

/etc/postfix/mysql-virtual_forwardings.cf

/etc/postfix/mysql-virtual_mailboxes.cf

/etc/postfix/mysql-virtual_email2email.cf

/etc/postfix/mysql-virtual_transports.cf

/etc/postfix/mysql-virtual_mailbox_limit_maps.cf

/etc/pam.d/smtp

/etc/postfix/sasl/smtpd.conf

/etc/courier/authmysqlrc




Also make sure that you changed the line in:


/etc/courier/authdaemonrc



from:

authmodulelist="authpam"


to:

authmodulelist="authmysql"



Hope this helped.

Last edited by thecaoticone; 2nd June 2008 at 02:20.
Reply With Quote
  #6  
Old 2nd June 2008, 21:36
spaceuser spaceuser is offline
Junior Member
 
Join Date: May 2008
Posts: 20
Thanks: 0
Thanked 0 Times in 0 Posts
Default

This is strange. I did find an typo, but after restarting everything, it still gives me the same error in Squirrelmail web page, ERROR:
ERROR: Connection dropped by IMAP server.


It's also strange that it says that I have a new mail in /var/mail/lars instead of /home/vmail (See below):

root@mailserver:~# mysql -u root -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 26
Server version: 5.0.51a-3ubuntu5.1 (Ubuntu)

Type 'help;' or '\h' for help. Type '\c' to clear the buffer.

mysql> INSERT INTO `domains` (`domain`) VALUES ('mydomain.xx.');
mysql> USE mail;
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Database changed
mysql> INSERT INTO `domains` (`domain`) VALUES ('mydomain.xx');
mysql> quit
Bye
You have new mail in /var/mail/lars
root@mailserver:~#


When i use mailx to send a message to my domain, the /var/log/mail.log says:
Jun 2 21:27:37 mailserver postfix/pickup[25650]: D85FE122164: uid=0 from=<root>
Jun 2 21:27:37 mailserver postfix/cleanup[25777]: D85FE122164: message-id=<20080602192737.D85FE122164@mailserver.vas.net>
Jun 2 21:27:37 mailserver postfix/qmgr[25652]: D85FE122164: from=<root@mailserver.vas.net>, size=310, nrcpt=1 (queue active)
Jun 2 21:27:45 mailserver postfix/smtpd[25786]: connect from localhost[127.0.0.1]
Jun 2 21:27:45 mailserver postfix/smtpd[25786]: 4CFEE122137: client=localhost[127.0.0.1]
Jun 2 21:27:45 mailserver postfix/cleanup[25777]: 4CFEE122137: message-id=<20080602192737.D85FE122164@mailserver.vas.net>
Jun 2 21:27:45 mailserver postfix/qmgr[25652]: 4CFEE122137: from=<root@mailserver.vas.net>, size=756, nrcpt=1 (queue active)
Jun 2 21:27:45 mailserver postfix/smtpd[25786]: disconnect from localhost[127.0.0.1]
Jun 2 21:27:45 mailserver postfix/virtual[25789]: 4CFEE122137: to=<lars@mydomain.xx>, relay=virtual, delay=0.56, delays=0.04/0.39/0/0.13, dsn=5.1.1, status=bounced (unknown user: "lars@mydomain.xx")
Jun 2 21:27:45 mailserver postfix/cleanup[25777]: D71841221A5: message-id=<20080602192745.D71841221A5@mailserver.vas.net>
Jun 2 21:27:45 mailserver postfix/qmgr[25652]: D71841221A5: from=<>, size=2603, nrcpt=1 (queue active)
Jun 2 21:27:45 mailserver postfix/bounce[25790]: 4CFEE122137: sender non-delivery notification: D71841221A5
Jun 2 21:27:45 mailserver postfix/qmgr[25652]: 4CFEE122137: removed
Jun 2 21:27:45 mailserver amavis[25673]: (25673-03) Passed CLEAN, <root@mailserver.vas.net> -> <lars@mydomain.xx>, Message-ID: <20080602192737.D85FE122164@mailserver.vas.net>, mail_id: YnhavBpMFQn9, Hits: 1.862, size: 310, queued_as: 4CFEE122137, 7793 ms
Jun 2 21:27:46 mailserver postfix/smtp[25780]: D85FE122164: to=<lars@mydomain.xx>, relay=127.0.0.1[127.0.0.1]:10024, delay=8.3, delays=0.17/0.13/0.14/7.9, dsn=2.0.0, status=sent (250 2.0.0 Ok: queued as 4CFEE122137)
Jun 2 21:27:46 mailserver postfix/qmgr[25652]: D85FE122164: removed
Jun 2 21:27:46 mailserver postfix/local[25792]: D71841221A5: to=<root@mailserver.vas.net>, relay=local, delay=0.23, delays=0.03/0.17/0/0.03, dsn=2.0.0, status=sent (delivered to mailbox)
Jun 2 21:27:46 mailserver postfix/qmgr[25652]: D71841221A5: removed


The user email "lars@mydomain.xx" is proven to be inside the users table.

No errors in /var/log/mail.err for the above.

TIA

Last edited by spaceuser; 2nd June 2008 at 21:38.
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
Virtual Users And Domains With Postfix, Courier, MySQL And SquirrelMail -Ubuntu 8.04 c4rdinal HOWTO-Related Questions 112 23rd August 2011 10:49
Virtual Users And Domains With Ubuntu 8.04 mikeyr Suggest HOWTO 12 8th May 2009 15:47
Virtual Users And Domains With Postfix, Courier, MySQL And SquirrelMail Ubuntu 8.04 paulodani HOWTO-Related Questions 7 4th June 2008 00:46
Virtual Users And Domains With Postfix, Courier, MySQL And SquirrelMail (Ubuntu 8.04 mtzcesar HOWTO-Related Questions 3 1st June 2008 10:57
Junk mail and spamassassin... sthompson Installation/Configuration 4 27th December 2006 16:11


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


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