5 ms·
I'm not looking forward to setting up my first Linux mail server next week. Any tips for a fellow noob? There's so much information and so many guides out there
by lunarscape 15y ago
I'm not looking forward to setting up my first Linux mail server next week. Any tips for a fellow noob? There's so much information and so many guides out there I don't know where to begin.
Debain/Ubuntu have a tasksel for a mail server but I haven't tried it yet. (https://help.ubuntu.com/community/Tasksel https://help.ubuntu.com/community/Tasksel)
> sudo tasksel install mail-server
I plan on trying some other semi-automated installers like iRedMail (http://www.iredmail.org/ http://www.iredmail.org/) in a VM first.
- jiggy2011 15y agoYes, if you can test it all out in a VM. Also keep frequent backups of your .conf files. The main log file of interest will be /var/log/mail.log check that everytime you change something as many errors that are silent elsewhere will end up here. It would be quite difficult to write a decent guide in a short space (also I have not quite got my setup correct yet), but make sure you RTFM before you start. Depending on how many users you have, if you are using postfix it may be easier to just map the users mail accounts to unix accounts rather than use virtual mailhosts (these allow you to designate a single account to store mail which will be divided into seperate folders for different domains/accounts, so useful if you are running many domains/users as you don't have to update main.cnf and change unix settings for each account) . here is a basic guide (assuming you are not using virtual mailhosts): http://rimuhosting.com/support/settingupemail.jsp?mta=postfix&t=local#local http://rimuhosting.com/support/settingupemail.jsp?mta=postfi... and one on integrating spamassasin: http://www.akadia.com/services/postfix_spamassassin.html http://www.akadia.com/services/postfix_spamassassin.html Of course make extra sure you are not running an open SMTP relay (best way to check for sure is with telnet)! Also you can setup fail2ban to watch your mail server logs for failed logins and automatically update your firewall rules to keep them out.
- flyt 15y agoAdvice from a long-time sysadmin? Don't. Use Sendgrid, MailGun, or some other managed email provider and let them deal with the headaches of running mail servers. It's seriously not an industry you want to try and understand or deal with. Setup an account, pay the service usage fees, and know that you're saving yourself a lot of headaches. All of these services now have good APIs, callback hooks, and statistics to help you track the behavior of your mail traffic without having to write your own parsing pipeline. Trade money for time when appropriate. Believe me that the time involved to deploy, run, secure, and maintain a flexible and stable mail infrastructure really isn't worth the time better used building a good application.
- jlawer 15y agoDepending on your requirements either iRedMail (for an out of the box support of virtual domains, etc) or otherwise... just plain simple postfix. Howto Forge has some good tutorials (http://www.howtoforge.com/howtos/email http://www.howtoforge.com/howtos/email). Its all a question of why you are doing it. If your aiming to learn, then I would recommend using a howto and installing different components. If your running a business... seriously look at just using Google Apps or some other similar system. If you need sending capability then SendGrid and such are suitable for low volume (sub multi-million messages / month). The biggest problem you are going to face in running your own server is keeping the design up to date.... every year Spam detection methods change, and you need to keep on top of that. Thats what eventually made me pack it in and move my hosting to google. I'm a RHCE and administer and support mail server for a some quite large national brands. But I can't be bothered for my own domain. If your are or are looking to be a systems guy then LEARN EMAIL (SMTP, POP, IMAP), its one of the core competencies. If your a dev you should know it, but outsourcing the running of it can make sense. Just don't be a fool and outsource it if its the core of your business. If your sending (or recieving) above a certain threshold its almost always cheaper to do it yourself.
- afhof 15y agoThis was brought up recently: http://flurdy.com/docs/postfix/index.html http://flurdy.com/docs/postfix/index.html I actually followed the guide (not just read it) and got a working mail server in a few hours.