V
V
Vladimir2017-09-19 04:26:46
Nginx
Vladimir, 2017-09-19 04:26:46

Indexed pages of one site are displayed in the index of another site on the same IP, what to do?

There is a VDS server with one IP, for example 170.70.70.70
This IP has two sites with domains https:// domain_1.com and domain_2.com
The first one is indexed by Google and Yandex, the second one is only added for indexing (literally yesterday it was transferred to the server)
If in the search Yandex, enter host: domain_ 2 .com, then in the output I see indexed pages from the site domain_ 1 .com
And in this form:
https:// domain_ 2 .com/url1_from_domain_ 1 ,
https:// domain_ 2 .com/url2_from_domain_ 1 and etc.
second site is not https
if you make a similar request in Google through the site: directive, then everything is fine
. in short, Yandex considers that domain_1 = domain_2 and substitutes the addresses of pages with domain_1 into domain_2.
I messed up something in the nginx configs of the first site and Yandex sees it not as domain_1, but as 170.70.70.70?
Or will everything fall into place after indexing the second site?
This is the first time I’ve encountered this and I don’t understand what kind of nonsense this is, maybe someone has come across something similar and will clarify the essence of this magic for me?)
UPD: yes, most likely the problem is in my nginx settings, tk. a request to https://domain_2.com quietly opens https://domain_1.com .... hmm..
UPD 2: The question takes on a different meaning, since something is wrong with setting the host config with https - now I have all the domains that are on this IP, if you substitute https:// for them, they open the first site, and the substituted domain name remains and the site perceives it as native, what's wrong with the config?

server {
    server_name www.domain_1.com domain_1.com;
    return 301 https://domain_1.com$request_uri;
}
server {
    listen       443 ssl;
    server_name  domain_1.com;
   
    keepalive_timeout   70;

    ssl on;
    ssl_certificate /etc/ssl/domain_1/domain_1.crt;
    ssl_certificate_key /etc/ssl/domain_1/domain_1.key;
    ssl_protocols       TLSv1 TLSv1.1 TLSv1.2;
    ssl_ciphers         HIGH:!aNULL:!MD5;
}

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
Vladimir Mukovoz, 2017-09-19
@ipdesign

UPD: yes, most likely I have a problem in the nginx settings, because a request to https://domain_2.com quietly opens https://domain_1.com .... hmm..

This is exactly what I wanted to tell you, but you beat me to it))
The reason is probably that the site https://domain_1.com has a certificate and an https setting, but the rest of the sites are configured only for http. As a result, when requesting via https, since you don’t have a given https site, the only virtual host that has https is selected, or perhaps not the only one, but simply the first one.
I strongly recommend reading, after reading you will understand everything yourself
https://nginx.ru/en/docs/http/request_processing.html
So what I recommend to do.
1. Buy a separate ip to VPS for each site and register everything in a virtual host, this will have a positive effect on search ranking.
2. Put https on each site.
And of course, it’s more careful to configure nginx or hire a specialist who understands this otherwise, spoil your position with such antics. From my own experience, I will say that setting up Nginx greatly affects search rankings, especially in Yandex.
PS If the settings that you posted are not just made from the bullshit, but are really used by you, then you are losing customers a lot, go here and test your site on which https and there is a list of browsers and devices and it is indicated against each according to which protocol it can work on site and with what encryption, those who will not be able to enter your site will be marked in red. Looks like there will be a lot of red ones. If a production site is better not to save and not to experiment, but to hire. If for the soul, then of course learn better yourself. If you have any questions, I will prompt.
https://www.ssllabs.com/ssltest/analyze.html

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question