LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 01-18-2011, 05:13 AM   #1
fusion1275
Member
 
Registered: Jul 2007
Location: Portsmouth, Hants
Distribution: Linux Mint
Posts: 274

Rep: Reputation: 35
Mail Server - Relay access denied - What on earth is this?


When testing my mail server setup using MX tools website I get the following:

Code:
HELO please-read-policy.mxtoolbox.com
250 mail.mymail.com [140 ms]
MAIL FROM: <supertool@mxtoolbox.com>
250 2.1.0 Ok [125 ms]
RCPT TO: <test@example.com>
554 5.7.1 <test@example.com>: Relay access denied [140 ms]
QUIT
221 2.0.0 Bye [125 ms
Can someone give me a clue as to what this might mean?

Thanks
 
Old 01-18-2011, 05:27 AM   #2
repo
LQ 5k Club
 
Registered: May 2001
Location: Belgium
Distribution: Arch
Posts: 8,528

Rep: Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899
Take a look at
http://en.wikipedia.org/wiki/Open_mail_relay


Kind regards
 
Old 01-18-2011, 06:28 AM   #3
fusion1275
Member
 
Registered: Jul 2007
Location: Portsmouth, Hants
Distribution: Linux Mint
Posts: 274

Original Poster
Rep: Reputation: 35
Hi repo,

Thanks for that but I am still very unclear. So how do I go about making this work using postfix? I have the DNS side set up as per my existing thread:

Code:
http://www.linuxquestions.org/questions/linux-newbie-8/mx-records-a-records-cname-records-advice-please-856658/
Any help would be very helpful.

Thanks a lot
 
Old 01-18-2011, 06:43 AM   #4
redgoblin
Member
 
Registered: Jun 2005
Location: UK
Distribution: Debian
Posts: 189

Rep: Reputation: 41
Quote:
So how do I go about making this work using postfix
You don't want to. You really, really, don't want to.

In that test mxtoolbox.com is testing whether or not it can send email to example.com via your MTA. "Relay access denied" is what you want to see. If it was successful you'd quickly find your server being used to relay large volumes of spam. Open mail relays are one of the things that bot's search for across entire IP ranges.

What are you actually trying to achieve? Being able to send mail from that machine? use it as a relay on an internal network? Let selected outside users relay email through it? Or allow the whole world and it's dog to be able to relay mail through it?

Last edited by redgoblin; 01-18-2011 at 06:44 AM. Reason: Spelling, syntax
 
Old 01-18-2011, 06:56 AM   #5
fusion1275
Member
 
Registered: Jul 2007
Location: Portsmouth, Hants
Distribution: Linux Mint
Posts: 274

Original Poster
Rep: Reputation: 35
My aim for this is to do the following...

1) My wife and I to be able to receive email from the outside world
2) My wife and I to be able to send email from the inside to the outside world
3) To have it secure using whatever means and to have a working spam program that will pick up the nasty stuff

As I said in my previous mail (link above) I already had a setup but my ISP decided to go out of business so I had the idea of starting the "whole" email process myself instead of using the ISP's smtp servers to connect fetchmail/postfix/dovecot etc etc.

Cheers
 
Old 01-18-2011, 06:59 AM   #6
repo
LQ 5k Club
 
Registered: May 2001
Location: Belgium
Distribution: Arch
Posts: 8,528

Rep: Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899
Quote:
2) My wife and I to be able to send email from the inside to the outside world
Do you have a fixed IP for your mailserver?
If not, your mail will be refused by other smtp servers.

Kind regards
 
Old 01-18-2011, 07:09 AM   #7
fusion1275
Member
 
Registered: Jul 2007
Location: Portsmouth, Hants
Distribution: Linux Mint
Posts: 274

Original Poster
Rep: Reputation: 35
Yeah I have a static IP from my ISP which I have routed to the mail server via my routers settings
 
Old 01-18-2011, 07:26 AM   #8
redgoblin
Member
 
Registered: Jun 2005
Location: UK
Distribution: Debian
Posts: 189

Rep: Reputation: 41
Fusion

A few different questions there.

