Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

How can I create a subdomain from a public IP and an existing domain name ?

I have a website hosted by an external hosting company.:

www.example.com

I have a public IP (not real): 127.180.150.20

I have a LAN.

What I want to do:

I am developing a web application (php/html/perl) that will need a lot of space for that I have planed to have my own dedicated server. I want to use my own computer and assign it a public IP but the application should be accessed from the following subdomain address:

  www.app.example.com
  • Is it possible to create a subdomain from the cpanel and point it to my public IP address?

  • Do I need to set up maybe a DNS server and a client, what I predict will be tough

I don't necessarily need the step by step on how to achieve this but rather the outline.

share|improve this question

3 Answers 3

up vote 0 down vote accepted

Its just a matter to define the correct A record for this name in the DNS zone file :

www.app.example.com    IN A 127.180.150.20

But this can only be done if you are the actual owner of example.com domain and can manage directly the DNS records. If this domain is owned by your hosting company, that you will need to ask them to do this change.

share|improve this answer

If the server running cpanel also is the primary NS server for your domain, then yes, using these instructions: http://docs.cpanel.net/twiki/bin/view/AllDocumentation/WHMDocs/EditZone

share|improve this answer

Is your public IP a fixed(static) or dynamic?.

Assuming it is a static one and your cPanel server is your primary dns server, you can simply add an "A" record to the zone file".

If you have WHM access, use the below link

http://docs.cpanel.net/twiki/bin/view/AllDocumentation/WHMDocs/EditZone

If you only have the cPanel access, follow the below link

http://docs.cpanel.net/twiki/bin/view/AllDocumentation/CpanelDocs/SimpleDnsEditor

Basically what you need to do is adding the following A record to the zone file

www.app.example.com.    IN A 127.180.150.20

If your public IP is dynamic and changing, the above methods will not work.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.