简体   繁体   English

如何通过将文件复制到其中来停止IIS网站

[英]How to stop a IIS website by copying a file into it

I remember it is possible to stop a website in IIS simply creating a file in the site directory with a special name. 我记得有可能在IIS中停止网站,只需在站点目录中使用特殊名称创建文件即可。 But I don't remember the name and can't find it in google. 但我不记得这个名字,也无法在Google中找到它。 Can you help me? 你能帮助我吗?

App_Offline.htm, at least for Asp.Net applications. App_Offline.htm,至少对于Asp.Net应用程序而言。

http://weblogs.asp.net/scottgu/archive/2005/10/06/426755.aspx http://weblogs.asp.net/scottgu/archive/2005/10/06/426755.aspx

Summary by Vincent P : Vincent P的摘要:

When you place a file called app_offline.htm in the root of the site, IIS stops the site. 当您将一个名为app_offline.htm的文件放置在网站的根目录中时,IIS会停止该网站。 Then when you remove the file, IIS starts up and gets going when it receives the first request. 然后,当您删除文件时,IIS会启动并在收到第一个请求时开始运行。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM