Help Setting Up Mail Server

Whether you are using Linux on the desktop or as a server, it's still good that you're using Linux. Linux related questions go here.

Moderator: General Moderators

Post Reply
User avatar
Kadanis
Forum Contributor
Posts: 180
Joined: Tue Jun 20, 2006 8:55 am
Location: Dorset, UK
Contact:

Help Setting Up Mail Server

Post by Kadanis »

Hey all

Pretty new to Linux so please bear with me ;) I've got Fedora Core 4 installed on a testing server (the install was done by the other developer who has since left the company), and I now need to get the email server running on it. I know the sending is running OK as I can send mails via the php sendmail command, but they always come from charlie.localhost. (charlie being the name of the server). There is a domain set up with A records and MX records pointing at the servers static IP which I would like to be able to use for the emails.

Can anyone point me in the right direction. Basically, I need to get the out going mails to come from the domain, then any replies / bounces to be collected in the mailbox for a php script to parse over.

I googled this but didn't find too much out there (maybe I'm a crap googler) but so far all I can tell is that I think I need to use PostFix, and Dovecot.

Any advice, links, instructions etc would be very much appreciated....

D
User avatar
Kadanis
Forum Contributor
Posts: 180
Joined: Tue Jun 20, 2006 8:55 am
Location: Dorset, UK
Contact:

Post by Kadanis »

Never mind, think i got it. Still can't log on to the server from a mail client (for some reason the login fails) but the send and recieve works so hopefully i'll be just fine.

D
Stickle
Forum Newbie
Posts: 4
Joined: Tue Sep 12, 2006 3:24 am
Location: Malaga, Spain

Post by Stickle »

Have you checked your logs Kadanis?

cd /var/log/
tail | maillog

Is it possible to paste the info it displays?

Hopefully you should see why you are receiving errors at login. With postfix usernames can sometimes need to be "user.domain", so might be an idea to look at...

Cheers

Rob
User avatar
Kadanis
Forum Contributor
Posts: 180
Joined: Tue Jun 20, 2006 8:55 am
Location: Dorset, UK
Contact:

Post by Kadanis »

as i said bit of a noob at linux, but all i get from the command you suggested is bash: command maillog not found...
Stickle
Forum Newbie
Posts: 4
Joined: Tue Sep 12, 2006 3:24 am
Location: Malaga, Spain

Post by Stickle »

My bad, I put in the "|" by mistake...

try the following:-

cd /
cd var/log/
tail maillog

Alternatively you could try "less maillog" instead of "tail maillog" and it will display more information...

That will give you the result I mentioned before...
User avatar
Kadanis
Forum Contributor
Posts: 180
Joined: Tue Jun 20, 2006 8:55 am
Location: Dorset, UK
Contact:

Post by Kadanis »

here's the log, but i don't see any connections from the mail client.... just sends

Sep 12 11:07:01 charlie postfix/smtpd[3422]: connect from charlie.localnet[127.0.0.1]
Sep 12 11:07:01 charlie postfix/smtpd[3422]: EFD70F00AB: client=charlie.localnet[127.0.0.1]
Sep 12 11:07:02 charlie postfix/cleanup[3423]: EFD70F00AB: message-id=<268d8beb508a885bed3e593445e71fa7@localhost.localdomain>
Sep 12 11:07:02 charlie sendmail[3421]: k8CA71Za003421: to=email@mydomain.com, ctladdr=root (0/0), delay=00:00:01, xdelay=00:00:01, mailer=relay, pri=31964, relay=[127.0.0.1] [127.0.0.1], dsn=2.0.0, stat=Sent (Ok: queued as EFD70F00AB)
Sep 12 11:07:02 charlie postfix/qmgr[2129]: EFD70F00AB: from=<root@charlie.localnet>, size=2279, nrcpt=1 (queue active)
Sep 12 11:07:02 charlie postfix/smtpd[3422]: disconnect from charlie.localnet[127.0.0.1]
Sep 12 11:07:02 charlie postfix/smtp[3424]: EFD70F00AB: to=<email@mydomain.com>, relay=mail.mydomain.com[my ip], delay=1, status=sent (250 2.6.0 2286 bytes received in 00:00:00; Message id QBP01539 accepted for delivery)
Sep 12 11:07:02 charlie postfix/qmgr[2129]: EFD70F00AB: removed
Sep 12 11:47:29 charlie dovecot: Killed with signal 15
Sep 12 11:47:43 charlie dovecot: Dovecot starting up

nb the email@mydomain.com and mail.mydomain.com are replaced just to keep email stuff off the web ;)
Post Reply