IIS7 IIS8 reverse proxy rule writing, installation and configuration method

IIS7 IIS8 reverse proxy rule writing, installation and configuration method

Purpose: Treat Station A as the secondary directory of Station B

like:

http://www.baidu.com is equal to /baidu/

http://www.qq.com is equal to http://www.6ke.com.cn/qq/

1. Install 64-bit URL IIS7 rewrite
2. Install requestRouter_amd64.msi

Installation Steps

1. The version of IIS is 7.5.7600.16385.

2. Close related services.

net stop was /y

net stop wmsvc /y

The second service is not turned on.

3. Manually install ARR dependencies.

a) Web Farm Framework module version 1.1

b) External cache module version 1.0

c) URL Rewrite module version 2.0

4. Install ARR.version 3.0

5. Start the service that was previously shut down.

net start was

net start wmsvc

6. Installation successful.

Problems encountered:

Previously installed using WebPI. It will automatically install ARR3.0 related dependencies. Server Farm can be displayed normally, but ARR3.0 is not installed successfully. Checking the system log shows: Failed to load file or assembly:

Solution:

Uninstall all the automatically installed arr and its dependencies. Follow the above steps to install manually.

3. Save the following rules in Notepad and rename them to web.config.

The above files can be downloaded from https://www.jb51.net/softs/629246.html

Put the website root directory:

<?xmlversion="1.0"encoding="UTF-8"?> 
  <configuration> 
  <system.webServer> 
  <rewrite> 
  <rules> 
  <rulename="OrgPage"stopProcessing="true"> 
  <matchurl="^baidu(.*)$"/> 
  <actiontype="Rewrite"url="http://www.baidu.com/{R:1}"/> 
  </rule> 
  <rulename="OrgPage4"stopProcessing="true"> 
  <matchurl="^qq(.*)$"/> 
  <actiontype="Rewrite"url="http://www.qq.com/{R:1}"/>
   </rule>
   </rules>
   </rewrite>
   <defaultDocument>
   <files>
   <clear/>
   <addvalue="index.html"/>
   <addvalue="1.html"/>
   <addvalue="index.php"/>
   </files>
   </defaultDocument>
   </system.webServer>
   </configuration>

4. Find aRR and click it as shown below.

Code Explanation:

<rulename="You can write it at will, but it must not have the same name"stopProcessing="true">
<matchurl="^website local secondary directory name (.*)$"/>
<actiontype="Rewrite"url="The called website or the called website's secondary directory name {R:1}"/>
</rule>

It's done!

Steps to add reverse proxy in IIS6 and 7

1. Install requestRouter_amd64.msi and rewrite_x64_zh-CN.msi.

2. Open IIS and select Application Request...

IIS6,IIS7,反向代理

3. Select Server Proxy Settings. . .

IIS6,IIS7,反向代理

4. Check Enable proxy and click Apply on the right.

IIS6,IIS7,反向代理

5. Select the site that needs reverse proxy, and then select URL rewrite.

IIS6,IIS7,反向代理

6. Click Add Rule

IIS6,IIS7,反向代理

7. Select Blank Rule

IIS6,IIS7,反向代理

8. Fill in the form as shown below

IIS6,IIS7,反向代理

9. Fill in the form as shown below

IIS6,IIS7,反向代理

10.Continue to fill in the form according to the diagram

IIS6,IIS7,反向代理

11. You are now done.

IIS6 is relatively simple, the steps are as follows:

1. Download and install Rewrite3.

2. Modify the ".htaccess" file appropriately and put it in the root directory of the website.

You may also be interested in:
  • How to set the cookie domain when IIS implements reverse proxy
  • Windows installs nginx1.10.1 reverse proxy to access IIS website
  • How to configure reverse proxy using IIS (picture and text)
  • IIS defense against small-scale DDOS attacks (reverse proxy)
  • Graphical tutorial on how to configure reverse proxy using Application Request Routing in IIS7
  • Let iis record the real ip of nginx reverse proxy
  • Nginx reverse proxy + DNS polling + IIS7.5 10 million PV 1 million IP dual-line website architecture case
  • Detailed explanation of ISAPI_Rewrite Full version used in IIS as reverse proxy

<<:  Analysis of the Principle of MySQL Index Length Limit

>>:  JavaScript Canvas draws dynamic wireframe effect

Recommend

Analysis of MySQL lock wait and deadlock problems

Table of contents Preface: 1. Understand lock wai...

Mysql stores tree structure through Adjacency List (adjacency list)

The following content introduces the process and ...

Websocket+Vuex implements a real-time chat software

Table of contents Preface 1. The effect is as sho...

Enable sshd operation in docker

First, install openssh-server in docker. After th...

HTML code to add icons to transparent input box

I was recently writing a lawyer recommendation we...

How to configure mysql5.6 to support IPV6 connection in Linux environment

Introduction: This article mainly introduces how ...

Vue component communication method case summary

Table of contents 1. Parent component passes valu...

HTML exceeds the text line interception implementation principle and code

The HTML code for intercepting text beyond multipl...

Method of building docker private warehouse based on Harbor

Table of contents 1. Introduction to Harbor 1. Ha...

Detailed explanation of the entry-level use of MySql stored procedure parameters

Use of stored procedure in parameters IN paramete...

Achieve 3D flip effect with pure CSS3 in a few simple steps

As a required course for front-end developers, CS...

Teach you how to subcontract uniapp and mini-programs (pictures and text)

Table of contents 1. Mini Program Subcontracting ...

Server stress testing concepts and methods (TPS/concurrency)

Table of contents 1 Indicators in stress testing ...

Specific operations of MYSQL scheduled clearing of backup data

1|0 Background Due to project requirements, each ...

How to optimize logic judgment code in JavaScript

Preface The logical judgment statements we use in...