IIS installation and website publishing illustration, iis publishing Diagram
Generally, install IIs first and install. Net Framework 4.0. If an error occurs during sequential installation, the table is worried and there is a solution. Please take a look ~
To install IIs, follow these steps:
By default, iis is not automatically installed during Windows 7 installation. You need to install iis manually. Click Start> Control Panel> program> open or close the windows function, select the function to be installed, and click OK to install the function.
After the installation is completed in a few minutes, open the internet Information Service (IIS) manager, which has a default website. Right-click to manage the website. The following page appears in the browser, indicating that IIS is successfully installed, configure the website.
Configure a website
1. Add virtual directory: Right-click the default website and click Add virtual directory. The following window is displayed. Enter the website alias and select the physical path of the website, and click OK.
2. Convert the virtual directory to an application, select the virtual directory, right-click and select convert to application. The following window is displayed. Select the application pool and click OK.
3. Application pool configuration: select the application pool directory, double-click the application pool, and the edit window is displayed. NET Framework Version and managed pipeline mode are selected, as shown in:
Right-click the application pool, select Advanced Settings, change the properties in the red box (for the Set Properties window), and click OK.
4. Set the default document: select the website and select the default document on the main interface. In the displayed document window, right-click to add the default document (the homepage of your website) and start the default document, as shown in.
5. Open the website in the browser: After configuring the above attributes, you can right-click the website and choose manage applications to browse,
7.
The effect is as follows: configuration center: http://www.ifcts.com
Publish website
1. Make sure that IIS is installed on your computer. Find the project you want to release in Vs and right-click-> release method: file system, as shown in the following figure: (Note: the target location cannot be a desktop or any other disk)
In my computer, find the file RMS you released and grant the file configuration permission to the released file. Otherwise, an error will be reported, saying that the website has no permission.
1. Add the Everyone permission to file RMS and find the file RMS released in disk E, right-click "--" properties ">" security ">" edit ">" add ">" advanced ">" Search now ">" find "Everyone"> "OK"
2 "1. Add IIS_IUSRS permissions to the file HRMS. In the previous step, after adding the Everyone permission, click --> advanced --> Find now --> Find IIS_IUSRS --> OK.
3. After the first two parts, click OK next to them ~
2. Click Start Menu> Control Panel> Management Tools> Internet information service to open the control panel. Take Win7 as an example, that is, the IIS Management window:
3. Right-click the "website" node on the left and select "add Website" from the right-click menu"
In the displayed window, add the website name, physical path, and port number. The port number must not be the same as that of other published sites; otherwise, the website cannot be started. For example, the name is FirstApp port 8888.
The page after successful addition is as follows:
Select Start in the Operation Panel on the right to start the website we just released.
4. Enter http: // localhost: 8888 in the browser.
5. If you want to change or add the project's port number, click "-" to bind it, for example:
After you click bind, the following message is displayed:
In this way, the operation is successful ~
Issue highlights
1. If the "configuration file cannot be modified" error is prompted during website publishing!
Solution: Check whether the application pool used by the website has been started.
2. When the application pool is started, the error message "service was not started" is displayed!
Solution: start the service on the service panel.
3. When the wsa service is started, the system prompts "the service file is damaged ".
Solution: in the running window, enter the command: fsutil resource setautoreset true c :\
Then start the was service again.
4. The error "w3svc service not started" is prompted when you start the website!
Solution: start the service in the service panel, or enter net start w3svc in the running window.
If you first install. net framework4.0 and then install IIs (403 error), the solution is as follows:
You must register. net framework4.0 in IIs as follows:
1. In the running window, enter: 64-bit operating system: C: \ Windows \ Microsoft. NET \ Framework64 \ v4.0.30319> aspnet_regiis.exe-I
2.32-bit operating system: Enter the specified directory m-"tbl key cd can automatically complete the specified word, such as: Microsoft C: \ Windows \ Microsoft. NET \ Framework \ v4.0.30319> aspnet_regiis.exe-I
3. In the running window, enter iisreset (restart IIs)
4. Registration is completed again.
5. cd directory name: enter a specific directory. If a directory is displayed as abcdef ghi
Enter: cdabcdef. ghi to enter the directory.
Cd \ returned to the root directory.
Cd .. return to the upper-level directory.
In this way, it is complete, isn't it very simple? This is a problem I encountered at work, and now I have contributed to everyone ~