如果您运行的是 64 位 Windows,请从 %windir%\system32\inetsrv 目录而不是 %windir%\syswow64\inetsrv 目录中使用 Appcmd.exe。
C:\Windows\System32\inetsrv>appcmd list VDIR
VDIR “Default Web Site/” (physicalPath:%SystemDrive%\inetpub\wwwroot)
VDIR “Default Web Site/PerlEx/” (physicalPath:C:\Perl\eg\PerlEx)
VDIR “test/” (physicalPath:C:\inetpub\other)
VDIR “test/t” (physicalPath:C:\inetpub\other)
http://technet.microsoft.com/zh-cn/library/cc772200%28WS.10%29.aspx
appcmd list site /config/xml >c:\sites.xml 导出所有站点
(windows2003)iis6.0配置文件路径:C:\Windows\system32\inetsrv\metabase.xml - 低调求发展 - 潜心习安全, S* j& ?2 m E7 a/ a- j3 n4 y
(win2008/2012)iis7.0 7.5配置文件路径:C:\Windows\System32\inetsrv\config\applicationHost.config - 低调求发展4 C" {. T& T; E
- 低调求发展 c: z4 J( e! O) O+ }’ b
导出全部站点的方法:www.t00ls.net7 z5 }" Z8 X3 Y7 v: Z
%windir%\system32\inetsrv\appcmd list site /config /xml > c:\sites.xml - 低调求发展- d( K0 t4 u2 J4 u9 m- T ~! ^’ L: s
http://www.cr173.com/html/19954_1.html
appcmd list vdir >c:\1.txt 列出IIS下所有域名路劲
一:准备工作
APPcmd.exe 位于 C:\Windows\System32\inetsrv 目录
使用 Cd c:\Windows\System32\inetsrv 切换到该目录
二:命令操作简介
IIS 命令行管理工具基本格式:
APPCMD (命令) (对象类型) <标识符> </参数1:值1 …>
支持的对象类型:
SITE 虚拟站点的管理
APP 管理应用程序
VDIR 管理虚