IMAP Email server install and config

This forum is dedicated to advanced help and support :

Ask here your questions about advanced usage of Mageia. For example you may post here all your questions about network and automated installs, complex server configurations, kernel tuning, creating your own Mageia mirrors, and all tasks likely to be touchy even for skilled users.

IMAP Email server install and config

Postby xboxboy » Sep 7th, '18, 16:28

I wish to use an open source app on my android phone to back up my SMS's. This is the app I'm thinking of using:
https://play.google.com/store/apps/details?id=com.zegoggles.smssync

Is it possible to set up an IMAP server on my home LAN, so it's not web facing, but my phone can back up the SMS's to it?

I've never done an email server/system, so I have no idea where to start, or even what software I need to install.

TIA.
xboxboy
 
Posts: 292
Joined: Jun 2nd, '13, 06:41

Re: IMAP Email server install and config

Postby JoesCat » Sep 13th, '18, 08:45

If security or privacy for the SMS is not an issue, it would be far easier to simply use an external email provider and be done with it.
If you're trying to learn email or are simply a gluteon for punishment, then this is the way to go :-)

I haven't looked at email in a while, but when I looked a few years ago, postfix would be the preferred server vs sendmail. Maybe things have changed, or maybe something better is available now, but assuming others don't suggest something else, or better, I would suggest you start with googling how to setup postfix as the mail server to choose/use.

1) To keep things simpler to avoid conflicts with external mail servers you would want to access, I would suggest setting your wan/lan router to allow some space for some static addresses because your (internal) mail server should be on a static address.... for example, supposing your lan is 192.168.0.xxx, and a gateway of 192.168.0.0 I would set your router to assign addresses 100...254 for dhcp, and then your mail server would sit in the static range, for example 192.168.0.5 - this is the address you would eventually set your android phone to access, meanwhile, all your dhcp stuff ends up in the mish-mash of 192.168.0.{100..254}.
2) to keep things simpler to avoid conflicts with mail servers you want to access, I would suggest using odd non-standard ports for your android mail server instead of the usual default ports. This could then firewall at your router to block in both directions for extra insurance in case you haven't configured everything ok.

3) I'd recommend setting up a fresh mageia install on the "mail server" computer. You will want to install with higher msec values (older msec was 4 or 5, newer msec is server level), and set the mageia firewall to have open ports for your non-standard imap ports when you're ready to give it a go. The higher msec security will cause havok with some programs you typically use if you were running a general laptop client, so you'll be opening-up some security settings to share the computer if this is both a server and your main computer for regular use. I suggest reading up on msec and how to customize settings.

4) readup on configuring postfix in the /etc directory for the non-standard ports so that when it starts running, it appears on these non-standard ports.
5) readup on openssh, you may need to create certificates, but hopefully not required since you're accessing 192.168.0.5 - accessing by url gets much more complicated
6) postfix won't be running as 'root', so you'll also need to ensure all the right users and user permissions are set for affected directories.
7) when you install postfix, you should be able to autorun it on bootup - check the mageia control center. When setup, it will be running a daemon.
8) setting up postfix is doable, just go one step at a time, with your main focus being security, security, security as you go from successful step to next successful step.

This by no means is complete, but hopefully points you in the right directions to go read further on where you need to go.
mailserver summary - static internal IP of 192.168.0.5, wan/lan router firewalled, use non-standard ports to avoid conflicting with other things on your network
android phone summary - connects to static 192.168.0.5, non-standard ports.

Maybe other readers have other/better suggestions.
User avatar
JoesCat
 
Posts: 96
Joined: Sep 15th, '11, 04:27
Location: Richmond, BC, Canada

Re: IMAP Email server install and config

Postby xboxboy » Sep 14th, '18, 03:34

Thanks JoesCat, that's quite a write up. Looks like I'm up for some reading and fun :)
xboxboy
 
Posts: 292
Joined: Jun 2nd, '13, 06:41

Re: IMAP Email server install and config

Postby wintpe » Oct 11th, '18, 16:06

I run just what you want at home for email.

you surly wont want this only accessible when your within range of your wifi, better to make your internal servers securely accessible over the internet.

then use your 4g to access the home server.

thats what i do.

I run aquamail on my phone, and openvpn client , and my phone first gets a vpn connection to home.

at that point your phone can remote control everything at home, use connectbot for example to ssh into any system at home.

for vpn at home there are various solutions, the simplest may already be available in your broadband router.

I use a rasberrypie 2 running fedora 28, for mine.

so application.

well you could go the difficult route and assemble postfix, dovecote, postgress etc but instead just install citadel http://www.citadel.org/doku.php

the whole thing is all done for you.

it has its own built in smtp server/secure smtp, database, web interface, and imap mailserver/builitin board in one.

its so simple to setup.

ive been running it for 6 years non stop, with never a hitch.

I would not for reasons of longevity , run it on mageia however. mageia needs upgrading every two years maximum, and its sometimes disruptive.

not what you need on a mail server, that your grow to depend on.

instead use centos 7 , which you will find familiar with mageia. but which 100% cleanly updates between minor revs, and will not need major rev update till June 30th, 2024

regards peter
Redhat 6 Certified Engineer (RHCE)
Sometimes my posts will sound short, or snappy, however its realy not my intention to offend, so accept my apologies in advance.
wintpe
 
Posts: 1177
Joined: May 22nd, '11, 17:08
Location: Rayleigh,, Essex , UK

Re: IMAP Email server install and config

Postby xboxboy » Oct 12th, '18, 00:03

I'll investigate that more when I have time, thanks Peter.
xboxboy
 
Posts: 292
Joined: Jun 2nd, '13, 06:41


Return to Advanced support

Who is online

Users browsing this forum: No registered users and 1 guest