As for your other questions they might require individual threads (if any of them aren't working the way you want) a long with setup, etc. Start from the bottom up; get mail working between accounts on the server, within the LAN, going out, then comming in.

Having a static IP is a very good start. You might need to have reverse DNS set up for your IP address as well as many mail servers are very strict about these things. I've been running my own mail server on a UK DSL line for several years and it's proven to be fast and secure.

In relation to your original post (on this thread) I think you've got your answer; refusing to relay is a good thing! Does that cover your original question?
 
Old 01-18-2011, 07:29 AM   #9
repo
LQ 5k Club
 
Registered: May 2001
Location: Belgium
Distribution: Arch
Posts: 8,528

Rep: Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899
Besides the reverse dns, also consider a backup MX record, in case your server or the connection are down.

Kind regards
 
Old 01-18-2011, 07:33 AM   #10
fusion1275
Member
 
Registered: Jul 2007
Location: Portsmouth, Hants
Distribution: Linux Mint
Posts: 274

Original Poster
Rep: Reputation: 35
I was told that if I get a backup MX then I will need another IP???

Is that correct or can I simply just create a secondary MX with the setup I have now???
 
Old 01-18-2011, 07:50 AM   #11
teebones
Member
 
Registered: Aug 2005
Location: /home/teebones
Distribution: sometimes this, sometimes that..
Posts: 502

Rep: Reputation: 56
Quote:
Originally Posted by repo View Post
Do you have a fixed IP for your mailserver?
If not, your mail will be refused by other smtp servers.

Kind regards
????????????????
what has a dynap to do with not being able to send out mail.. (the MTA won't mind which ip it has, as long as it can find the destination) (and the receiving mta won't mind either for that matter)
 
Old 01-18-2011, 07:51 AM   #12
repo
LQ 5k Club
 
Registered: May 2001
Location: Belgium
Distribution: Arch
Posts: 8,528

Rep: Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899
Most smtp servers refuse mail from a dynamic IP.

Kind regards
 
Old 01-18-2011, 08:00 AM   #13
teebones
Member
 
Registered: Aug 2005
Location: /home/teebones
Distribution: sometimes this, sometimes that..
Posts: 502

Rep: Reputation: 56
only BAD configured smtp's do that. PBL blocking e.g. (spamhaus)
PBL is not a blacklist, although some lame ass mta administrators think so (because they block every IP in the PBL, thus lots of problems for their customers).

An MTA purely by itself would not know if the IP of the sender is Dynamic or static.
Secondly, infact each IP is dynamic in technical terms, since each netblock can be revoked, used as the LIR wants etc..
Can change as see fit...(thus dynamic)
 
Old 01-18-2011, 08:38 AM   #14
fusion1275
Member
 
Registered: Jul 2007
Location: Portsmouth, Hants
Distribution: Linux Mint
Posts: 274

Original Poster
Rep: Reputation: 35
Hey guys thanks for the replies but this is getting a bit out of my realms of knowledge for a simple email server.

So is it possible for me to create this so I can send and receive mail? If so can you give me some guidelines please.

Static IP --> pointing to mail server --> Postfix --> dovecot --> email client


Cheers
 
Old 01-18-2011, 10:18 AM   #15
repo
LQ 5k Club
 
Registered: May 2001
Location: Belgium
Distribution: Arch
Posts: 8,528

Rep: Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899
Quote:
Originally Posted by fusion1275 View Post
Hey guys thanks for the replies but this is getting a bit out of my realms of knowledge for a simple email server.

So is it possible for me to create this so I can send and receive mail? If so can you give me some guidelines please.

Static IP --> pointing to mail server --> Postfix --> dovecot --> email client


Cheers
Yes.
Can you sent mail?
Can you receive mail?

Kind regards
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Use postfix send mail return 'relay access denied' ??need help!! xiaolong85 Linux - Server 6 01-24-2010 01:36 PM
Relay access denied while sending from external mail clients spokz Linux - Server 2 11-16-2008 09:47 AM
Postfix Relay access denied outgoing mail alitrix Linux - Server 2 06-14-2008 04:38 PM
Postfix: Relay access denied whenever sending e-mail Doug52392 Linux - Server 1 11-11-2007 05:21 AM
Postfix as a mail relay (getting relay access denied) hypexr Linux - Software 3 09-13-2005 08:15 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 04:37 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration