Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > Linux Forums > HOWTO-Related Questions

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 19th March 2008, 19:48
Leichtweis Leichtweis is offline
Junior Member
 
Join Date: Mar 2008
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default Ubuntu Server 7.10 Postfix issue

I am attempting to configure postfix for my buddies Ubuntu server. He already had all the normal web stuff set up (ftp, PHP, mySQL, ect.) except for postfix.
Having used Falko's guide to set up my Centos server I figured it would be easy.

So I followed Falko's instructions on setting up Postfix With SMTP-AUTH And TLS in Ubuntu Server 7.10 HERE. Everything seemed to go fine. Followed all prompts everything looked good. I installed Courier-POP everything there looked fine.
So I figured I would test the setup. Did this
Code:
telnet localhost 25

Trying 127.0.0.1...
Connected to mail.pinpunk.com.
Escape character is '^]'.
220 mail.pinpunk.com ESMTP Postfix (Ubuntu)

ehlo localhost
250-mail.pinpunk.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

mail from: root@localhost
rcpt to: user@localhost
data
Subject: My first mail on Postfix

Hi,
Are you there?
regards,
Admin[
. 
quit
Ok that worked fine, I got the mail so then I tried to send it to my peronal e-mail:


Code:
telnet mail.pinpunk.com 25

Trying 127.0.0.1...
Connected to mail.pinpunk.com.
Escape character is '^]'.
220 mail.pinpunk.com ESMTP Postfix (Ubuntu)

ehlo pinpunk.com
250-mail.pinpunk.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

mail from: root@pinpunk.com
rcpt to: me@gmail.com  <---used my gmail address
554 5.7.1 <me@gmail.com>: Relay access denied
Thats the error I get. Can't figure it out. But what I thought was odd is that I telneted back under localhost 25 and sent a mail from root@localhost to my gmail and it worked fine.

If you guys could help a guy out it would be greatly appreciated.

Thanks, Dan

Last edited by Leichtweis; 19th March 2008 at 23:52.
Reply With Quote
Sponsored Links
  #2  
Old 20th March 2008, 17:54
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,711
Thanks: 1,899
Thanked 2,702 Times in 2,545 Posts
Default

Any errors in your mail log?
Is the server running on a dynamic IP address?
__________________
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
  #3  
Old 20th March 2008, 19:32
Leichtweis Leichtweis is offline
Junior Member
 
Join Date: Mar 2008
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by falko
Any errors in your mail log?
Is the server running on a dynamic IP address?
I have more errors in the log then I know what do do with. I am not sure where to start.

The server is running on a static IP.

Here is a snip it of the mail.log

Code:
Mar 19 03:22:04 ubuserver postfix/smtpd[12493]: connect from unknown[122.163.253.115]
Mar 19 03:22:07 ubuserver postfix/smtpd[12493]: NOQUEUE: reject: RCPT from unknown[122.163.253.115]: 554 5.7.1 <ab@nutscape.$
Mar 19 03:22:07 ubuserver postfix/smtpd[12493]: lost connection after RCPT from unknown[122.163.253.115]
Mar 19 03:22:07 ubuserver postfix/smtpd[12493]: disconnect from unknown[122.163.253.115]
Mar 19 03:24:01 ubuserver postfix/smtpd[12767]: cannot load Certificate Authority data
Mar 19 03:24:01 ubuserver postfix/smtpd[12767]: warning: TLS library problem: 12767:error:02001002:system library:fopen:No s$
Mar 19 03:24:01 ubuserver postfix/smtpd[12767]: warning: TLS library problem: 12767:error:2006D080:BIO routines:BIO_new_file$
Mar 19 03:24:01 ubuserver postfix/smtpd[12767]: warning: TLS library problem: 12767:error:0B084002:x509 certificate routines$
Mar 19 03:24:01 ubuserver postfix/smtpd[12767]: connect from frostcatcher.com[66.93.0.30]
Mar 19 03:24:46 ubuserver postfix/smtpd[12767]: NOQUEUE: reject: RCPT from frostcatcher.com[66.93.0.30]: 554 5.7.1 <dan@metr$
Mar 19 03:25:32 ubuserver postfix/smtpd[12767]: disconnect from frostcatcher.com[66.93.0.30]
Mar 19 03:26:45 ubuserver postfix/anvil[12498]: statistics: max connection rate 1/60s for (smtp:66.7.178.144) at Mar 19 03:1$
Mar 19 03:26:45 ubuserver postfix/anvil[12498]: statistics: max connection count 1 for (smtp:66.7.178.144) at Mar 19 03:16:45
Mar 19 03:26:45 ubuserver postfix/anvil[12498]: statistics: max cache size 1 at Mar 19 03:16:45
Mar 19 03:26:55 ubuserver postfix/smtpd[12767]: connect from frostcatcher.com[66.93.0.30]
Mar 19 03:28:09 ubuserver postfix/smtpd[12767]: disconnect from frostcatcher.com[66.93.0.30]
Mar 19 03:31:24 ubuserver postfix/smtpd[13027]: cannot load Certificate Authority data
Mar 19 03:31:24 ubuserver postfix/smtpd[13027]: warning: TLS library problem: 13027:error:02001002:system library:fopen:No s$
Mar 19 03:31:24 ubuserver postfix/smtpd[13027]: warning: TLS library problem: 13027:error:2006D080:BIO routines:BIO_new_file$
Mar 19 03:31:24 ubuserver postfix/smtpd[13027]: warning: TLS library problem: 13027:error:0B084002:x509 certificate routines$
Mar 19 03:31:26 ubuserver postfix/smtpd[13027]: connect from cpe-66-68-250-175.rgv.res.rr.com[66.68.250.175]
Mar 19 03:31:26 ubuserver postfix/smtpd[13027]: disconnect from cpe-66-68-250-175.rgv.res.rr.com[66.68.250.175]
Mar 19 03:32:30 ubuserver postfix/smtpd[13027]: connect from unknown[121.34.228.65]
certificate verification problem? I don't know maybe I should just uninstall postfix and start over again?

Ok I reinstalled but I still get errors:
Code:
Mar 20 17:03:54 ubuserver postfix/smtpd[20449]: warning: cannot get certificate from file /etc/postfix/ssl/smtpd.crt
Mar 20 17:03:54 ubuserver postfix/smtpd[20449]: warning: TLS library problem: 20449:error:02001002:system library:fopen:No s$
Mar 20 17:03:54 ubuserver postfix/smtpd[20449]: warning: TLS library problem: 20449:error:20074002:BIO routines:FILE_CTRL:sy$
Mar 20 17:03:54 ubuserver postfix/smtpd[20449]: warning: TLS library problem: 20449:error:140DC002:SSL routines:SSL_CTX_use_$
Mar 20 17:03:54 ubuserver postfix/smtpd[20449]: cannot load RSA certificate and key data
Mar 20 17:03:54 ubuserver postfix/smtpd[20449]: connect from frostcatcher.com[66.93.0.30]
Mar 20 17:03:58 ubuserver postfix/smtpd[20455]: warning: cannot get certificate from file /etc/postfix/ssl/smtpd.crt
Mar 20 17:03:58 ubuserver postfix/smtpd[20455]: warning: TLS library problem: 20455:error:02001002:system library:fopen:No s$
Mar 20 17:03:58 ubuserver postfix/smtpd[20455]: warning: TLS library problem: 20455:error:20074002:BIO routines:FILE_CTRL:sy$
Mar 20 17:03:58 ubuserver postfix/smtpd[20455]: warning: TLS library problem: 20455:error:140DC002:SSL routines:SSL_CTX_use_$
Mar 20 17:03:58 ubuserver postfix/smtpd[20455]: cannot load RSA certificate and key data
Mar 20 17:03:59 ubuserver postfix/smtpd[20455]: connect from seven.pairlist.net[209.68.2.241]
Mar 20 17:03:59 ubuserver postfix/smtpd[20455]: NOQUEUE: reject: RCPT from seven.pairlist.net[209.68.2.241]: 554 5.7.1 <alle$
Mar 20 17:03:59 ubuserver postfix/smtpd[20455]: disconnect from seven.pairlist.net[209.68.2.241]
Mar 20 17:04:32 ubuserver postfix/smtpd[20449]: NOQUEUE: reject: RCPT from frostcatcher.com[66.93.0.30]: 554 5.7.1 <dan@metr$
Mar 20 17:04:49 ubuserver postfix/smtpd[20449]: disconnect from frostcatcher.com[66.93.0.30]
possible problem because of the hostname? in the log it shows it as frostcatcher.com but the domain I am trying to set up mail from is pinpunk.com I am so green to linux its not even funny.

Last edited by Leichtweis; 20th March 2008 at 22:13.
Reply With Quote
  #4  
Old 21st March 2008, 14:50
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,711
Thanks: 1,899
Thanked 2,702 Times in 2,545 Posts
Default

What's the output of
Code:
ls -la /etc/postfix/ssl
?
__________________
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
  #5  
Old 21st March 2008, 17:28
Leichtweis Leichtweis is offline
Junior Member
 
Join Date: Mar 2008
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by falko
What's the output of
Code:
ls -la /etc/postfix/ssl
?
Code:
total 28
drwxr-xr-x 2 root root 4096 2008-03-20 23:10 .
drwxr-xr-x 4 root root 4096 2008-03-21 01:00 ..
-rw-r--r-- 1 root root 1269 2008-03-20 23:10 cacert.pem
-rw-r--r-- 1 root root  963 2008-03-20 23:10 cakey.pem
-rw-r--r-- 1 root root  936 2008-03-20 23:09 smtpd.crt
-rw-r--r-- 1 root root  765 2008-03-20 23:08 smtpd.csr
-rw-r--r-- 1 root root  887 2008-03-20 23:09 smtpd.key
Reply With Quote
  #6  
Old 22nd March 2008, 17:03
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,711
Thanks: 1,899
Thanked 2,702 Times in 2,545 Posts
Default

Please run these commands again:
Code:
mkdir /etc/postfix/ssl
cd /etc/postfix/ssl/
openssl genrsa -des3 -rand /etc/hosts -out smtpd.key 1024

chmod 600 smtpd.key
openssl req -new -key smtpd.key -out smtpd.csr

openssl x509 -req -days 3650 -in smtpd.csr -signkey smtpd.key -out smtpd.crt

openssl rsa -in smtpd.key -out smtpd.key.unencrypted

mv -f smtpd.key.unencrypted smtpd.key
openssl req -new -x509 -extensions v3_ca -keyout cakey.pem -out cacert.pem -days 3650
__________________
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
  #7  
Old 27th March 2008, 23:02
Leichtweis Leichtweis is offline
Junior Member
 
Join Date: Mar 2008
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
 
Default

Ok I figured it out, there was never a problem. I was not attempting to authenticate (postfix wouldn't let me because its not a open relay) once I used a mail client and checked server requires authentication. Worked like a charm.

Thanks for everyones help!
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
Mail server using Postfix, Dovecot, Mysql... Postfix virtual maps doesn't work?? tarasbuljba HOWTO-Related Questions 33 28th May 2010 14:33
Mail System Error - Returned Mail tristanlee85 General 16 16th March 2008 09:40
The Perfect Server - Ubuntu Gutsy Gibbon (Ubuntu 7.10) B767Mike Installation/Configuration 5 18th January 2008 19:16
Centos 4.4 32bit Hangs, High Server load 3cwired_com Server Operation 11 16th November 2006 15:47
Verify email setup meekish Installation/Configuration 28 27th October 2006 15:36


All times are GMT +2. The time now is 00:13.


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