如何设置使 HMC 4.0 创建的用户的密码永不过期

HMC 4.0 创建的用户,默认的帐户属性里面没有设置密码永不过期,这样就会产生个问题,在用户密码过期后,用户无法通过 OWA 再去修改或者重置密码,将会导致用户无法访问邮箱,为了解决这一问题,我们需要修改 MPS 默认的创建用户的脚本,通过设置 "userAccountControl" 的属性来达到默认就是密码永不过期的目的。
  1. 以管理员身份登陆 MPS (MPSSQL),打开 Provisioning Manager
  2. 在名称空间 "Hosted Active Directory" 中打开 "CreateUser" 过程的属性,找到更改用户的调用脚本 - Managed Active Directory::ModifyUser: <execute namespace="Managed Active Directory" procedure="ModifyUser" impersonate="1">
    注释或者去掉以下的2句判断语句
    <when select="isAdmin" case="1" />
    <when select="isBiz" case="0" /> 
  3. 改完之后应该类似这样
    <execute namespace="Managed Active Directory" procedure="ModifyUser" impersonate="1">
    <executeData>
    <user/>
    <properties>
    <!-- sets the password to never expire -->
    <property name="userAccountControl">
    <value>65536</value>
    </property>
    </properties>
    </executeData>
    <before source="procedureData" sourcePath="path" destination="executeData" destinationPath="user" mode="merge"/>
    <before source="data" sourcePath="preferredDomainController" destination="executeData" mode="insert"/>
    </execute>
  4. 点击 "Apply" 保存修改。
解释:userAccountControl 属性中,值设置成 65536 表示设置密码永不过期
<when select="isAdmin" case="1" />
<when select="isBiz" case="0" />
这2句很好理解,就是如果创建的用户是管理员的,密码就永不过期,如果是一般用户,就是默认设置,有密码有效期的

参考的文章:

Microsoft KB:http://support.microsoft.com/kb/305144
MSDN:User-Account-Control Attribute - http://msdn2.microsoft.com/en-us/library/ms680832.aspx

Leave a comment

Recent Entries

  • How to remove a VMHost from SCVMM 2008 R2 forcefully

    这几天碰到个问题,有个服务器原来安装的是 2008 Server Core系统,上面跑 Hyper-V,已经将其导入 SCVMM 2008 R2 来管理。最近实在是嫌 Server Core 管理太不方便,于是想把系统换成带图形界面的,也没在 SCVMM 里面把主机删除,直接就重装了,IP和计算机名什么的都没变,结果问题来了,再打开 SCVMM 的控制台,发现这台主机联系不上(当然,因为重装的没有了 Agent),就想删掉再重加,结果删除过程报错:Error (801) VMM cannot find ISO object . Recommended...

  • Outlook Mobile Update

    现在你可通过新的Microsoft Office Outlook Mobile更新程序和 Microsoft Exchange Server 2010 来保证你手上的信息是最有价值的。 这次的 Outlook Mobile 更新仅针对 Windows Mobile 6.1 的手机。 当你的手机连接到 Exchange Server 2010 时,如果有适合的更新你会收到自动的提示。 如果你的手机的系统是 Windows Mobile...

  • 哥们,我的更新汇总在哪呢?

    我刚刚在我全新的 Exchange 2010 服务器上安装了更新汇总1 - RU1, 然后运行 Get-Exchangeserver -Identity MyExchangeServer (译者: 可以用 Get-Exchangeserver -Identity MyExchangeServer | fl ExchangeVersion, AdminDisplayVersion)得到以下关于AdminsDisplayVersion 和 ExchangeVersion 的版本信息: 嗯, 这看上去有点眼熟(译者:...

  • Exchange 2010 Update Rollup 2

    Today Microsoft released Update Rollup 2 for Microsoft Exchange Server 2010. RU2 comes 3 months after the release of RU1. The list of included fixes...

  • HMC 4.0 Update Rollup 3 has been updated

    Description of Update Rollup 3 for Hosted Messaging and Collaboration 4.0http://support.microsoft.com/kb/979702/en-usMicrosoft released an update rollup that is dated December 2009. This update fixes issues that...

Close