How do I set this up in my domain settings? Thanks in advance.
You need to add a custom DNS record.
If your office workgroup server already has an external DNS record (such as officeworkgroup.mycompany.com) then you would want to add a CNAME record. If you are trying to point sub.example.com to an IP address then you would want to enter an A record. Remember if the IP address of the office workgroup server changes you will manually need to update this A record, and connectivity will be broken until you do.
Go to the manage domains tab in the panel, and click the DNS link the name of the domain. Scroll down to the second section on the page titled “Add a custom DNS record to example.com” and fill in the form.[hr]
FWIW… if you take the A record approach (because you are trying to name the server in DNS to begin with) you could point your office IT staff to the dreamhost API http://wiki.dreamhost.com/API/Dns_commands they could set up a script on the office workgroup server to delete the old and add new record if the external IP address of the server ever changed.
What about MX records for the subdomain?[hr]
Or am I better off running my own name server for the subdomain and have DH point to that?[hr]
Also, I have a static IP at the office.
if you need custom MX records go here: https://panel.dreamhost.com/index.cgi?tree=mail.mx
You can’t run a nameserver on shared host if that’s what you are asking. Nor am I sure why you would want to.
If the IP is truly static and will not change just enter your A record (as described above) and go about your business. If you think its static just because it’s never changed double check. If you static IP is provided by your bandwidth provider even those are subject to change, look for the fine print or “*” to a footnote. It’s true those won’t change frequently so perhaps just documenting how to update the record making several people aware of it’s existence.
Maybe I didn’t explain what I’m trying to do correctly. My weak area is MX records. I understand how A records work and have a basic understanding of how DH hosts DNS stuff.
I have a workgroup server in my office that I would like to have publicly available via sub.example.com, and I do have a genuine static IP from my ISP. Until now I have had an A record pointing sub.example.com to my static IP and my office server and it’s been fine. What I would like to add is mail serving on my office server, to host email addresses on my office server (such as firstname.lastname@example.org) and I understand I need an MX record to point to the server.
How do I setup an MX record on DH that points mail traffic for my subdomain sub.example.com to my office server? Does an A record point any/everything for sub.example.com to the IP associated with it, including mail/MX? This is the missing link in my brain.
I’ll pass. That’s an entirely different question than the original post and mx records are not my strong point either.
Someone else with more mx knowledge than I have can pick this up.
As others have said you need to define a custom MX DNS record for ‘sub.example.com’ which points to the name of your office mail server (make sure your office mail server is configured to receive mail from sub.example.com).
Although most modern mailers will fall back to using an A record if there is no MX I’m unsure of what will happen for your sub-domain. Not sure if it will try the A record or fall back to the parent MX. You can easily test this by defining your sub-domain’s A record and sending a test email.
If using gmail for your primary domain you may find this link helpful.
Theres also a nice write up here