How to direct all newly registered domains to default holding page - dns

When you register a domain with, let's say GoDaddy, and use their nameserver your domains points to a default holding page.
I run my own nameserver and when I register new domains I point my domains to my own DNS.
How do I set up a holding page so that all newly registered domains point to a default holding page.
Any pointers will be helpful.
Tx

I believe what you are asking is that you want to be able to purchase a domain, update it's nameservers to point to your DNS server and then have a default webpage "holding page" for them?
You can do this, but you will need to configure DNS. DNS servers, by default, do not give out answers that they do not know the answer to. There is a mechanism called dns hijacking, but it is very frowned upon. So lets assume that for every newly purchased domain you do configure DNS. To create the "holding page" simply point your default records (domain, www.domain, etc). to a web server's ip address.
On the web server do not use virtual hosts. A virtual host will give a specific web folder to a request with a given host header. This means that if you request foo.com you will get the foo.com folder. If you request bar.com you will get bar.com folder, etc. If you do not configure your webserver for virtualhosts then the web server will simply return the default web folder.

Related

Programmatically Connect domains to servers

I want to create a simple web app. where user can have a form to add domain and directory name( that is already created on our server ). And it simply starts pointing the domain to that directory. What apis should I need for this? Hosting and domains can be bought from same brand, like GoDady.
Cloudflare has an API to add DNS records.
However, if you go this route, these are the prerequisites:
User's domain must already be activated in Cloudflare. At least partial-setup with Cloudflare's hosting partner (Siteground etc which have Cloudflare integrations built-in) or full-setup (the domain's authoritative nameserver points to Cloudflare).
User must trust you with their email address linked to their Cloudflare account and their Global API key.
Your web app can then make the API call to the endpoint and Cloudflare will create the appropriate DNS records to point to your server.

How to connect one of primary domain access with another subdomain

I have domain coupen.tk and a sub domain coupons.yadvi.com.I have web data in coupons.yadvi.com. i want so DNS configuration that if any one visit Coupen.tk they can see all information of coupon.yadvi.com but the link should be shown of coupen.tk not of coupons.yadvi.com
i have added the ip address of yadvi.com in coupoen.tk DNS A Record ,Ip Address of yadvi.com which will be same for coupons.yadvi.com.
coupen.tk needs to point to the same A record IP address as coupons.yadvi.com, so they both resolve to the same server. That server then needs to be configured to serve the same site for requests to both domains.
The usual way to do that would be to make coupen.tk the "master" A record and configure coupons.yadvi.com as CNAME coupen.tk, so it points to that master record. The web server still needs to be configured to serve the same site for either domain.
Failing that, you'll need to set up a reverse proxy server which literally forwards requests for one domain to the other.

How to map domain to hosting server

My client have a dedicated server on liquedweb cloud service and we my web app is hosted on that server. We want our users to map their domain to our server. So they can enjoy our web app by using their domain name. What information I need to provide to my user so he can map domain and what information I need from them?
I don't know much(in fact anything) about domain mapping
thanks
It depends if the server has a dedicated IP address or is natted.
If the server has a dedicated IP address you can ask your clients to point their entire domain to you server by adding the following A records:
Host TTL Protocol Type IP Address
# 300 IN A 1.1.1.1
www 300 IN A 1.1.1.1
Not all domain hosts ask for TTL,if not dont worry about it.
If you want just their subdomain to point to your server (subdomain.website.com)
subdomain IN A 0.0.0.1
TTL is optional in some systems, in this case the default will be used.
Generally it is recommended that you use an IP for the Apex record and not a domain name. EG: example.com is the apex, www.example.com is the www subdomain.
A typical configuration would be below:
Host TTL Protocol Type Result
# 300 IN A 1.1.1.1
www 300 IN CNAME example.com
This is the same config as the top example but using CNAME example.com. It is the same as using A 1.1.1.1, it just means you only need to change one record.
If your server details are a hostname and not an IP address, most systems will not let you use the hostname for the apex so you will need to find out the IP address. (A simple method is to use the nslookup command or dig command).
TTL is how long in seconds a record last before it expires. If you are unsure what you are doing I recommend lowering this so you can correct mistakes more quickly.
Different methods for the different servers. For most of the servers, you have to change the nameservers of your domain.
This mostly needs when your domain registrar and hosting provider both are different.
First Login into your hosting account, navigate to the account details,
then copy the nameservers from there...which would be like :- dns1.hostingprovider.com
dns2.hostingprovider.com
After that, Go to control panel of your domain. Navigate to the nameservers
You will see the link:- dns1.domainregistrar.com
dns2.domainregistrar.com
Paste the above links at the place of below links.
They need the IP address (and possibly instructions on how to configure their DNS servers (which means a variety of different sets of instructions for different servers and control panels)).
You need the domain name.

Delegation of sub-domain

I have a domain xyz.com whose registrar and web host are different. I have pointed the registrars name server entries to the web hosts ns01.host.com, etc.
On the web host, I have now created sub.xyz.com and want to delegate this domain to an external name server. Of course this is not possible straight off since the web host only allows IP Addresses against Custom A records.
What are my options to delegate sub.xyz.com to ns01.externalnameserver.com?
Instead of an A record on your registrar, you may use CNAME record to point the subdomain to an external address.

Domain forwarding (sort-of)

I have been attempting to set up magento on a shared hosting server that doesn't support innoDB, ergo its not been possible. The domain I want to use has also been registered with this rubbish hosting provider. (one[dot]com for anyones reference). So I thought I would be able to point this domain to a different hosting provider that DOES support it, but one[dot]com doesnt allow me to change nameservers for the domain. They just said this:
You can only setup IP address, CNAME and web forwarding in our DNS settings but not change of nameservers
Would there be any way to change any of these settings or the .htaccess file so that, for example
http://www.mydomain.com/folder/page.php?query=string
Would display a page from the other server
http://xxx.xxx.xxx:xx/folder/page.php?query=string
I've created loads of sits doing all sorts but never really needed to other with the domain administration side of things.
You don't need to change name servers to map a domain to a different server. If the "good" provider supports it (i.e. allows you to register a domain on the server that isn't hosted by the company), just switch the A and MX records to the new server's IP address.
You do need the cooperation of the "good" provider for this, though.
If they're letting you set up the IP address, then setting the IP address of www.mydomain.com to xxx.xxx.xxx.xx should do the trick. On the other server, you'll need its webserver to be set up to serve www.mydomain.com as a virtual domain - if you're using a hosting provider they should do this for you; if not it should be fairly easy to set up (consult the manual of whichever web server software you're using).

Resources