当前位置:网站首页>block yandex bot
block yandex bot
2022-07-28 05:23:00 【oHuangBing】
yandex bot yes Yandex Search engine crawler . stay yandex bot user agent In this article , I summed up all yandexbot Of User-agent, Through that article , We can see some Yandexbot comply with robots.txt agreement , Some do not comply robots.txt agreement .
We need to block yandexbot(block yandex bot) Can pass robots.txt and IP The way to shield , Let's talk about it separately .
adopt robots.txt shielding yandexbot
yandex bot user agent In this article, only abide by robots.txt The crawler of the agreement, we can pass robots.txt Protocol to shield , If we don't comply, we can't pass robots.txt Protocol to shield .
for example , We need to block YandexBot/3.0 This Reptiles ,robots.txt It is written as follows :
User-agent: YandexBot
Disallow: /
This prohibits all YandexBot Grab any page of our website , Blockade reached yandex bot(block yandex bot) Purpose .
If we just want some pages not to be YandexBot Grab , We can write this way :
User-agent: Yandex
Allow: /
Disallow: /private/user-info
We allow YandexBot Visit all pages , But the last one forbids access /private/user-info page , That's what we're trying to achieve .
Some more Yandex bot Do not abide by robots.txt agreement , So we need to go through IP perhaps IP The address segment is shielded .
adopt IP Address to shield Yandex bot
We go through YandexBot The page can find out the specific Yandex bot Of IP Address , for example :YandexMobileBot/3.0 Do not abide by robots.txt agreement , So we need to pass shielding IP The way to shield Yandex bot, Displayed through this page IP , Let's choose any one IP As an example :95.108.213.6.
If our front-end server ( for example :Nginx,Apache) Running Linux We can directly enter the following command to mask Yandex bot:
sudo iptables -A INPUT -s 95.108.213.6 -j DROP
such YandexMobileBot/3.0 We can't capture the content on our website .
We can input one by one IP Address , Shield through firewall .
summary
shielding Yandex bot We used two methods , One is : adopt robots.txt To shield , The other is : adopt IP Address to shield , If Yandexbot Non compliance rotbots.txt agreement , We will use IP Address to shield .
Yandex bot yes Yandex Search engine crawler , If we block , It may bring us losses in traffic , Please consider whether it is necessary to shield Yandex Bot, Make another decision .
边栏推荐
- Antd setfieldsvalue warning problem cannot use 'setfieldsvalue' until you use 'getfielddecorator' or
- 【ARXIV2203】CMX: Cross-Modal Fusion for RGB-X Semantic Segmentation with Transformers
- Autoreleasepool problem summary
- [learning record] data enhancement 1
- Table image extraction based on traditional intersection method and Tesseract OCR
- New methods and features of ES6 built-in objects
- Know etcd
- MySQL 默认隔离级别是RR,为什么阿里等大厂会改成RC?
- 【SLAM】LVI-SAM解析——综述
- Scanf function of input and output function in C language
猜你喜欢

MySQL practice 45 lectures

测试开发---自动化测试中的UI测试

【ARXIV2203】SepViT: Separable Vision Transformer

【CVPR2022 oral】Balanced Multimodal Learning via On-the-fly Gradient Modulation

【内功心法】——函数栈帧的创建和销毁(C实现)

Testcafe's positioning, operation of page elements, and verification of execution results

7. < tag string and API trade-offs> supplement: Sword finger offer 05. replace spaces

【CVPR2022】Multi-Scale High-Resolution Vision Transformer for Semantic Segmentation

Dcgan:deep volume general adaptive networks -- paper analysis

Duoyu security browser will improve the security mode and make users browse more safely
随机推荐
类和对象【中】
regular expression
【CPU占用高】software_reporter_tool.exe
HashSet add
Reading sdwebimage source code Notes
HDU 3078 network (lca+ sort)
【CVPR2022 oral】Balanced Multimodal Learning via On-the-fly Gradient Modulation
[internal mental skill] - creation and destruction of function stack frame (C implementation)
How to successfully test php7.1 connecting to sqlserver2008r2
Configuration experiment of building virtual private network based on MPLS
Autoreleasepool problem summary
HDU 3585 maximum shortest distance
SMD component size metric English system corresponding description
【CVPR2022】On the Integration of Self-Attention and Convolution
Service object creation and use
阿里怎么用DDD来拆分微服务?
Tips for using swiper (1)
【ARIXV2204】Neighborhood attention transformer
Offline loading of wkwebview and problems encountered
PC端-bug记录