So on the MX record I get to name my mail server whatever? Where do I find the name ot
So if I get to name it, i'd put something like
I'm confused. I bought a domain name at 1and1.com
Originally, they were doing all the hosting. Then, I started using linux and found out that I could do my own hosting. So, I copied and pasted my website and put it on a computer here in my network at my apt. That network has port 80 open, as well as the router forwarding any http requests to port 80 on that machine. So my website works from outside the network. This website is for personal use, and has no valuable data. I do not have a static ip address, but that computer is always on and remains with the same ip address.
I was told that I needed to purchase a static ip through my local isp. My local isp offers static ip addresses but are very expensive, because they're meant for a business. I decided against it. I have also found out that the external ip address of my router remains static, unless I turn my router off for more than 10 secs. So that make its confusing. Why do businesses pay more for a static ip address when you could simply keep an ip address as long as ur router doesn't get reset or stay off more than 10 secs. Even if ur router did change, u simply change the new ip address of the external router in the control panel of domain name vendor.
Anyhow, so my website works. I know want to setup a mail server under that domain so I could have email addresses like firstname.lastname@example.org
. I can currently get mail through an email account email@example.com
but I have to go through 1and1.com to get my mail. I'd rather set this up on my own computer.
So I setup sendmail and made various modificiations to the macro file, as posted in my first post. I then went to the control panel of my domain name vendor, where I could change the mail server. To change a mail server, I needed to put an name in the MX Record. I figured mail.mydomain.com would suffice. But it's giving me errors. What do I do at this point? Also, I'm getting the feeling that I need to create a subdomain like
ns.mydomain.com for dns purposes. Do I need to do that? and what for? Do I need to add nameservers or DNS servers? Can someone explain to me what and how the MX record works?