What are the optimization ideas for Nginx? How to prevent hotlinking on a website? Attached are graphic descriptions and complete code steps.

What are the optimization ideas for Nginx? How to prevent hotlinking on a website? What are some similar safety experiences in actual work? Implement it step by step through code practice, with graphic descriptions and complete code steps.

Experimental topology diagram:

Insert image description here

Experimental steps

1. Install Nginx on Centos01, set the website root directory / www and use the domain name www.huhu.com to access.
2. Install DNS on Centos02 and use the domain name to access. On Centos01, use the domain name www.huhu.com to access. Centos03 uses yum to install apache and use the domain name. Visit www.huyan.com

3. Hide Nginx version on the website of www.huhu.com domain name, view Nginx management users, set web cache, configure log cutting, configure Nginx log cutting, and set timeout

4. Configure anti-hotlink protection on the www.huhu.com website to prevent www.huyan.com from stealing links to www.huhu.com

Install Nginx on Centos01, set the website root directory /www and use the domain name www.huhu.com to access it

Mount Centos7 system CD

[root@centos01 ~]# mount /dev/cdrom /mnt/  

mount: /dev/sr0 is write-protected and will be mounted read-only.

Create nginx management account

[

Guess you like

Origin blog.csdn.net/u014374009/article/details/133120436