前言:有些网站不想做SEO,加上可能配置不好,各大搜索引擎蜘蛛的抓取反而给服务器造成了压力。
方案1:首先你得拥有一个宝塔防火墙,直接在防火墙里找到:User-Agent过滤,然后添加以下规则内容:
(Baiduspider|baiduspider|sogouspider|sogouweb|360spider|Bytespider|toutiao|Sosospider|YodaoBot|msnbot|Googlebot|Amazonbot|dataforseo|DataForSeoBot|semrush|babbar|mj12bot|116.0.0.0)
方案2:在宝塔面板找到对应的网站,点击设置,点击配置文件,加入以下代码:
C
if$http_user_agent"Baiduspider|baiduspider|sogouspider|sogouweb|360spider|Bytespider|toutiao|Sosospider|YodaoBot|msnbot|Googlebot|Amazonbot|dataforseo|DataForSeoBot|semrush|babbar|mj12bot|116.0.0.0"return403
你 发表评论:
欢迎