E
E
elyourn2014-08-21 22:31:12
System administration
elyourn, 2014-08-21 22:31:12

Domain names. How to link a third-party domain to a site?

Hello.
There is domain X and under domain Y. Domain X is located on my account, on hosting, under domain Y on a third-party.
It is necessary to make it so that when you enter the address under domain Y (in the browser line), site X opens. Without changing the domain name (that is, not a redirect). Сname is also not considered.
As far as I understand, they usually register ip (a - record) of domain X for sub-domain Y and get the result, by doing this I get a hosting page with the error "site does not exist".
Perhaps someone knows how to implement?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
E
elyourn, 2014-08-21
@elyourn

I didn't write it right, I need to clarify here. I own site X, under domain Y belongs to another person who wants his sub domain to link to my site. When I manage to set everything up, I will unlink my domain from the site and only it will remain under the domain.
A-records lead to the same ip. Is it possible to create an alias that will refer not to a specific domain, but to a website?
Solution: The hosting support reacted, placed it under the domain in my PU.

N
neonox, 2014-08-21
@neonox

I'm certainly not a pro, but.
By entering the site address, you send a request to the DNS server, which gives you the IP of the server where domain X is located. Next, Apache, nginx, etc sends a request like poddomen.x.ru. Apache, nginx, etc looks at its config and does not see the poddomen.x.ru entries, as a result of which it gives you 404.
Therefore, by entering one address you will not receive data from the second site without changing the address in the address bar.
Perhaps it's easier to use an iframe?
Everything written above IMHO, perhaps there is some kind of solution, but I do not know it. Would be interesting to read if possible.

I
Igor, 2014-08-21
@merryjane

If they are on different hostings, then the sites should in fact be given to different ones? So one is a copy of the other?
If the site should be given by the same domain and subdomain, the meaning of the second hosting is not clear. For the main domain and subdomain, A-records in NS must lead to the same IP address. On the hosting for the site, you simply hang aliases of domain names for which the site will be given.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question