SELF-HOSTED | Set up and run your own Mailserver with Mailcow | DNS, Security, Installation, Test

Поділитися
Вставка
  • Опубліковано 4 лип 2024
  • THEY always tell you it is too hard and too complicated to run your own mailserver. Well, that's a lie.
    In this video we are going to set up our own mailserver. We discuss reasons to do that, prerequisites, recommendations, security, the actual installation process, setting the required DNS-entries (including DKIM, SPF, and DMARC), setup of mailboxes, and what to do after the installation.
    This video is a bit longer, but this is time well spent if you want to run your own mailserver! Please apologize the sound quality - I had some issues with the microphone. :-(
    Resources:
    GIST with firewall commands:
    gist.github.com/opentaq/2ce85...
    Mailcow Documentation:
    mailcow.github.io/mailcow-doc...
    Chapters:
    00:00 - Intro
    00:36 - Why running your own mailserver?
    02:59 - Prerequisites
    04:32 - VPS- / VM-Setup
    08:17 - Securing the System
    10:57 - Reverse DNS
    11:51 - Basic DNS
    13:49 - Installing the Mailserver
    16:10 - Changing the Admin-Password
    17:09 - Adding a Domain and Finishing the DNS-Setup
    24:05 - Adding a Mailbox
    25:38 - Checking the Configuration
    27:29 - Using the Mailserver
    28:45 - What's Next?
    30:28 - What do YOU think?
    Let me know your thoughts in the comments below. And while you are there, don't forget to like, to subscribe, and to hit the notification bell - since it helps!
    Don't forget: Let's make the world a better place - Now more than ever!
    #StandWithUkraine #SelfHosted #Mailserver
  • Наука та технологія

КОМЕНТАРІ • 208

  • @nura943
    @nura943 9 місяців тому +7

    Hi Karsten, das ist das genialste Tutorial, dass ich jemals zu dem Thema gesehen habe. Du hast damit meinem Mailserver Projekt krassen Rückenwind gegeben. Tausend Dank dafür. Das ist so kurzweilig und cool gemacht und hat zwischen den Parts, die ich schon kannte, die Brücken gebaut. Genial.

  • @ze3rax
    @ze3rax 2 місяці тому +1

    You are amazing in teaching, period. I've spent numerous hours reading this, reading that, many enthusiasts' websites on "How to", yet none of them were able to share the information the way I find it right - sharing it in such a way in order to teach the other side. Thank you! You did great! My server is running right now and it's receiving all the emails (tested).

  • @Star-egy
    @Star-egy Рік тому +5

    you are so great, please come back with more self hosted series we need the great way of explaination, also let me say we miss you :)

  • @PeterBatah
    @PeterBatah 5 місяців тому

    By far one of the better mail server tutorials that I have had the pleasure of sitting through. Wonderful. Thank you for sharing your time and expertise with us. Much appreciated.

  • @dwrout
    @dwrout Рік тому +7

    Awesome tutorial, I did this as self-hosted on proxmox vm. I only needed additional port forwarding, edits to my reverse proxy and also my domain name host screen layout looked different to the one used, but it came up as in the tutorial. Scored 10/10 on the email test. Great job on the video.

  • @WokCorner
    @WokCorner 11 місяців тому +5

    25:48 - you just made me flashback to a Better Call Saul scene with that word "truly". "is there no other way, truly?" this sentence lives in my heart rent-free

  • @boss0killer
    @boss0killer Рік тому +49

    This is what a tutorial is supposed to look like! Thank you!

  • @sideshowlol
    @sideshowlol 8 місяців тому +1

    Thank you for your excellent tutorial, Mr Opentaq. 🙏😎 Sound quality was plenty good enough and your explanations were very helpful.
    One thing I ran into after the main installation was done was the need to set up an SMTP relay server for my VPS. I couldn't send any email without doing this. This can now be done in the Mailcow UI. There's a section in the mailcow docs under Postfix and Relayhosts. Apart from this, I had a few other things to sort out. I'm testing mailcow on a 2GB RAM server which meant I had to disable ClamAV to prevent out-of-memory situations. I realise this is not recommended for a production email server but it has seemingly been fine for testing and has allowed me to familiarise myself with the rest of the mailcow services.

  • @raven325i
    @raven325i Рік тому +13

    Seriously good job at explaining the process - although I installed mine on a ubuntu platform, most of it was the same - so thanks for your video tutorial. It helped a lot!

  • @commievoyager
    @commievoyager Рік тому +2

    Awesome video! It's just a great job! I'll try this manual tomorrow. I hope it will work. Thanks for your efforts.

  • @Epicvids61
    @Epicvids61 Рік тому +2

    Amazing content, thank you for the tips! Got a 8.7 on the spam meter, and setup my first mailserver!!

  • @ishi92
    @ishi92 Рік тому +3

    thank you! mailcow has made the process so easy that its a no brainer for a tech company to run their own mail server - especially if privacy matters to your organization.
    now need to look into backups.

  • @akiyai
    @akiyai 5 місяців тому

    Very nice, useful and complete tutorial. Thank you. I will give a trial and install this server. You have convinced me of having my own mail server!

  • @3rdClaude
    @3rdClaude Рік тому +2

    Thanks so much for this video. Every other video I found about a mail server was installing a server that had no GUI. Thisa make it so much easier. Liked & subscribed!

  • @patrickscheel2033
    @patrickscheel2033 2 роки тому +9

    As always, a wonderful and inspiring video! Keep it up!

    • @opentaq
      @opentaq  2 роки тому +6

      Thank you so much!

  • @CipherOne
    @CipherOne Рік тому +7

    I love the content. I have one bit of unsolicited constructive criticism though, and I only am saying this because I believe you will succeed in this UA-cam game: I would back off a bit on the zoom cuts. If you do it too often, it can become distracting. I would use it to add emphasis only on particular points or when the subject is changing or taking a slight detour. Great camera angle and your technique is on point too, just over used. Most important of all, you're a good speaker and the content is top notch. Keep up the good work, my friend! I'm your 777th subscriber!

  • @viniciostorres
    @viniciostorres 4 місяці тому

    Great tutorial! The only problem I faced was the time propagation of DNS updates. Thank you very much for your video.

  • @fransvanderwerf7485
    @fransvanderwerf7485 Рік тому

    Excellent tutorial from Germany! You've been a great help here :) Many many thanks

  • @geoffgates8264
    @geoffgates8264 Рік тому

    proper tutorial and no stupid loud music. cheers, by the way I did it and it works.

  • @pharaohstudiosllc
    @pharaohstudiosllc 4 місяці тому +1

    Great Tutorial! Time for us to take control of our own data & businesses moving forward..

  • @frankuchan3080
    @frankuchan3080 Рік тому +2

    Thank you!
    I was able to successfully set up my own mailserver!

  • @AlexS-so7wk
    @AlexS-so7wk 3 місяці тому

    You are a marvellous person, thank you for the video.
    I understand almost everything that you said, and it was quite useful for me.
    A few times I skiped a content, and got lot of waste of time then, so It was a little funny to find solution of my problem in a passage of the video that I skiped :)

  • @zekarov
    @zekarov Рік тому +5

    A fantastic tutorial! Thank you

  • @sparti89
    @sparti89 Рік тому +2

    Nice, and now i have a domain where i can host my own website. Looking forward for more videos to recycle domains :)

  • @sirwrad
    @sirwrad 9 місяців тому +1

    the best tutorial to build a mail server that i've seen! thanks a lot!

    • @opentaq
      @opentaq  9 місяців тому +1

      Thank you!

  • @jim7smith
    @jim7smith Рік тому +3

    One of the best tutorials I have seen in years of watching. No extraneous babbling, just the facts. Seriously, this was excellent. My only mild complaint is the background music, especially one part where it had vocals. I am hard of hearing anyway, and have to focus to hear the narration. Thanks so much, and praying for your safety in these troubled times for the Ukraine!

  • @donboscow9291
    @donboscow9291 5 місяців тому

    THE tutorial on this topic! No other tutorial comes close!

  • @DNAblue2112
    @DNAblue2112 10 місяців тому

    I managed to get everything but the DNS setup by myself. But this tutorial is awesome and I wish I had used it for the whole setup. Regardless, thanks for the help with the DNS portion!

  • @ADHDOCD
    @ADHDOCD Рік тому +4

    This is a great tutorial. Can you also make a video on domain/email reputation & deliverability?

  • @francesco4143
    @francesco4143 Рік тому +2

    Hello and thank you very much for the clear and simple guide, but I wanted to ask you if you could also add the guide for port forwarding that needs to be done on your home router (provided that you always need to have a static public address) and if NGINX Proxy is also present Manager what should he manage and how?
    Sorry for too many questions but I think this part should be explored :-)
    Thank you very much

  • @CliffordHepplethwaite
    @CliffordHepplethwaite 11 місяців тому

    Wonderful video, Sir. Many thanks!

  • @romainrochas1474
    @romainrochas1474 2 місяці тому

    Mooohooooo it works !!!! Thank you so much ! (I am on this for almost 1 month already...) I still have to fix these anoying email blocking and spam categorization, but I can send and receive mails :)

    • @saranyasreedharan480
      @saranyasreedharan480 2 місяці тому

      I setup the same in ec2 instance and one more local machine. It is working fine. When I am working on the production it is not working ans expected. After adding the DNS. while clicking in the DNS ( to see the record). It is showing 504 gateway time out error. Do have any idea?

  • @miguelpalencia4386
    @miguelpalencia4386 2 місяці тому

    excelente video!!!
    Recomendado 200%
    muy facil de entender y muy funcional para ccomenzar usando seguridad ante todo.

  • @Andrei-ds8qv
    @Andrei-ds8qv 2 місяці тому

    Very nice, in depth tutorial, thanks

  • @alexpastushok7235
    @alexpastushok7235 Рік тому

    Thanks for tutorial, that's helped me a lot with my mailcow installation

  • @comoyun
    @comoyun 11 місяців тому

    This tutorial was indeed helpful! thank you.

  • @cbaservs
    @cbaservs 10 місяців тому

    great to learn about my own mailserver...Karsten....vielen dank

  • @James_Alfonso
    @James_Alfonso 24 дні тому

    This is the first tutorial I was able to fulfill my mail server without a glitch

  • @VictorMongi
    @VictorMongi Рік тому

    Hello,
    Thank you for sharing this,
    Works like a charm.
    Thank you sir....

  • @reziiwastaken
    @reziiwastaken 11 місяців тому

    This is a fantastic tutorial. Thank you very much!

  • @gf6h75fghfghfghdfh7
    @gf6h75fghfghfghdfh7 Рік тому +3

    Great video! Very well explained. My only concern is email reachability these days (aka oligopoly). Did you have any big issue?

  • @franklimmaciel
    @franklimmaciel Рік тому +1

    Thank you very much for this excellent tutorial.

  • @guandulin
    @guandulin 11 місяців тому

    Great tutorial, I got issues with mailcow's web GUIs (admin andwebmail) with port 80 and 443 since I already had a web server running, just change them on mialcow's configuration and now its fine.
    Also got problems sending emails since my server is hosted by vultr and by default they block the SMTP ports (solved by opening a ticket explaining I will not be a spammer).

  • @ksamaschke
    @ksamaschke 2 роки тому +3

    Wow, awesome video!

  • @goranzajec8486
    @goranzajec8486 Рік тому

    Fantastic guide, thanks!

  • @Babbis44
    @Babbis44 5 місяців тому

    Appreciate this!!

  • @SerkanKoyuncu
    @SerkanKoyuncu Рік тому

    Very good video! Thanks.

  • @ViniDav
    @ViniDav Рік тому

    Thank you! Great tutorial!!!

  • @fredrik354
    @fredrik354 5 місяців тому

    Great tutorial, thank you!

  • @AnneFrank2012
    @AnneFrank2012 Рік тому

    Really great tutorial I've ever seen...

  • @MichaelSharpTechniSmart
    @MichaelSharpTechniSmart Рік тому +1

    I liked, subscribed and HIT the notification bell!
    Can you go a bit deeper on the rest of the DNS settings?
    btw, I like the female vocalist's voice in your background music. What is it?

  • @isaisa1678
    @isaisa1678 3 місяці тому

    Great content!

  • @mohammadhosseingholizadeh
    @mohammadhosseingholizadeh 5 місяців тому

    Thank you so much. It was really really helpful for me.

  • @stanislavus
    @stanislavus 2 місяці тому

    great tutorial!

  • @phobes
    @phobes Рік тому +1

    I've started using Cloudflare Tunnel for 3 of my domains, and it effectively masks your home IP and does not require a static IP. Would this work for a mailserver as well?

  • @rajamustaqeem
    @rajamustaqeem Рік тому +1

    nice and excellent !

  • @gomo5628
    @gomo5628 3 місяці тому

    thanks for the detailed vid man. I wonder how this works if i host multi websites/domains on the same server.

  • @myozone
    @myozone Рік тому

    Prefect !, With German precision. I've watched lots of other videos that skip some parts so you end up without a worker server.
    A second part might add a spam filter ? Just an idea ...

  • @berk473
    @berk473 Рік тому

    Great, thank you! So helpfull

  • @jwspock1690
    @jwspock1690 Рік тому

    Top - Danke für's Video !

  • @rokonection
    @rokonection 9 місяців тому

    just fantastic, thanks

  • @notDacian
    @notDacian 2 роки тому +2

    I run mailinabox for years now, and i never had problems!

    • @notDacian
      @notDacian 2 роки тому

      Also it requires much less resources

    • @kennethlau8108
      @kennethlau8108 2 роки тому

      @@notDacian what server provider are u using. As alot of service providers ban the mail ports

    • @notDacian
      @notDacian 2 роки тому +1

      @@kennethlau8108 In the beginning i used AWS Lightsail, but now i moved my box to Hertzner, they have better deals and overall i feel the performance is better. For Hertzner you have to wait 1 month for your account to be able to open port 25.

    • @MichaelSharpTechniSmart
      @MichaelSharpTechniSmart Рік тому

      @@kennethlau8108 You can see he is using Hetzner, but you have to aopply after 3 months to unblock port 25.

    • @chimastudios
      @chimastudios Рік тому

      @@notDacian if I can use AWS Lightsail I'm good then

  • @danielrdugan
    @danielrdugan Рік тому +1

    Great tutorial!! Question tho.. would using a service like no-ip or duckdns work for setting this up in my home lab? I really dislike the idea of having a monthly bill of using a VPS and I find the cost of using no-ip way more affordable

  • @dallascao
    @dallascao 3 місяці тому

    Thank you! By the way if you get a "unbound test fail" error, replace the unbound image with
    unbound-mailcow:
    image: mvance/unbound:latest

  • @maxmuster6691
    @maxmuster6691 16 днів тому

    Great video. Did I miss the part where you routet all of the trafic to the VM? How did you do that?

  • @ahsanabrar880
    @ahsanabrar880 5 місяців тому

    thanks you so much, really help

  • @rosolovsky
    @rosolovsky Рік тому +2

    Nice. How can i use letsencrypt certificate for secure Mailcow server?

  • @shalchianamin
    @shalchianamin 2 місяці тому

    thank you, great video

  • @johnpintonava3778
    @johnpintonava3778 Рік тому

    Awsome! thanks...

  • @utubetvux5170
    @utubetvux5170 Рік тому

    Subscribed & Hit the bell button my lord.

  • @smalltimer4370
    @smalltimer4370 5 місяців тому

    Would love a tutorial on how to use and configure wildcard SSL on mailcow and mail domains

  • @essanhaji
    @essanhaji 9 місяців тому

    Hi there thank you. I followed along everything is working fine except for ma domain it is not secured no https.please help

  • @GrundGad
    @GrundGad 4 місяці тому

    Followed the same steps as you did but getting 5/10 for the mail-tester.
    My lowest scores are in the dmarc and dkim, any suggestions ?

  • @fabienl.7569
    @fabienl.7569 Рік тому

    I have a stupid question here. Is it possible to do this and provide email hosting services? Clients will provide their domain names and we create professional emails for them? thank you

  • @ghazixdii
    @ghazixdii Місяць тому

    CAN I USE THE EMAIL ACCOUNTS FOR SENDING COLD EMAILS?

  • @farmermet6242
    @farmermet6242 Рік тому

    like to know how to use mailcow with nginx proxy manager ... didn´t find a proper configuration yet. Any pracitcal idea?

  • @gustavomejia9184
    @gustavomejia9184 Рік тому

    Can I use my websites domain or would I have to buy another one for this?

  • @northblue8216
    @northblue8216 9 місяців тому

    Very nice. Thank you. What about spam? How do you block spam?

  • @veroxsity2336
    @veroxsity2336 4 місяці тому

    Is this possible to do on a preinstalled version of debian?

  • @YeloPartyHat
    @YeloPartyHat 3 місяці тому +1

    The command that is unfortunately not in the description: sudo ufw allow 22,25,80,110,143,443,465,587,993,995,4190/tcp

  • @YeloPartyHat
    @YeloPartyHat 3 місяці тому

    How do you check DMARC-reports and how should you action and maintain your abuse email?

  • @VishalSharma-ri8mo
    @VishalSharma-ri8mo 3 місяці тому

    Can i setup it with kubernetes and ingress?

  • @nephygt.h.k1187
    @nephygt.h.k1187 Місяць тому

    Can I be able to connect remotely to this mailserver with smtp credentials?

  • @bhargavaramudu-dot-com
    @bhargavaramudu-dot-com 2 місяці тому

    Which hosting provider is offering reverse DNS without extra cost?

  • @liuuner
    @liuuner Рік тому

    Finally i understand it

  • @YeloPartyHat
    @YeloPartyHat 3 місяці тому

    How do you uninstall docker when you've installed it like this?

  • @decemberfrostpaindine7987
    @decemberfrostpaindine7987 4 місяці тому

    I am confused at 8:27 part, is it ssh from my VM to my PC? or from my PC to its VM?
    I am just confused what machine we are referring to. sorry for being newb

  • @JuanFernandoGallegoGomez
    @JuanFernandoGallegoGomez 8 місяців тому +2

    The hardest part is migrating from a previous mail system preserving all previous data for all accounts, specially if it is a lot.

    • @connor7439
      @connor7439 7 місяців тому +1

      Not really. IMAP sync.

    • @nilpo
      @nilpo 5 місяців тому

      ​@@connor7439yep. This.

  • @kamaljoshi9644
    @kamaljoshi9644 Рік тому

    what is sending limit of this in inbox on receipient side ? can i send 100k inbox a day?

  • @jmsvigno
    @jmsvigno Рік тому

    One question, how to setup using reverse proxy, like nginx proxy manager behind nat on private ip , with redirect ports from video?!

  • @NotSound.
    @NotSound. 7 місяців тому

    Hi, when i setup the server, i keep getting "mydomain"/debug. Any idea why?

  • @user-ei4qg2ud8f
    @user-ei4qg2ud8f 12 днів тому

    Do you know of any information on how to migrate my email domains away from Exchange 2007 to mailcow. I have mailcow set up per this tutorial but having trouble getting the correct mail server to show in the mailcow dns recoreds. It keeps wanting to show the exchange server even after all the dns records are set and the mailcow server is set with a lower priority level than the exchange priority. Any hints or references are appreciated.

  • @ayhangunay1178
    @ayhangunay1178 3 місяці тому

    Hi, super Anleitung. Was aber interessant wäre - Mailcow in Verbindung mit Proxy wie z.B.: Proxmox Mail Gateway nutzen oder Mailcow selbst mit MTA-STS benutzen, was wäre sinnvoller ?

  • @reformatioinpeius2743
    @reformatioinpeius2743 8 місяців тому +1

    Help! I can send emails but can't recieve them. Anybody have any idea of why it may be?

  • @CodinTest
    @CodinTest Місяць тому

    salam alaikoum,
    Thank you for this wonderful tutorial, I hope doing well, I just have question after searching for what reason allowing the port 4190 (ManageSieve Protocol).

  • @brandonmoore3124
    @brandonmoore3124 10 днів тому

    I followed the tutorial to build the mailserver, it's working properly but i can't connect through smtp with a mail client, please what could be the issue.

  • @ErikDuits-jy4ms
    @ErikDuits-jy4ms Рік тому

    Thanks for this video! Maybe a stupid question. If i need to restart the server, should i first close Docker / Mailcow? or can i just sudo reboot?

  • @dev-rachid
    @dev-rachid 8 місяців тому

    thank you very much for your share 👍

  • @user-in5fi3kp4w
    @user-in5fi3kp4w 3 місяці тому

    i can't able to send the mails. the mail test itself failed. i had deployed the configuration settings on gcp virtual machine

  • @EitanbAi
    @EitanbAi Рік тому

    Thank you 💪