Mail Server Setup which route do I take.

The place to post if you need help or advice

Moderators: ChrisThornett, LXF moderators

Mail Server Setup which route do I take.

Postby Ram » Thu Apr 07, 2005 10:03 pm

Need help with this and the best way to do it.

What I want is to be able to set up IMAP so that the Wife, Children and me can log on to which ever PC ( have 3 ) and have the same mail format whether it be Linux or Windows.

I have a SuSE Server set up for File / Printing that the 3 PC connect to.

I have a hosted Website that also does my main mail and I also have mail through my ISP.

I want all mail dumped to my Server so that it can be read from any one of the 3 PCs via IMAP, the mail will remain on the server unless deleted.

The problem I got is understanding how I link Sendmail/Postfix, Courier IMAP and Fetchmail together. I understand what each bit does just not the type of mail service I need to run.

what type of server do I run ? SMTP, POP or IMAP

Ram
User avatar
Ram
LXF regular
 
Posts: 1679
Joined: Thu Apr 07, 2005 9:44 pm
Location: Guisborough

RE: Mail Server Setup which route do I take.

Postby crimmer » Sat Apr 09, 2005 1:49 pm

Sounds like a good approach.

I've got a similar setup, though most of my email comes directly to my home PC (I have a static IP address and have set the MX record for my domain). The rest comes from POP3 mailboxes at my hosting provider and my old dial-up ISP.

You'll need an imap server so that your other PCs can read the messages. You shouldn't use POP. But you also need postfix or sendmail to be running on the server so that fetchmail (also running on the server) can get the messages fetched from your ISP and from your hosted web site to be stored in the local mailboxes in /var/mail.

Hope this helps.

Chris.
crimmer
 
Posts: 3
Joined: Tue Apr 05, 2005 8:54 pm

RE: Mail Server Setup which route do I take.

Postby Guest » Sat Apr 09, 2005 5:17 pm

Cheers, I think it does.

Whats getting me is that in all the books I've read Fetchmail appears not to use IMAP but either POP or SMTP, so I suppose the point I keep missing is I that I need to set IMAP up to read /var/mail as the default location for mail collection

Ram
Guest
 

RE: Mail Server Setup which route do I take.

Postby nelz » Sat Apr 09, 2005 9:28 pm

Use Fetchmail to pull mail from your ISP mailbox(es) and deliver it to where your IMAP server can serve it.
"Insanity: doing the same thing over and over again and expecting different results." (Albert Einstein)
User avatar
nelz
Site admin
 
Posts: 8527
Joined: Mon Apr 04, 2005 11:52 am
Location: Warrington, UK

RE: Mail Server Setup which route do I take.

Postby marlight » Mon Apr 11, 2005 8:32 pm

I'll second the opinion in this months mag, and recommend Exim for SMTP as it supports Maildir storage. Use IMAP to offer up the email. That way you know where the email is (on the server), and folder structures are the same wherever you are. (Handy if you also access the mail account from work *cough*)

You can then use Courier to provide IMAP and POP3 access.

I've been running exactly this configuration for some time now, and it works just fine.

I also use fetchmail to pull email from my ISP and Gmail POP3 accounts. This gets delivered locally via Exim, and ends up in the correct Maildir directory, ready to be served up via IMAP.

The full exim config is probably too much for here, but the key points are:

* set your "real_local" router to use a maildir transport. (On my box, the transport is called "maildir_home".)
* The maildir_home transport looks like this:

maildir_home:
debug_print = "T: maildir_home for $local_part@$domain"
driver = appendfile
directory = $home/Mail/inbox
delivery_date_add
envelope_to_add
return_path_add
maildir_format
mode = 0600
mode_fail_narrower = false

In other words, each user has a directory called "Mail" in their $HOME. Below that is a sub-folder called "inbox", and exim drops the Maildir files in there.

I'm using Debian on the rust bucket I call a mail server and the Courier IMAP package for Debian defaults to using each user's home directory as the location for "Mail/inbox", so this all fits together very neatly.

Enabling SSL on Courier is also pretty easy if you want to encrypt between work^H^H^H^H wherever you happen to be, and the email server. A real practical use: Access from an Internet cafe with Mozilla Thunderbird on your 1GB USB key. You now that the traffic between your cafe provided PC and the server is safe from snooping.

Another bonus is that most decent webmail packages (IMP, squirrelmail, phpgroupware, etc) can use the Courier IMAP server out of the box. Stick an SSL cert on your web server, and you got webmail access to your personal email from Internet cafes that restrict USB key usage...

Anyway, more than 'nuff said!
marlight
 
Posts: 6
Joined: Mon Apr 11, 2005 7:52 pm

RE: Mail Server Setup which route do I take.

Postby Ram » Tue Apr 12, 2005 5:10 pm

Wow that some reply,

I'll let you know how I get on.

Thx

Ram.

lubuntu LXDE 13.10 running on AMD Phenom II*4; ASUS Crosshair III Formula MB; 4 GB Ram.....
User avatar
Ram
LXF regular
 
Posts: 1679
Joined: Thu Apr 07, 2005 9:44 pm
Location: Guisborough

RE: Mail Server Setup which route do I take.

Postby Guest » Fri Apr 15, 2005 12:30 pm

I set up Cyrus IMAP and Fetchamil last night

Fetchmail is pulling in mail for a test account I have set up that collects mail sent by my router ( just something to keep my NTLWorld addy ticking over ) which then pipes it through to Cyrus, Mail is sent to /var/spool/imap/user ( I take it, it got this info from YaST MTA configure 'Delivery by Cyrus IMAP as I only ran a novice Fetchmail setup with fetchmailconf ).

setup a imap account to test in outlook and its working OK.
One quark but could be just with outlook having no purge deleted.
I set a rule up to move the mail from my router into a new folder, ran the rule, this moved the mails from the inbox to the folder but left strikethrough copies in the inbox, I've seen this with Horde when using webmail from my paid fore hosted site, once the mails moved I can purge deleted and the strikethrough copies are removed.

One nice thing I noticed well tried and that was moving a outlook folder into the imap account and this worked with out a problem. That solved one of my next task in moving mail from my PST File over the Linux without the need to let Windows Thunderbird convert it and loading the TB mails into Linux :)

Just need to sort how the sending of the mail now.


Ram
Guest
 

RE: Mail Server Setup which route do I take.

Postby crimmer » Thu Apr 21, 2005 12:34 pm

Sending mail: either set up an SMTP server on the same machine where fetchmail and the IMAP server are running and point TB or Outlook at that, or point TB/Outlook at your ISP's SMTP server. Make sure your SMTP server can't be used as a relay for spam. If you don't know how to do that, ask here or use the second option, but definitely don't run an SMTP server on your main PC which is accessible to the outside internet.

Chris.
crimmer
 
Posts: 3
Joined: Tue Apr 05, 2005 8:54 pm


Return to Help!

Who is online

Users browsing this forum: No registered users and 2 guests