Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 857
  • Last Modified:

SUB DOMAIN CONFIGURATION IN REDHAT LINUX 7.3

I am using linux server as a primary dns server and  mailserver.Now i want launch a web site in windows 2000 server .For that i need to configure sub domail in linux.

For example:

1.The dns server domain name is "example.com" and ip is "203.50.10.1."  ( linux )
2.The mail server mx record is same "@examlp.com" and ip is "203.50.10.1."  ( linux )

3.The web server is in windows 2000 server.The ip is "203.50.10.2" .Now i want use sub domain for this ip . "update.example.com".How i configure in linux redhat .I configured dns bind by using redhat dns configuration tool.
0
belranjan
Asked:
belranjan
  • 2
  • 2
1 Solution
 
psimationCommented:
This all happens in the zone file for the top level domain.

Look in the /var/named folder for the zone file for this domain, usually called something like domain.dom.zone or whatever you called it in your /etc/named.conf file.

A typical zone file looks like this:

;
; Forward resolution zone file for a primary nameserver
;
$TTL 86400
@ IN  SOA          domain.dom. emailaddress.domain.dom. (
      2003021903   ; Serial    < -----------------------------------------------     change this so named will know to update secondary server.
           10800   ; Refresh
            3600   ; Retry
          604800   ; Expire
           86400)  ; Minimum

              IN  NS     domain.dom.
              IN  NS     otherdomain.dom.

              IN  MX 10  mail.serer.dom.
             

              A          203.50.10.1  < ------------- this is so people won't have to type www to get to your website, you can leave it out.
ftp           IN  CNAME  domain.dom.
mail          IN  CNAME  domain.dom.
www           IN  CNAME  domain.dom.
update           IN CNAME 203.50.10.2      < ---------- you need to add this

Make the change, and change the serial number for the file, and then restart your DNS on the primary AND secondary box. Changes can take a while to propagate, except if you use this server as your nameserver.

This is a quick and dirty hack, apparently the elegant way to do this is to have a zone file for the subdomain as well...


0
 
belranjanAuthor Commented:
Hi  psimation..

I understand but i used redhat gui dns configuration tool.I want to know how to configuration from that tool.

In that there his records option is there .Is that a way i have add sub domain and assign a ip for that new subdomain.
0
 
psimationCommented:
I don't think that the GUI tool will help you to edit the zone file. Anyway, a good SySAdmin will always know how to do things from the command line as well, just incase the monitor explodes and you can only telnet/ssh into the server ;)

You can use your GUI editors to edit the zone file, use something like gedit or kedit to open the /var/named/xxx.zone file and make the changes as I have shown you. If you are afraid you mess up, make a backup of the zone file before you start editing. It's very important you observe the layout of the file wrt spaces and tabs etc. Also, note the "." after you supply "human" readable names for machines, and when supplying IP's, you DON'T give a trailing dot...

Don't be intimidated by having to make changes to the file directly, that is why Linux is such a nice OS, it was meant to be done that way in the first place...
 
0
 
belranjanAuthor Commented:
website, you can leave it out.
ftp           IN  CNAME  domain.dom.
mail          IN  CNAME  domain.dom.
www           IN  CNAME  domain.dom.
update           IN CNAME 203.50.10.2      < ---------- you need to add this

If make this changes like that.Weather i can host a web site in diffent machine with this ip.
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now