OS: Fedora 10
If you're like me, you've setup DNS many times before on many different machines, but its one of those things that never quite stick in your head. Its a bit like knowing that somewhere in Year 9, you've done Simpsons Rule for calculus, but if you were asked to prove it, you'd have no idea. Its just one of those useless wonders, what you encounter in a blue moon. Of course, if you're a system administrator full time you are probably exposed to this quite often, but for me, I just do it when needed. And everytime I need to do it, I need to google it. Well, time to write it down and bookmark it!
Webmin makes certain things easier, especially tedious system administration tasks that you only do once in a blue moon. DNS is one of those things. For the following, lets assume that you are creating a DNS entry for your new domain "yourdomain.com". Remember, this is without the "www" part.
1) Webmin menu on the left, click on "Servers", then click on "BIND DNS Server". This will open up the BIND DNS Server Page. If you do not have this, then you do not have BIND setup on your machine. You will need to install BIND by:
$ yum install bindLoaded plugins: refresh-packagekitSetting up Install ProcessParsing package install argumentsResolving Dependencies--> Running transaction check---> Package bind.i386 32:9.5.1-1.P1.fc10 set to be updated--> Finished Dependency ResolutionDependencies Resolved================================================================================ Package Arch Version Repository Size================================================================================Installing: bind i386 32:9.5.1-1.P1.fc10 updates 3.3 MTransaction Summary================================================================================Install 1 Package(s)Update 0 Package(s)Remove 0 Package(s)Total download size: 3.3 MIs this ok [y/N]: yDownloading Packages:bind-9.5.1-1.P1.fc10.i386.rpm | 3.3 MB 00:04============================== Entering rpm code ===============================Running rpm_check_debugRunning Transaction TestFinished Transaction TestTransaction Test SucceededRunning Transaction Installing : bind 1/1=============================== Leaving rpm code ===============================Installed: bind.i386 32:9.5.1-1.P1.fc10Complete!
Once installed BIND, you will need to refresh the Webmin modules - on the left hand menu towards the bottom, click on "Refresh Modules". Then log out, log back in, and the BIND DNS menu option will be there.
2) Under the "Existing DNS Zones" click on "Create master zone".
3) Fill out the following:
- "Domain name / Network": yourdomain.com
- "Master Server" : yourdomain.com
- "IP address for template records": [ your external IP address as provided to you (xxx.xxx.xxx.xxx) ]
- Click on "Create"
4) This will take you to the "Edit Master Zone" page.
1) Click on "Address"
2) Fill out the following:
- "Name" : [ leave this blank ]
- "Address" : [ your IP address ]
- "Name" : www
4) Fill out the following:
- "Name" : mail
5) Fill out the following:
- "Name" : ftp
6) Fill out the following:
- "Name" : ns1
7) Fill out the following:
- "Name" : ns2
8) You can keep doing this for more names that you want to use. These names are then used when someone types in "name.yourdomain.com". Essentially, these are subdomains that you are setting up, but you are just pointing them to the same server.
9) Once done, click on "Return to record types" at the bottom of the page.
1) Click on "Name Server"
- "Zone Name" : yourdomain.com. [note the trailing period is required here]
- "Name Server" : ns1.yourdomain.com. [note the trailing period is required here]
- "Name Server" : ns2.yourdomain.com. [note the trailing period is required here]
4) Once done, click on "Return to record types" at the bottom of the page.
1) Click on "Mail Server"
- "Name" : yourdomain.com
- "Mail Server" : mail.yourdomain.com
- "Priority" : 10
3) Once done, click on "Return to record types" at the bottom of the page.
0) If you are not on the main options screen, click on the left hand menu "BIND DNS Server".
1) Click on "Zone Defaults"
2) Under "Default Zone Settings", "Allow queries from" box, select "Listed" and change the box from "localhost" to "any". This will allow anyone to query your DNS server.
3) Click on "Save"
4) Click on "Return to zone list" at the bottom of the page.
5) Click on "Addresses and Topology".
6) Under "Global address and topology options", under "Ports and address to listen on", select "Listed below" and in the first row, make sure that "Default" is not selected, and the second radio box is selected. In the text box there should be "53" indicating that we are running DNS on port 53. In the "Address" column, change the value to "any" to allow anyone to access this port.
7) Click on "Save"
1) In the top right hand corner, "Stop BIND" and then "Start BIND" to restart the service. DNS typically takes 72 hours to propogate, but more often than not, it takes less than an hour for local DNS servers to pick up.
« Ga terug