gpt4 book ai didi

command-line - 创建 IIS 6 应用程序池

转载 作者:行者123 更新时间:2023-12-01 08:36:53 25 4
gpt4 key购买 nike

有人可以让我知道如何(或指出正确的方向)我可以创建一个应用程序池并设置一个应用程序以使用命令行使用新创建的池吗?应用程序已添加到 IIS,但需要创建一个新池并将其用于此新应用程序。

最佳答案

这是我收集的,以防其他人正在寻找同样的东西:

rem // Creates a new application pool called MyAppPool
CSCRIPT %SYSTEMDRIVE%\Inetpub\AdminScripts\ADSUTIL.VBS CREATE w3svc/AppPools/MyAppPool IIsApplicationPool

rem // if running under different user name and password
rem CSCRIPT %SYSTEMDRIVE%\Inetpub\AdminScripts\ADSUTIL.VBS SET w3svc/AppPools/MyAppPool/WamUserName "domain\username"
rem CSCRIPT %SYSTEMDRIVE%\Inetpub\AdminScripts\ADSUTIL.VBS SET w3svc/AppPools/MyAppPool/WamUserPass "pass"
rem CSCRIPT %SYSTEMDRIVE%\Inetpub\AdminScripts\ADSUTIL.VBS SET w3svc/AppPools/MyAppPool/AppPoolIdentityType 3
========================================

rem // create a new virtual directory (creates vdir "Test" and set it to D:\WebSites\MyWebSite
CSCRIPT %SystemRoot%\system32\iisvdir.vbs /Create W3SVC/1/ROOT Test D:\WebSites\MyWebSite
=================================

rem // assign MyAppPool to "Test" web site
CSCRIPT %SYSTEMDRIVE%\Inetpub\AdminScripts\ADSUTIL.VBS SET W3SVC/1/ROOT/Test/AppPoolId MyAppPool

关于command-line - 创建 IIS 6 应用程序池,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/17454355/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com