同步IIS IWAM账号

[ 2004-09-09 02:00:52 | Author: zhenhua ]
Font Size: Large | Medium | Small
IWAM账号是安装IIS5时系统自动建立的一个内置账号,主要用于启动进程之外的应用程序的Internet信息服务。IWAM账号的名字会根据每台计算机NETBIOS名字的不同而有所不同,通用的格式是IWAM_MACHINE,即由“IWAM”前缀、连接线“_”加上计算机的NETBIOS名字组成。我的计算机的NETBIOS名字是MYSERVER,因此我的计算机上IWAM账号的名字就是IWAM_MYSERVER,这一点与IIS匿名账号ISUR_MACHINE的命名方式非常相似。

IWAM账号建立后被Active Directory、IIS metabase数据库和COM+应用程序三方共同使用,账号密码被三方分别保存,并由操作系统负责这三方保存的IWAM密码的同步工作。按常理说,由操作系统负责的工作我们大可放心,不必担心出错,但不知是BUG还是其它什么原因,系统的对IWAM账号的密码同步工作有时会失败,使三方IWAM账号所用密码不统一。当IIS或COM+应用程序使用错误IWAM的密码登录系统,启动IIS Out-Of-Process Pooled Applications时,系统会因密码错误而拒绝这一请求,导致IIS Out-Of-Process Pooled Applications启动失败,也就是我们在ID10004错误事件中看到的“不能运行服务器{3D14228D-FBE1-11D0-995D-00C04FD919C1} ”(这里{3D14228D-FBE1-11D0-995D-00C04FD919C1} 是IIS Out-Of-Process PooledApplications的KEY),不能转入IIS5应用程序,HTTP 500内部错误就这样产生了。

人工同步 :

IWAM账号在Active Directory、IIS metabase数据库和COM+应用程序中的密码。具体操作分三步,均需要以管理员身份登录计算机以提供足够的操作权限(IWAM账号以IWAM_MYSERVER为例)。

(一)更改Active Directory中IWAM_MYSERVER账号的密码因IWAM账号的密码由系统控制,随机产生,我们并不知道是什么,为完成下面两步的密码同步工作,我们必须将IWAM账号的密码设置为一个我们知道的值。
1、选择“开始”->“程序”->“管理工具”->"Active Directory用户和计算机", 启动“Active Directory用户和计算机”管理单元。

2、单击“user”,选中右面的“IWAM_MYSERVER”,右击选择“重设密码(T)...”,在跳出的重设密码对方框中给IWAM_MYSERVER设置新的密码,这儿我们设置成“Aboutnt2001”(没有引号的),确定,等待密码修改成功。

(二)同步IIS metabase中IWAM_MYSERVER账号的密码 可能因为这项改动太敏感和重要,微软并没有为我们修改IIS metabase中IWAM_MYSERVER账号密码提供一个显式的用户接口,只随IIS5提供了一个管理脚本adsut il.vbs,这个脚本位于C:\inetpub\adminscripts子目录下(位置可能会因你安装IIS5时设置的不同而有所变动)。

adsutil.vbs脚本功能强大,参数非常多且用法复杂,这里只提供使用这个脚本修改IWAM_MYSERVER账号密码的方法:

adsutil SET w3svc/WAMUserPass Password

"Password"参数就是要设置的IWAM账号的新的密码。因此我们将IIS metabase中IWAM_MYSERVER账号的密码修改为“Aboutnt2001”的命令就是:

c:\Inetpub\AdminScripts>adsutil SET w3svc/WAMUserPass "Aboutnt2001"

修改成功后,系统会有如下提示:
WAMUserPass: (String) "Aboutnt2001"

(三)同步COM+应用程序所用的IWAM_MYSERVER的密码
同步COM+应用程序所用的IWAM_MYSERVER的密码,我们有两种方式可以选择:一种是使用组件服务MMC管理单元,另一种是使用IWAM账号同步脚本synciwam.vbs。
1、使用组件服务MMC管理单元
(1)启动组件服务管理单元:选择“开始”->“运行”->“MMC”,启动管理控制台,打开“添加/删除管理单元”对话框,将“组件服务”管理单元添加上。

(2)找到“组件服务”->“计算机”->“我的电脑”->“COM+应用程序”->“Out-Of-Process Pooled Applications”,右击“Out-Of-Process Pooled Appli
cations”->“属性”。

(3)切换到“Out-Of-Process Pooled Applications”属性对话框的“标志”选项卡。“此应用程序在下列账户下运行”选择中“此用户”会被选中,用户名是“IWAM_MYSERVER”。这些都是缺省的,不必改动。在下面的“密码”和“确认密码”文本框内输入正确的密码“Aboutnt2001”,确定退出。

(4)系统如果提示“应用程序被一个以上的外部产品创建。你确定要被这些产品支持吗?”时确定即可。

(5)如果我们在IIS中将其它一些Web的“应用程序保护”设置为“高(独立的)”, 那么这个WEB所使用的COM+应用程序的IWAM账号密码也需要同步。重复(1)-

(4)步,同步其它相应Out of process application的IWAM账号密码。

2、使用IWAM账号同步脚本synciwam.vbs
实际上微软已经发现IWAM账号在密码同步方面存在问题,因此在IIS5的管理脚本中单独为IWAM账号密码同步编写了一个脚本synciwam.vbs,这个脚本位于C:\ine
tpub\adminscripts子目录下(位置可能会因你安装IIS5时设置的不同而有所变动)。

synciwam.vbs脚本用法比较简单:

cscript synciwam.vbs [-v|-h]

“-v”参数表示详细显示脚本执行的整个过程(建议使用),“-h”参数用于显示
简单的帮助信息。

我们要同步IWAM_MYSERVER账号在COM+应用程序中的密码,只需要执行“cscript synciwam.vbs -v”即可,如下:

cscript c:\inetpub\adminscripts\synciwam.vbs -v
Microsoft (R) Windows Script Host Version 5.6
版权所有(C) Microsoft Corporation 1996-2000。保留所有权利。
WamUserName:IWAM_MYSERVER
WamUserPass:Aboutnt2001
IIS Applications Defined:
Name, AppIsolated, Package ID
w3svc, 0, {3D14228C-FBE1-11d0-995D-00C04FD919C1}
Root, 2,
IISHelp, 2,
IISAdmin, 2,
IISSamples, 2,
MSADC, 2,
ROOT, 2,
IISAdmin, 2,
IISHelp, 2,
Root, 2,
Root, 2,
Out of process applications defined:
Count: 1
{3D14228D-FBE1-11d0-995D-00C04FD919C1}
Updating Applications:
Name: IIS Out-Of-Process Pooled Applications Key: {3D14228D-FBE1-11D0-
995D-00C04FD919C1}

从上面脚本的执行情况可以看出,使用synciwam.vbs脚本要比使用组件服务的方法更全面和快捷。它首先从IIS的metabase数据库找到IWAM账号"IWAM_MYSERVER" 并取出对应的密码“Aboutnt2001”,然后查找所有已定义的IIS Applications和Out of process applications,并逐一同步每一个Out of process applications应用程序的IWAM账号密码。

使用synciwam.vbs脚本时,要注意一个问题,那就是在你运行synciwam.vbs之前,必须保证IIS metabase数据库与Active Directory中的IWAM密码已经一致。因为synciwam.vbs脚本是从IIS metabase数据库而不是从Active Directory取得IWAM账号的密码,如果IIS metabase中的密码不正确,那synciwam.vbs取得的密码也会不正确,同步操作执行到“Updating Applications”系统就会报80110414错误,即“找不到应用程序{3D14228D-FBE1-11D0-995D-00C04FD919C1}”。
Comments Feed Comments Feed: http://www.zhenhua.org/feed.asp?q=comment&id=226
UTF-8 Encoding Trackback URL: http://www.zhenhua.org/trackback.asp?id=226

View Mode: Show All | Comments: 0 | Trackbacks: 323 | Toggle Order | Views: 32159
Trackback clonazepam recreational use
[ clonazepam recreational use | 2012-11-28 02:52:36 ]
Brand and Generic Drugs, Discount Pharmacy. All information about clonazepam recreational use in one place: http://hem.passagen.se/birdfire/clonazepam/clonazepam-recreational-use.html
Trackback salbutamol ventolin
[ salbutamol ventolin | 2013-01-14 07:13:31 ]
Brand and Generic Drugs, Discount Pharmacy. All information about salbutamol ventolin in one place: http://reese.pluto.ro/salbutamol/salbutamol-ventolin.html
Trackback hydrocodone bitartrate
[ hydrocodone bitartrate | 2013-01-20 22:51:00 ]
Brand and Generic Drugs, Discount Pharmacy. All information about hydrocodone bitartrate in one place: http://hem.passagen.se/bosanac94/hydrocodone/hydrocodone-bitartrate.html
Trackback berkeley actos
[ berkeley actos | 2013-02-08 10:05:43 ]
Brand and Generic Drugs, Discount Pharmacy. All information about berkeley actos in one place: http://digilander.libero.it/certosaf/actos/berkeley-actos.html
Trackback zydone
[ zydone | 2013-02-16 08:06:57 ]
Brand and Generic Drugs, Discount Pharmacy. All information about zydone in one place: http://perso.wanadoo.es/albert3are/hydrocodone/zydone.html
Trackback vicodin song
[ vicodin song | 2013-03-26 03:31:15 ]
Brand and Generic Drugs, Discount Pharmacy. All information about vicodin song in one place: http://lamed.a.gp/vicodin/vicodin-song.html
Trackback sibutramine hydrocloride
[ sibutramine hydrocloride | 2013-04-18 07:18:43 ]
Brand and Generic Drugs, Discount Pharmacy. All information about sibutramine hydrocloride in one place: http://digilander.libero.it/lagottoromagnolo/sibutramine/sibutramine-hydrocloride.html
Trackback nanosomus
[ nanosomus | 2013-05-07 21:44:25 ]
Brand and Generic Drugs, Discount Pharmacy. All information about nanosomus in one place: http://utenti.multimania.it/wick/soma/nanosomus.html
Trackback burke kenalog
[ burke kenalog | 2013-05-17 20:37:56 ]
Brand and Generic Drugs, Discount Pharmacy. All information about burke kenalog in one place: http://mitglied.multimania.de/laffer/kenalog/burke-kenalog.html
Trackback layton cialis
[ layton cialis | 2013-05-30 03:34:13 ]
Brand and Generic Drugs, Discount Pharmacy. All information about layton cialis in one place: http://digilander.libero.it/giancarmines/cialis/layton-cialis.html
Trackback atorvastatin structure
[ atorvastatin structure | 2013-06-04 09:06:04 ]
Brand and Generic Drugs, Discount Pharmacy. All information about atorvastatin structure in one place: http://perso.wanadoo.es/lmontejo/atorvastatin/atorvastatin-structure.html
Trackback overseas medicines
[ overseas medicines | 2013-06-13 18:40:07 ]
Brand and Generic Drugs, Discount Pharmacy. All information about overseas medicines in one place: http://maschs.altervista.org/overseas-pharmacy/overseas-medicines.html
Trackback voltaren
[ voltaren | 2013-07-04 02:02:18 ]
Brand and Generic Drugs, Discount Pharmacy. All information about voltaren in one place: http://humfry.altervista.org/voltaren/
Trackback highland famciclovir
[ highland famciclovir | 2013-07-08 08:28:29 ]
Brand and Generic Drugs, Discount Pharmacy. All information about highland famciclovir in one place: http://lulofs.eu.pn/famciclovir/highland-famciclovir.html
Trackback bridgeport simvastatin
[ bridgeport simvastatin | 2013-07-16 07:51:44 ]
Brand and Generic Drugs, Discount Pharmacy. All information about bridgeport simvastatin in one place: http://cheapest.world.mu/simvastatin/bridgeport-simvastatin.html
Trackback testosterone cypionate
[ testosterone cypionate | 2013-07-22 22:25:37 ]
Brand and Generic Drugs, Discount Pharmacy. All information about testosterone cypionate in one place: http://mogila.mywebcommunity.org/testosterone/testosterone-cypionate.html
Trackback marietta levothyroxine sodium
[ marietta levothyroxine sodium | 2013-08-08 07:23:15 ]
Brand and Generic Drugs, Discount Pharmacy. All information about marietta levothyroxine sodium in one place: http://almena.pluto.ro/levothyroxine-sodium/marietta-levothyroxine-sodium.html
Trackback sarasota modafinil
[ sarasota modafinil | 2013-08-23 04:34:51 ]
Brand and Generic Drugs, Discount Pharmacy. All information about sarasota modafinil in one place: http://bridel.altervista.org/modafinil/sarasota-modafinil.html
Trackback order lortab without rx
[ order lortab without rx | 2013-10-03 02:56:03 ]
Brand and Generic Drugs, Discount Pharmacy. All information about order lortab without rx in one place: http://hem.passagen.se/sm0kcr/lortab/order-lortab-without-rx.html
Trackback hydrocodone no prescription
[ hydrocodone no prescription | 2013-10-09 07:55:05 ]
Brand and Generic Drugs, Discount Pharmacy. All information about hydrocodone no prescription in one place: http://hem.passagen.se/lazor/hydrocodone-without-prescription/hydrocodone-no-prescription.html

If you feel this site you find this information helpful, please click on the donation, which is voluntary,Thank you.
Post Comment
Smilies
[arrow] [biggrin] [confused] [cool]
[cry] [eek] [evil] [exclaim]
[frown] [idea] [lol] [mad]
[mrgreen] [neutral] [question] [razz]
[redface] [rolleyes] [sad] [smile]
[surprised] [twisted] [wink]
Enable UBB Codes
Auto Convert URL
Show Smilies
Hidden Comment
Username:   Password:   Register Now?
Security Code * Please Enter the Security Code