IIS Manage With AppCmd


  1. 說明
    1. AppCmd Folder
    2. Useful Command
    3. aspnet_regiis
  2. 參考資料
  3. 相關連結

筆記如何使用 AppCmd 進行 IIS 的站台管理、部署與各項組態設定,藉由活用 AppCmd 精進 IIS 的管理之道。

logo

說明

管理目標 說明
Site 虛擬站台
App 應用程式
Vdir 虛擬目錄
Apppool 應用程式集區
Config 組態設定
Backup 伺服器組態備份
WP Worker Process
Requests Active HTTP Request
Module Server Module
Trace Sever Trace Log

AppCmd Folder

IIS Express

cd C:\Program Files\IIS Express

IIS

cd %systemroot%\system32\inetsrv\

Useful Command

查詢 IIS 下包含的站台、應用程式以及應用程式集區:

appcmd list site
appcmd list app
ammcmd list apppool

如果想要確認 Application Pool 以及 Worker Process 的對應關係,可以使用下列 Command

appcmd list wps

如果要確認目前的 Requests 可以使用下列 Command

appcmd list requests

aspnet_regiis

加密 web.config 連線字串密碼的方式,使用 pef

aspnet_regiis.exe -pef "connectionStrings" "D:\Sites\MyApplication"

解密 web.config 連線字串密碼的方式,,使用 pdf

aspnet_regiis.exe -pdf "connectionStrings" "D:\Sites\MyApplication"

參考資料

Getting Started with AppCmd.exe | learn.microsoft

相關連結

IIS 筆記整理

IIS 網頁伺服器的安全設定 (IIS Security Configuration)