Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
update Urgent request re: mail server configuration....
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
dspahn
Guru
Guru


Joined: 22 Jun 2006
Posts: 392

PostPosted: Wed Aug 20, 2008 4:06 pm    Post subject: update Urgent request re: mail server configuration.... Reply with quote

I apologize if this should go into unsupported software, but I am completely lost at this point in trying to set up a postfix mailserver. The last time I set up a mailserver, it was a qmail server, and that was 2 years ago. The qmail server is getting a number of bouncebacks from recipient systems that the MTA is of ill repute and that its messages will not be accepted. This forum provided great advice, to use (among others) postfix as a mail server. I have rebuilt this (formerly FC6) server to be a Gentoo server... and now I'm stuck. .Getting support at the Postfix site is a maze at best, and my issue really is fairly simple for anyone proficient at mail sever configuration. I want to setup Postfix to accept email from another machine (scanner) on the same subnet and relay it to the recipients requested by the scanner. The scanner is 192.168.1.3 and the Postfix server is 192.168.1.4.

First, how do I set the main.cf and master.cf files?
Second, how do I add a user to this mailserver as a sender?

Is there any other configuration I need to do?
I have spent the past 3 days researching this, and this forum is the only place I have left to turn for help.... I appreciate any advice.

Thanks!

Edit: I finally got the web interface with Postfixadmin to send mail... and after sending one mail successfully from a mail client, I started getting connection refusals reported by the mail client. Any idea what's going on?
Back to top
View user's profile Send private message
kashani
Advocate
Advocate


Joined: 02 Sep 2002
Posts: 2032
Location: San Francisco

PostPosted: Wed Aug 20, 2008 5:42 pm    Post subject: Reply with quote

Let's see the output of postconf -n and that should make troubleshooting far easier.

In order to allow 192.168.1.3 relay email to your server I would add the IP address to mynetworks in your /etc/postfix/main.cf

Code:
mynetworks = 127.0.0.0/8 192.168.1.3/32


I'm not sure what you mean by "Second, how do I add a user to this mailserver as a sender?" Do you want to add a user account to the server? Or do you want to allow more machines to relay email through your mail server?

kashani
_________________
Will personally fix your server in exchange for motorcycle related shop tools in good shape.
Back to top
View user's profile Send private message
dspahn
Guru
Guru


Joined: 22 Jun 2006
Posts: 392

PostPosted: Wed Aug 20, 2008 6:05 pm    Post subject: I'll do that.... Reply with quote

OK, I'll try that.
I did figure out adding a user- i turns out I was having trouble because of a bug/feature in postfixadmin. The workaround was to turn off automatic domain resolution.

What exactly does that /32 mean? I've seen the /24 and /8, but never a /32.

I also figured out why I could send from Postfixadmin but not from a test external client- I had not committed some changes to the inet interfaces variable, which I had set to 127.0.0.1 only, as part of a walkthrough during some of my troubleshooting. So far, I have been working in a test environment. I'm going to take the machine on site to go live shortly. Any configuration ideas to try to keep the address out of junk mailboxes?
Back to top
View user's profile Send private message
dspahn
Guru
Guru


Joined: 22 Jun 2006
Posts: 392

PostPosted: Thu Aug 21, 2008 4:20 pm    Post subject: Where are the logs? Reply with quote

Thanks for your help- the mailserver is up and running... but I am feeling a little 'inadequate', as I cannot find the logs.
They are not in the normal locations, so I am guessing they are not being created. What do I need to do to enable the logging, or to find the location?
Back to top
View user's profile Send private message
kashani
Advocate
Advocate


Joined: 02 Sep 2002
Posts: 2032
Location: San Francisco

PostPosted: Thu Aug 21, 2008 5:28 pm    Post subject: Reply with quote

You probably know that a /24 is 256 addresses. 32 bits - 24 bits = 8 bits = 256 numbers = 256 IP addresses. A /32 is a single IP address. You asked for one IP address so it's a /32.

Gentoo has a stupid default where it pipes everything into /var/log/messages. Add these lines to your /etc/syslog-ng/syslog-ng.conf file.

Code:

destination mail { file("/var/log/mail.log"); };

filter f_mail { facility(mail); };
filter f_messages { level(info..warn) # this line should already exist
        and not facility(mail); };    # make sure this line is under the above line.

log { source(src); filter(f_mail); destination(mail); };


You might want to look at my PostfixAdmin how-to on the Gentoo Wiki.
http://gentoo-wiki.com/HOWTO_Setup_a_Virtual_Postfix/Courier_Mail_System_with_PostfixAdmin

kashani
_________________
Will personally fix your server in exchange for motorcycle related shop tools in good shape.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum