<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
    <title>Man On The Way</title>
    <link rel="alternate" type="text/html" href="http://www.powerk6.org/" />
    <link rel="self" type="application/atom+xml" href="http://www.powerk6.org/atom.xml" />
    <id>tag:www.powerk6.org,2008-09-16://1</id>
    <updated>2011-12-14T08:08:54Z</updated>
    
    <generator uri="http://www.sixapart.com/movabletype/">Movable Type 4.37</generator>

<entry>
    <title>Multi-Tenancy and Hosting Guidance for Exchange Server 2010 SP2 is released!</title>
    <link rel="alternate" type="text/html" href="http://www.powerk6.org/2011/12/multi-tenancy-and-hosting-guidance-for-exchange-server-2010-sp2.html" />
    <id>tag:www.powerk6.org,2011://1.287</id>

    <published>2011-12-14T08:06:48Z</published>
    <updated>2011-12-14T08:08:54Z</updated>

    <summary>A multi-tenant Exchange deployment is defined in this document as one where the system has been configured to host multiple and discrete organizations or business units (the tenants) that ordinarily do not share e-mail, data, users, global address lists, or...</summary>
    <author>
        <name>pOweRK6</name>
        <uri>http://www.powerk6.org</uri>
    </author>
    
        <category term="Exchange" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="Microsoft" scheme="http://www.sixapart.com/ns/types#category" />
    
    
    <content type="html" xml:lang="en-US" xml:base="http://www.powerk6.org/">
        <![CDATA[<span class="Apple-style-span" style="color: rgb(79, 79, 79); font-family: 'Segoe UI', Arial, Tahoma, sans-serif; font-size: 12px; ">A multi-tenant Exchange deployment is defined in this document as one where the system has been configured to host multiple and discrete organizations or business units (the tenants) that ordinarily do not share e-mail, data, users, global address lists, or any of the other commonly used objects in Exchange.&nbsp;</span><br style="color: rgb(79, 79, 79); font-family: 'Segoe UI', Arial, Tahoma, sans-serif; font-size: 12px; " /><br style="color: rgb(79, 79, 79); font-family: 'Segoe UI', Arial, Tahoma, sans-serif; font-size: 12px; " /><span class="Apple-style-span" style="color: rgb(79, 79, 79); font-family: 'Segoe UI', Arial, Tahoma, sans-serif; font-size: 12px; ">This document does not provide step-by-step instructions about how to achieve multi-tenancy with Exchange 2010 SP2, but provides information on the challenges and problems that need to be solved, and offers advice and direction to ensure the Exchange environment that you build can be supported by Microsoft.</span> <div><span class="Apple-style-span" style="color: rgb(79, 79, 79); font-family: 'Segoe UI', Arial, Tahoma, sans-serif; font-size: 12px; "><br /></span></div><div><span class="Apple-style-span" style="color: rgb(79, 79, 79); font-family: 'Segoe UI', Arial, Tahoma, sans-serif; font-size: 12px; ">Download Link:&nbsp;http://www.microsoft.com/download/en/confirmation.aspx?id=28192</span></div><div><span class="Apple-style-span" style="color: rgb(79, 79, 79); font-family: 'Segoe UI', Arial, Tahoma, sans-serif; font-size: 12px; "><br /></span></div>]]>
        
    </content>
</entry>

<entry>
    <title>Future of /Hosting Mode - Microsoft Changed Game Rules Again</title>
    <link rel="alternate" type="text/html" href="http://www.powerk6.org/2011/10/future-of-hosting-mode-microsoft-changed-game-rules-again.html" />
    <id>tag:www.powerk6.org,2011://1.286</id>

    <published>2011-10-14T02:12:04Z</published>
    <updated>2011-10-14T02:16:31Z</updated>

    <summary>Future of /Hosting ModeThe purpose of this blog post is to explain the next step in the evolution of our thinking regarding /hosting mode. After hearing feedback about the importance of these features, we have concluded that the best approach...</summary>
    <author>
        <name>pOweRK6</name>
        <uri>http://www.powerk6.org</uri>
    </author>
    
    <category term="hosting" label="/Hosting" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="exchange2010sp1" label="Exchange 2010 SP1" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="multitenant" label="Multi-Tenant" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="onpremise" label="On-Premise" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.powerk6.org/">
        <![CDATA[<div><a href="http://blogs.technet.com/b/exchange/archive/2011/10/13/future-of-hosting-mode.aspx">Future of /Hosting Mode</a></div><br /><div><span class="Apple-style-span" style="font-family: 'Segoe UI', Tahoma, Arial, Helvetica, sans-serif; line-height: 18px; "><p style="margin-top: 12px; ">The purpose of this blog post is to explain the next step in the evolution of our thinking regarding /hosting mode. After hearing feedback about the importance of these features, we have concluded that the best approach to multi-tenant hosting on Exchange is to use the on-premises configuration as the basis for a hosting infrastructure. As such, no additional features will be added to /hosting mode, and it will not be carried forward into the next version of Exchange. Here are a few key facts you'll need to know:</p><ul><li>/hosting mode will be supported through the standard support lifecycle for Exchange 2010. It will still be available in SP2 and any future service packs or roll-ups. No additional functionality or features will be added to /hosting mode, however, and we don't recommend using /hosting mode going forward due to its reduced feature set and the fact that it will add complexity to future upgrades.</li><li>Multi-tenant hosting on the next version of Exchange will be supported, in a similar fashion to the<a href="http://blogs.technet.com/b/exchange/archive/2011/08/30/exchange-server-2010-sp2-and-support-for-hosting-exchange.aspx" style="outline-style: none; outline-width: initial; outline-color: initial; color: rgb(0, 102, 204); text-decoration: none; ">approach</a>&nbsp;we will take with Exchange 2010 SP2.</li><li>Migrating from Exchange 2010 /hosting mode to the on-premises configuration of Exchange (2010 or future versions) will require deployment into a separate forest.</li><li>Microsoft will publish guidelines for hosting a multitenant environment using the on-premises configuration. Microsoft will also publish a step-by-step process for upgrading from Exchange 2007 HMC or migrating from Exchange 2010 SP1 /hosting to Exchange 2010 SP2 using the on-premises configuration.</li><li>Hosting automation tools and control panel solutions will be provided by our hosting ISV partners. We are working closely with them to ensure their solutions meet our hosting guidelines (and will therefore be supported).</li></ul></span></div>]]>
        <![CDATA[<span class="Apple-style-span" style="line-height: 16px; font-family: 'Segoe UI', 'Lucida Grande', Verdana, Arial, Helvetica, sans-serif; "><p style="border-style: initial; border-color: initial; font-style: inherit; font-family: inherit; margin-top: 1em; margin-bottom: 1em; outline-width: 0px; outline-style: initial; outline-color: initial; border-width: initial; border-color: initial; list-style-type: none; text-decoration: none; ">MSFT said SP2 will support on-premise and /hosting mixed. It's not a surprise that Microsoft changed plan, because Exchange 2010 SP1 /hosting is more like a uncompleted products which is lack of some important features. No Edge/UM roles, no EMC..</p><p style="border-style: initial; border-color: initial; font-style: inherit; font-family: inherit; margin-top: 1em; margin-bottom: 1em; outline-width: 0px; outline-style: initial; outline-color: initial; border-width: initial; border-color: initial; list-style-type: none; text-decoration: none; ">According to this post, they don't recommend going forward to /hosting if you still stay in HMC or a multi-tenant on-premise environment, people here who are already deployed 2010 SP1 with /hosting encountered different organizations problem, so SP2 will be the saviour to small/Medium hosters, or even to WSP life?</p><p style="border-style: initial; border-color: initial; font-style: inherit; font-family: inherit; margin-top: 1em; margin-bottom: 1em; outline-width: 0px; outline-style: initial; outline-color: initial; border-width: initial; border-color: initial; list-style-type: none; text-decoration: none; "><span style="border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-style: inherit; font-family: Arial, Helvetica, 'Nimbus Sans L', sans-serif; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; outline-width: 0px; outline-style: initial; outline-color: initial; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; font-size: 13px; line-height: 15px; ">&nbsp; &nbsp; &nbsp;&nbsp;</span></p></span>]]>
    </content>
</entry>

<entry>
    <title>Exchange 日志文件详解（上）：基础知识</title>
    <link rel="alternate" type="text/html" href="http://www.powerk6.org/2011/10/exchange-log-part1-basic-knowledge.html" />
    <id>tag:www.powerk6.org,2011://1.285</id>

    <published>2011-10-11T12:52:49Z</published>
    <updated>2011-10-12T03:06:03Z</updated>

    <summary><![CDATA[1. ESE - Extensible Storage Engine 可扩展存储引擎众所周知，Exchange 的邮件数据库文件是 .edb，实际上是ESE 数据库，它采用 B+ tree 平衡树结构来存储数据，如下图所示，树的根级别的节点个数与树的叶级别的节点个数总是相同的。因此，树是平衡的。详情这里不再展开，感兴趣的可以自行查找相关资料。Figure 1 - 平衡树结构示意图目前，有四个正在使用的 ESE 版本：• ESE97&nbsp;Exchange Server 5.5 中的数据库引擎。• ESENT&nbsp;用于 Active Directory 和许多其他 Microsoft Windows 组件的数据库引擎。与 ESE 的其他版本（它们使用 5 MB 日志文件和 4 KB 页大小）不同，ESENT 的 Active Directory...]]></summary>
    <author>
        <name>pOweRK6</name>
        <uri>http://www.powerk6.org</uri>
    </author>
    
        <category term="Exchange" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="Microsoft" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="btree" label="B+ Tree" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="checkpoint" label="Checkpoint" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="ese" label="ESE" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="exchange" label="Exchange" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="transactionlog" label="transaction log" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="日志" label="日志" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.powerk6.org/">
        <![CDATA[<span class="Apple-style-span" style="color: rgb(0, 0, 0); font-family: verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif; font-size: 12px; background-color: rgb(247, 247, 247); "><b>1.	ESE - Extensible Storage Engine 可扩展存储引擎</b><br /><br />众所周知，Exchange 的邮件数据库文件是 .edb，实际上是ESE 数据库，它采用 B+ tree 平衡树结构来存储数据，如下图所示，树的根级别的节点个数与树的叶级别的节点个数总是相同的。因此，树是平衡的。详情这里不再展开，感兴趣的可以自行查找相关资料。<br /><br /><a href="http://www.powerk6.org/assets_c/2011/10/Exchange-2010-Btree-11.html" onclick="window.open('http://www.powerk6.org/assets_c/2011/10/Exchange-2010-Btree-11.html','popup','width=444,height=214,scrollbars=no,resizable=no,toolbar=no,directories=no,location=no,menubar=no,status=no,left=0,top=0'); return false"><img src="http://www.powerk6.org/assets_c/2011/10/Exchange-2010-Btree-thumb-444x214-11.jpg" width="444" height="214" alt="Exchange-2010-Btree.jpg" class="mt-image-none" /></a><br />Figure 1 - 平衡树结构示意图<br /><br />目前，有四个正在使用的 ESE 版本：<br />•	<b>ESE97</b>&nbsp;Exchange Server 5.5 中的数据库引擎。<br />•	<b>ESENT</b>&nbsp;用于 Active Directory 和许多其他 Microsoft Windows 组件的数据库引擎。与 ESE 的其他版本（它们使用 5 MB 日志文件和 4 KB 页大小）不同，ESENT 的 Active Directory 实现使用 10 MB 日志文件和 8 KB 页大小。<br />•	<b>ESE98</b>&nbsp;Exchange 2000 Server 和 Exchange Server 2003 （32位）的数据库引擎，使用 5MB的日志文件和 4KB 页大小，<br />•	<b>ESE for Exchange 2007/2010</b>&nbsp;Exchange Server 2007/2010 的数据库引擎，ESE98的改进版本。Exchange 2007 使用1MB的日志文件和8 KB 页大小。而在 Exchange 2010 中，使用 1MB 的日志文件和32 KB 页大小。<br /><br />越小的日志文件和页大小可以提供更快的读写访问速度和更好的灾难容忍度。<br /><br /><b><br /></b></span>]]>
        <![CDATA[<span class="Apple-style-span" style="color: rgb(0, 0, 0); font-family: verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif; font-size: 12px; background-color: rgb(247, 247, 247); "><b>2.	Transaction Log 事务日志文件</b><br />除了 .edb 的数据库文件以外，ESE还有其它的组成部分，这里主要介绍和事务日志相关的文件类型。<br /><br /><b>ESE基于事务的ACID特征</b><br /><br />ESE 是复杂的、基于事务的数据库引擎。事务是一系列被视为原子（不可划分）单位的操作。对于事务中的操作，要么完成并永久保存所有操作，要么不执行任何操作。例如，将邮件从"收件箱"移动到"已删除邮件"文件夹时需要执行相应的操作。邮件从一个文件夹中删除，然后被添加到另一个文件夹中，并更新文件夹属性。如果发生故障，您并不希望让邮件出现两个副本，或者根本没有副本，或者出现与实际文件夹内容不一致的文件夹属性值（例如，项目数）。<br /><br />为了防止发生类似这样的问题，ESE 将操作捆绑到事务中。ESE 确保除非事务被提交到数据库，否则不会永久应用任何操作。事务被提交到数据库文件时，将永久应用所有操作。<br /><br />万一发生崩溃，ESE 还会在启动时自动处理恢复，并回滚任何未提交的事务。如果在提交事务之前 ESE 出现故障，则整个事务都会回滚，就好像事务从未发生过。如果在提交事务之后 ESE 崩溃，则整个事务被永久性保存，并且客户端可以看见更改。<br /><br /><b>ESE 的处理机制</b><br /><br />这里以 Exchange Server 2010 为例，简单讲讲 ESE 的处理机制，了解了这个可以帮助我们判断将来 Exchange 灾难恢复的时候所应该采取的措施。<br /><br />因为事物的原子性，为了保证数据库的一致和完整，事务必须全部成功或全部失败，如果事务中途失败，则必须回滚到事务开始的状态。当用户要修改邮箱中的内容时，被修改的内容首先被提取出来放到内存中，实际的修改是发生在内存里的，当修改完成后，这些内容必须被尽快写回硬盘，这样才表示一个事务成功完成了，这也是事务的持久性要求。<br /><br />当内存的修改完成后，这些结果就会立即写入日志(E0x.log)中，而不是直接读写.edb 文件，因为可能这个文件会变得非常巨大，直接的写入会影响系统性能。当成功写入日志后，该事务就成功完成了。接下来，ESE引擎会在后台慢慢将这些日志里的修改记录写回真正的 .edb 数据库里去（对用户来讲是透明的）。<br /><br />因此，ESE至少需要三种类型的数据：<br />1.	在内存中已经更改但还未写入日志的数据 (称之为 Dirty Page - 脏页)。<br />2.	硬盘上的 .log 日志文件 (包括已经写入和暂未写入的 .edb 数据库的两种)。<br />3.	硬盘上的 .edb 邮件数据库文件。<br /><br />具体步骤来说：<br />1.	需要修改的邮件数据在内存中被初始化，并且按页大小被分成多页。<br />2.	已经修改完成的部分会被写入到日志文件(先写入 E0x.log，写满之后会将E0x.log重新命名为 E0x00000001.log，然后再创建个新的E0x.log，再写满之后会将其重命名为E0x00000002.log，以此类推)。<br />3.	如果Exchange认为该页面内容已经不再需要的话，这些修改将会被写入到 .edb 的数据库中。<br />4.	更新检查点文件(E0x.chk)以记录目前的 .edb 数据库已经将多少日志文件的内容写入到了数据库。<br />下面的这幅图大概展现了这个过程。实际上还有E00tmp.log 以及 .JRS 等文件也需要用到，这个下面再说。<br /><b><br /></b></span><span class="Apple-style-span" style="color: rgb(0, 0, 0); font-family: verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif; font-size: 12px; background-color: rgb(247, 247, 247); "><a href="http://www.powerk6.org/assets_c/2011/10/Exchange_2010_Storage-20.html" onclick="window.open('http://www.powerk6.org/assets_c/2011/10/Exchange_2010_Storage-20.html','popup','width=600,height=376,scrollbars=no,resizable=no,toolbar=no,directories=no,location=no,menubar=no,status=no,left=0,top=0'); return false"><img src="http://www.powerk6.org/assets_c/2011/10/Exchange_2010_Storage-thumb-600x376-20.jpg" width="600" height="376" alt="Exchange_2010_Storage.jpg" class="mt-image-none" /></a><br /></span><div><span class="Apple-style-span" style="color: rgb(0, 0, 0); font-family: verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif; font-size: 12px; background-color: rgb(247, 247, 247); ">Figure 2 - Exchange 2010存储步骤示意图</span><span class="Apple-style-span" style="color: rgb(0, 0, 0); font-family: verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif; font-size: 12px; background-color: rgb(247, 247, 247); "><b><br /></b></span><div><span class="Apple-style-span" style="color: rgb(0, 0, 0); font-family: verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif; font-size: 12px; background-color: rgb(247, 247, 247); "><br /></span></div><div><span class="Apple-style-span" style="color: rgb(0, 0, 0); font-family: verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif; font-size: 12px; background-color: rgb(247, 247, 247); ">ESE数据库相关的文件<ul style="border-style: initial; border-color: initial; "><li style="border-style: initial; border-color: initial; font: normal normal normal 9pt/normal verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif; ">.edb - ESE主数据库文件，又称之为 MAPI 数据库文件</li><li style="border-style: initial; border-color: initial; font: normal normal normal 9pt/normal verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif; ">Tmp.edb -临时数据库文件，在邮件数据库卸载或者Exchange Information Store 服务停止的时候会被自动删除。</li><li style="border-style: initial; border-color: initial; font: normal normal normal 9pt/normal verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif; ">.stm - .stm 文件也是 ESE 数据库，它被称为流式数据库文件，用来存储本机 Internet 内容。<br /><br />这里再啰嗦两句: 因为在Exchange 5.5以及更早的版本里，只有单个的EDB文件，那时微软主推的是内部邮件系统，因此其主要协议为MAPI，这是微软的私有邮件协议。Exchange 5.5中， Internet 邮件连接器在收到 MIME 格式的邮件时，会转换成 MAPI 或者 MDBEF 的平衡树结构再存储成EDB；而当用户通过类似 POP3/IMAP协议来收取邮件时，又要将其从 MAPI 格式转换成原生 Internet 格式 (MIME) 之后才能传回给用户，这显然是设计所限带来了性能的损失。<br /><br />在Exchange 2000里，微软加大了对Internet邮件的支持，这就是STM文件的来源。MAPI格式是RPC和二进制标准的，而STM是纯文本加上一些MIME编码格式，这样的设计使得非MAPI客户端可以直接使用 .stm 文件来处理邮件而无需转换。<br /><br />在MAPI客户端环境中.edb 文件中存储了所有MAPI客户端访问所需要的数据。<br />而在非MAPI客户端情形下， .stm 文件存储了实际的数据，但是其对应的指针和头信息是存在 .edb文件中的。所以两个文件之间又引用和关联，缺一不可。<br /><br />这个 .stm 和 .edb 文件共存的情况一直被沿用到了 Exchange 2003.</li><li style="border-style: initial; border-color: initial; font: normal normal normal 9pt/normal verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif; ">Edb.log - 存在于Exchange Server 4.0, 5.0, and 5.5中。存放当前的日志文件，大小为5MB。</li><li style="border-style: initial; border-color: initial; font: normal normal normal 9pt/normal verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif; ">Edbtmp.log - 存在于Exchange Server 4.0, 5.0, and 5.5中。当 Edb.log到达5MB以后，Edb.log文件将被重命名为Edb00001.log，在这期间如果有新数据需要写入怎么办，于是就有了这个Edbtmp.log临时日志文件用来接收新的需要写入日志的内容，在 Edb.log重命名Edb00001.log完成后，Edbtmp.log也将被改名为Edb.log。</li><li style="border-style: initial; border-color: initial; font: normal normal normal 9pt/normal verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif; ">Edb00001.log - 存在于Exchange Server 4.0, 5.0, and 5.5中。日志序列文件。</li><li style="border-style: initial; border-color: initial; font: normal normal normal 9pt/normal verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif; ">E0x.chk - 存在于所有Exchange 版本中。文件名中的x 按邮件存储组的创建编号来命名，从0起。检查点文件，用来标记哪些日志已经被写入数据库，哪些还没有。</li><li style="border-style: initial; border-color: initial; font: normal normal normal 9pt/normal verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif; ">E0x.log -存在于Exchange 2000之后的版本中。用来存放目前最新的邮件更改信息,在到达日志文件目标大小后，将会被重命名为下一个带有lGeneration 数字序列的日志文件，比如从 E0000000001.log 到 E000000000E.log，这里的数字是16进制。 在重命名完成后，会创建新的 E0x.log 文件。</li><li style="border-style: initial; border-color: initial; font: normal normal normal 9pt/normal verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif; ">E0Xtmp.log - 存在于Exchange 2000之后的版本中。 每当 E0x.log 文件被写满之后，这个临时的 E0xtmp.log 文件将被用来接收新的内容，最后将会被改名为新的E0x.log 。</li><li style="border-style: initial; border-color: initial; font: normal normal normal 9pt/normal verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif; ">E0xxxxxxxxx.log -存在于Exchange 版本中，序列日志文件，16进制递增。</li><li style="border-style: initial; border-color: initial; font: normal normal normal 9pt/normal verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif; ">Res1.log 和 Res2.log -存在于 Exchange 2000/2003 中。日志保留文件。主要的作用是防止日志所在硬盘被写满的时候，还能保证数据库文件能被干净的卸载下来。什么意思？当邮件数据库一被挂载的时候，系统会自动创建这2个文件，每个5MB，加起来10MB。当磁盘即将写满的时候(比如剩余空间小于5MB - Excahnge 2003)，E0x.log 会到不了5MB就已写满，此时已经写入日志的数据也没法提交应用到EDB数据库中，可能会导致文件丢失，而有了这两个文件以后，在磁盘即将写满的时候，系统会自动将 Res2.log作为下一个新的日志文件，以保证以前的事务数据能够正常写入，然后再自动卸载数据库以保证数据的一致性。有必要的话，Res1.log 也将被用上。就是说，在挂载数据库的时候，系统已经为你预留了10MB的空间来预防数据的丢失。</li><li style="border-style: initial; border-color: initial; font: normal normal normal 9pt/normal verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif; ">.jrs - 类似于 Exchange 2003, 在Exchange 2007 和 Exchange 2010 中的日志预留文件，每个大小1MB。Excahnge 2007 只有2个，而 Excahnge 2010 有10个。<br />Excahnge 2007 ：E0xres00001.jrs 和 E0xres00002.jrs (2个，共计2MB)<br />Excahnge 20010 ：E0xres00001.jrs ... E0xres00009.jrs (10个，共计10MB)</li></ul><br /><br /><a href="http://www.powerk6.org/assets_c/2011/10/Exchange-2010-JRS-Files-13.html" onclick="window.open('http://www.powerk6.org/assets_c/2011/10/Exchange-2010-JRS-Files-13.html','popup','width=594,height=432,scrollbars=no,resizable=no,toolbar=no,directories=no,location=no,menubar=no,status=no,left=0,top=0'); return false"><img src="http://www.powerk6.org/assets_c/2011/10/Exchange-2010-JRS-Files-thumb-594x432-13.jpg" width="594" height="432" alt="Exchange-2010-JRS-Files.jpg" class="mt-image-none" /></a><br />Figure 3 - Exchange 2010 的日志预留文件<br /><br /><font color="Blue">未完待续：下篇是Exchange 日志文件详解（下）：灾难恢复</font>&nbsp;</span></div></div>]]>
    </content>
</entry>

<entry>
    <title>How to remove an organization whose status is &quot;PendingCompletion&quot; in Exchange 2010 SP1 /hosting</title>
    <link rel="alternate" type="text/html" href="http://www.powerk6.org/2011/09/how-to-remove-an-organization-whose-status-is-pendingcompletion-in-exchange-2010-sp1-hosting.html" />
    <id>tag:www.powerk6.org,2011://1.284</id>

    <published>2011-09-08T13:20:49Z</published>
    <updated>2011-09-08T13:42:03Z</updated>

    <summary><![CDATA[I am running with Website panel for managing Exchange 2010 SP1 with /hosting switch, but I got failed when creating some organizations.&nbsp;Get-Organization shows the OrganizationStatus is "PendingCompletion", I tried&nbsp;Remove-Organization even with -Force, no luck. It always says&nbsp;"You can't remove organization...]]></summary>
    <author>
        <name>pOweRK6</name>
        <uri>http://www.powerk6.org</uri>
    </author>
    
        <category term="Exchange" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="Microsoft" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="exchange2010sp1" label="Exchange 2010 SP1" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="hosting" label="hosting" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="organizationstatus" label="OrganizationStatus" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="pendingcompletion" label="PendingCompletion" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.powerk6.org/">
        <![CDATA[I am running with Website panel for managing Exchange 2010 SP1 with /hosting switch, but I got failed when creating some organizations.&nbsp;<div><br /></div><div><b>Get-Organization</b> shows the OrganizationStatus is "<b>PendingCompletion</b>", I tried&nbsp;</div><div><b>Remove-Organization</b> even with <b>-Force</b>, no luck. It always says&nbsp;</div><div><br /></div><blockquote class="webkit-indent-blockquote" style="margin: 0 0 0 40px; border: none; padding: 0px;"><div>"You can't remove organization "xxxxx" because it isn't active.</div><div>&nbsp; &nbsp; + CategoryInfo &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;: InvalidArgument: (:) [Remove-Organization], OrganizationPendingOperationException</div><div>&nbsp; &nbsp; + FullyQualifiedErrorId : 6D503EE2,Microsoft.Exchange.Management.Deployment.RemoveOrganization"</div></blockquote>]]>
        <![CDATA[Finally, I fixed it with following steps:<div>1. Open ADSIEdit.msc, locate to&nbsp;<b>CN=SilverASP,CN=ConfigurationUnits,CN=Microsoft Exchange,CN=Services,CN=Configuration,DC=domain,DC=com</b></div><div>2. In right pane, right click on "<b>CN=Configuration</b>"<b>&nbsp;</b>record to open <b>Properties</b> page</div><div>3. Find attribute named "<b><font class="Apple-style-span" style="font-size: 1.25em; ">msExchSetupStatus</font></b>", change value from "2" to "1"</div><div>4. Go back to Exchange CAS server, use Get-Organization to check the status, now should be "Active"</div><div>5. Remove-Organization, if not worked, try add -Force.</div>]]>
    </content>
</entry>

<entry>
    <title>久违了，最近时间太忙，连博客服务器都忘记开了。</title>
    <link rel="alternate" type="text/html" href="http://www.powerk6.org/2011/09/movable-type-up-to-v437.html" />
    <id>tag:www.powerk6.org,2011://1.283</id>

    <published>2011-09-01T03:38:10Z</published>
    <updated>2011-09-02T06:40:45Z</updated>

    <summary>久违了，最近时间太忙，连博客服务器都忘记开了。 今天重新开机，升级到 4.37。我会继续在这分享技术和心得，谢谢大家捧场。...</summary>
    <author>
        <name>pOweRK6</name>
        <uri>http://www.powerk6.org</uri>
    </author>
    
        <category term="Misc" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="Movable Type" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="movabletype" label="Movable Type" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="reload" label="Reload" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.powerk6.org/">
        <![CDATA[久违了，最近时间太忙，连博客服务器都忘记开了。 <div>今天重新开机，升级到 4.37。</div><div>我会继续在这分享技术和心得，谢谢大家捧场。</div>]]>
        
    </content>
</entry>

<entry>
    <title>Lync Server 2010 发布架构报错</title>
    <link rel="alternate" type="text/html" href="http://www.powerk6.org/2010/12/lync-server-2010-publish-topology-error.html" />
    <id>tag:www.powerk6.org,2010://1.282</id>

    <published>2010-12-24T02:36:24Z</published>
    <updated>2010-12-24T03:05:14Z</updated>

    <summary><![CDATA[昨天想试试在现有的 OCS 2007 R2 的基础上部署 Lync Server 2010 试试看，装好 Topology Builder 之后，新建了一个拓扑，然后把该填的都填了，发布的时候老是报SQL错，很是郁闷，后来终于在log中找到了错误原因: &nbsp;Script result: ERROR_VALIDATE_BAD_SQL_VERSION Error: Script failed (code "ERROR_VALIDATE_BAD_SQL_VERSION") when installing "CentralMgmtStore" on "LyncServer01.mail2any.local". For details, see the following log file: "C:\Users\Administrator.Mail2any\AppData\Local\Temp\Create-CentralMgmtStore-LyncServer01.mail2any.local-[2010_12_22][16_11_55].log" Error: An error occurred: "Microsoft.Rtc.Common.Data.SqlConnectionException" "Cannot open...]]></summary>
    <author>
        <name>pOweRK6</name>
        <uri>http://www.powerk6.org</uri>
    </author>
    
        <category term="Microsoft" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="OCS" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="lync" label="Lync" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="sql" label="SQL" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="topology" label="Topology" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.powerk6.org/">
        <![CDATA[昨天想试试在现有的 OCS 2007 R2 的基础上部署 Lync Server 2010 试试看，装好 Topology Builder 之后，新建了一个拓扑，然后把该填的都填了，发布的时候老是报SQL错，很是郁闷，后来终于在log中找到了错误原因: 
<p style="MARGIN: 0cm 0cm 10pt" class="MsoNormal"><span class="bodytext-8p-black-bold1"><i><span style="LINE-HEIGHT: 115%; FONT-FAMILY: 'Calibri','sans-serif'; FONT-SIZE: 10pt"><strong></strong></span></i></span>&nbsp;<span class="bodytext-8p-black-bold1"><i><span style="LINE-HEIGHT: 115%; FONT-FAMILY: 'Calibri','sans-serif'; FONT-SIZE: 10pt"><strong>Script result: </strong></span></i></span><i><span style="LINE-HEIGHT: 115%; COLOR: black; FONT-SIZE: 10pt"><span style="FONT-FAMILY: Calibri">ERROR_VALIDATE_BAD_SQL_VERSION<o:p></o:p></span></span></i></p>
<p style="MARGIN: 0cm 0cm 10pt" class="MsoNormal"><span class="alert-8p-red-bold1"><i><span style="LINE-HEIGHT: 115%; FONT-FAMILY: 'Calibri','sans-serif'; COLOR: rgb(255,51,0); FONT-SIZE: 10pt"><strong>Error: </strong></span></i></span><span class="alert-8p-red1"><i><span style="LINE-HEIGHT: 115%; FONT-FAMILY: 'Calibri','sans-serif'; FONT-SIZE: 10pt"><span style="COLOR: rgb(255,51,0)">Script failed (code "ERROR_VALIDATE_BAD_SQL_VERSION") when installing "CentralMgmtStore" on "LyncServer01.mail2any.local". For details, see the following log file: "C:\Users\Administrator.Mail2any\AppData\Local\Temp\Create-CentralMgmtStore-LyncServer01.mail2any.local-[2010_12_22][16_11_55].log"<o:p></o:p></span></span></i></span></p>
<p style="MARGIN: 0cm 0cm 10pt" class="MsoNormal"><span class="alert-8p-red-bold1"><i><span style="LINE-HEIGHT: 115%; FONT-FAMILY: 'Calibri','sans-serif'; COLOR: rgb(255,51,0); FONT-SIZE: 10pt"><strong>Error: </strong></span></i></span><span class="alert-8p-red1"><i><span style="LINE-HEIGHT: 115%; FONT-FAMILY: 'Calibri','sans-serif'; COLOR: rgb(255,51,0); FONT-SIZE: 10pt">An error occurred: "Microsoft.Rtc.Common.Data.SqlConnectionException" "Cannot open database "xds" requested by the login. The login failed.</span></i></span><i><span style="LINE-HEIGHT: 115%; COLOR: rgb(255,51,0); FONT-SIZE: 10pt"><br /><span class="alert-8p-red1"><span style="LINE-HEIGHT: 115%; FONT-FAMILY: 'Calibri','sans-serif'">Login failed for user 'Mail2Any\Administrator'."</span></span></span></i></p>
<p style="MARGIN: 0cm 0cm 10pt" class="MsoNormal"><i><span style="LINE-HEIGHT: 115%; COLOR: rgb(255,51,0); FONT-SIZE: 10pt"><span class="alert-8p-red1"><span style="LINE-HEIGHT: 115%; FONT-FAMILY: 'Calibri','sans-serif'"></span></span></span></i><i><span style="LINE-HEIGHT: 115%; FONT-SIZE: 10pt"><o:p></o:p></span></i>&nbsp;</p>
<p style="MARGIN: 0cm 0cm 10pt" class="MsoNormal"><span>看到这个 Bad Version 版本错误提示，我才想起来原来部署 OCS 2007 R2 的时候，后端数据库用的是 SQL Server 2008，而 Lync Server 2010需要至少 SQL Server 2008 SP1 才行，于是乎打上 SP1 补丁，顺利通过发布。</span><span><span style="FONT-FAMILY: Calibri"><span style="FONT-SIZE: 11pt">SQL Server的版本需求:</span></span></span></p>
<ul>
<li>
<div style="MARGIN: 0cm 0cm 10pt" class="MsoNormal"><span><span style="FONT-FAMILY: Calibri"><span style="FONT-SIZE: 11pt"><font face="Times New Roman">Standard or Enterprise Edition of SQL Server 2005 with Service Pack 3</font></span></span></span></div></li>
<li>
<div style="MARGIN: 0cm 0cm 10pt" class="MsoNormal"><span><span style="FONT-FAMILY: Calibri"><span style="FONT-SIZE: 11pt"><font face="Times New Roman">Standard or Enterprise Edition of SQL Server 2008 with Service Pack 1</font></span></span></span></div></li>
<li>
<div style="MARGIN: 0cm 0cm 10pt" class="MsoNormal"><span><span style="FONT-FAMILY: Calibri"><span style="FONT-SIZE: 11pt"><font face="Times New Roman">Standard or Enterprise Edition of SQL Server 2008 R2<br /></font></span></span></span><span style="FONT-FAMILY: Symbol"><span><span style="FONT: 7pt 'Times New Roman'">&nbsp; </span></span></span></div></li></ul>]]>
        
    </content>
</entry>

<entry>
    <title>使用 URL Rewrite 重定向 Http 请求至 Https</title>
    <link rel="alternate" type="text/html" href="http://www.powerk6.org/2010/10/how-to-use-url-rewrite-to-redirect-http-to-https-on-iis7.html" />
    <id>tag:www.powerk6.org,2010://1.281</id>

    <published>2010-10-21T01:48:24Z</published>
    <updated>2010-10-21T03:11:25Z</updated>

    <summary>公司部署了个新的 IIS 站点，需要强制在 Https 下面访问，但是又不希望关掉80端口的 Http 请求，这样对用户体验来讲不好，最好是能强制所有的 Http 请求都会被重定向到 Https 上面去，显然， IIS 自带的 &quot;HTTP Redirect&quot; 已经不能满足这个需求，我们这里使用 IIS 7.0 下面的重定向扩展 URL Rewrite Module 来做。1. http://www.iis.net/download/URLRewrite 到这里下载，有分 32 和 64 位版本。 2. 安装完后，可以在 IIS 站点管理的根目录下面看到多了个 URL Rewrite。 3. 双击打开，你会看到一个规则配置的页面。 4. 点击 &quot;Add...</summary>
    <author>
        <name>pOweRK6</name>
        <uri>http://www.powerk6.org</uri>
    </author>
    
        <category term="Microsoft" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="Windows" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="https" label="HTTPS" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="iis7" label="IIS 7" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="urlrewrite" label="URL Rewrite" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.powerk6.org/">
        <![CDATA[公司部署了个新的 IIS 站点，需要强制在 Https 下面访问，但是又不希望关掉80端口的 Http 请求，这样对用户体验来讲不好，最好是能强制所有的 Http 请求都会被重定向到 Https 上面去，显然， IIS 自带的 "HTTP Redirect" 已经不能满足这个需求，我们这里使用 IIS 7.0 下面的重定向扩展 URL Rewrite Module 来做。<br /><br />1. <a href="http://www.iis.net/download/URLRewrite">http://www.iis.net/download/URLRewrite</a> 到这里下载，有分 32 和 64 位版本。<br />
<br />
2. 安装完后，可以在 IIS 站点管理的根目录下面看到多了个 URL Rewrite。<br />
<img src="http://www.powerk6.org/upfiles/2010/10/url-rewrite-1.jpg" />
<br />
3. 双击打开，你会看到一个规则配置的页面。<br />
<img src="http://www.powerk6.org/upfiles/2010/10/url-rewrite-2.jpg" />
<br />
4. 点击 "Add Rules" 添加规则，选择默认的"Blank Rule" 作为模板。<br />
<img src="http://www.powerk6.org/upfiles/2010/10/url-rewrite-3.jpg" />
<br />]]>
        <![CDATA[5. 在规则名字这一栏输入 "Redirect to HTTPS"。<br />
<img src="http://www.powerk6.org/upfiles/2010/10/url-rewrite-4.jpg" /><br />
6. 展开 "Match URL" 这个小三角，按如下设定：<br /><strong>Requested URL:</strong> Matches the Pattern<br />
<strong>Using:</strong> Regular Expressions<br />
<strong>Pattern:</strong> (.*)<br />
<img src="http://www.powerk6.org/upfiles/2010/10/url-rewrite-5.jpg" /><br />
7.在"Conditions"这里，点击 "Add..."。<br />
<img src="http://www.powerk6.org/upfiles/2010/10/url-rewrite-6.jpg" /><br />
8. 按以下设定输入：<br /><strong>Condition Input</strong>: {HTTPS}<br />
<strong>Check if input string</strong>: Matches the Pattern<br />
<strong>Pattern</strong>: ^OFF$<br />
<img src="http://www.powerk6.org/upfiles/2010/10/url-rewrite-7.jpg" />
<br />
9. 完成后入下图所示。<br />
<img src="http://www.powerk6.org/upfiles/2010/10/url-rewrite-8.jpg" /><br />
10. 最后一步就是重定向的设置了。&nbsp; <br />
<img src="http://www.powerk6.org/upfiles/2010/10/url-rewrite-9.jpg" />
<strong>Action Type</strong>: Redirect<br />
<strong>Redirect URL</strong>: <a href="https://%7bhttp_host%7d/%7BR:1">https://{HTTP_HOST}/{R:1</a>}<br />
<strong>Redirect Type</strong>: See Other (303)<br /><br />

11. 点击右边的 "Apply" 应用，设置完成。<br />
<img src="http://www.powerk6.org/upfiles/2010/10/url-rewrite-10.jpg" />
<br /><img src="http://www.powerk6.org/upfiles/2010/10/url-rewrite-11.jpg" />
<br />补充： 因为本地的 IIS 还有个 Web Service 需要调用 http://localhost/directory/service.asmx，如上设置后，会被重定向去 http://localhost/directory/service.asmx，而由于SSL证书匹配的关系，这个Web Service调用会出错，所以我后来又再加上了个例外条件，使得本地的 localhost 调用请求不再转向 HTTPS。<br /><br />

12. 在"Conditions"这里，点击 "Add..."。<br />
<br />按以下设定输入，然后点击 Move Up 使其成为第一个条件<br />
<strong>Condition Input</strong>: {HTTPS_HOST}<br />

<strong>Check if input string</strong>: Does Not Matches the Pattern<br />

<strong>Pattern</strong>: ^(localhost)<br /><br />
<img src="http://www.powerk6.org/upfiles/2010/10/url-rewrite-12.jpg" /><br />
<img src="http://www.powerk6.org/upfiles/2010/10/url-rewrite-13.jpg" /><br />
13. 最后设定完成如图。<br /><br />14. 在 web.config 里面你也可以看到最终的设置结果<br /><img src="http://www.powerk6.org/upfiles/2010/10/url-rewrite-14.jpg" /><br />]]>
    </content>
</entry>

<entry>
    <title>How to remember your OC and Outlook password</title>
    <link rel="alternate" type="text/html" href="http://www.powerk6.org/2010/10/how-to-remember-your-oc-and-outlook-password.html" />
    <id>tag:www.powerk6.org,2010://1.280</id>

    <published>2010-10-13T07:12:20Z</published>
    <updated>2011-09-01T15:55:59Z</updated>

    <summary>How to make your computer remember your Microsoft Communicator 2007 R2 and Outlook 2007 password (如何让你的电脑在非域环境中记住 OC 2007 R2 和 Outlook 的密码)我们知道，在域的环境中，使用 OC 和 Outlook 都可以使用 Windows 的集成验证来完成用户验证过程，也能很方便的记住密码自动登录，但是如果你的电脑没有在域环境中或者工作站所在的域与 Exchange/OCS 所在的域没有联系呢？ 这个时候，你甚至连&quot;保存密码&quot;的复选框都看不到，怎么办？...</summary>
    <author>
        <name>pOweRK6</name>
        <uri>http://www.powerk6.org</uri>
    </author>
    
        <category term="Exchange" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="Microsoft" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="OCS" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="communicator" label="Communicator" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="exchange" label="Exchange" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="outlook" label="Outlook" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.powerk6.org/">
        <![CDATA[How to make your computer remember your Microsoft Communicator 2007 R2 and Outlook 2007 password (如何让你的电脑在非域环境中记住 OC 2007 R2 和 Outlook 的密码)<br /><br />我们知道，在域的环境中，使用 OC 和 Outlook 都可以使用 Windows 的集成验证来完成用户验证过程，也能很方便的记住密码自动登录，但是如果你的电脑没有在域环境中或者工作站所在的域与 Exchange/OCS 所在的域没有联系呢？ 这个时候，你甚至连"保存密码"的复选框都看不到，怎么办？<br />]]>
        <![CDATA[中文版本：<br /><b>A.&nbsp;&nbsp;&nbsp; Outlook 2007</b> (同样适用于 Outlook 2003/2010)<br />1.&nbsp;&nbsp;&nbsp; 退出Outlook（如果在运行的话）.<div><br />2.&nbsp;&nbsp;&nbsp; 控制面板 -&gt; 邮件 -&gt; 邮件账户..., 点击 "更改...".&nbsp;</div><div><br /></div><div><img src="http://www.powerk6.org/upfiles/2010/10/ol_step_1.jpg" />
<br /><br /></div><div>3.&nbsp;&nbsp;&nbsp; 在 "更改电子邮件账户" 对话框, 点击 "更多设置"。</div><div><br />
<img src="http://www.powerk6.org/upfiles/2010/10/ol_step_2.jpg" /></div><div><br /></div><div>
4.&nbsp;&nbsp;&nbsp; 转到 "连接" 标签卡, 点击 "Exchange 代理设置"。</div><div><br />
<img src="http://www.powerk6.org/upfiles/2010/10/ol_step_3.jpg" />&nbsp;</div><div><br /></div><div>5.&nbsp;&nbsp;&nbsp; 在代理认证这里，将认证方式从基本认证改为NTLM认证。</div><div><br />
<img src="http://www.powerk6.org/upfiles/2010/10/ol_step_4.jpg" />&nbsp;</div><div><br /></div><div>6.&nbsp;&nbsp;&nbsp; 点击 "OK" 两次确认。</div><div><br />

7.&nbsp;&nbsp;&nbsp; 接着点击下一步和完成按钮。</div><div><br />

8.&nbsp;&nbsp;&nbsp; 重新打开Outlook, 你就能看到那 "记住密码" 选项又出来了，输入你的邮件地址和密码, 选中记住密码功能。&nbsp;</div><div><br />

9.&nbsp;&nbsp;&nbsp; 这一步是关键！点击开始-&gt; 运行, 输入 "control Keymgr.dll"</div><div><br /></div><div>&nbsp; 
<img src="http://www.powerk6.org/upfiles/2010/10/ol_step_5.jpg" /></div><div><br /></div><div>

10.&nbsp;&nbsp;&nbsp; 确认你选择的是 Exchange 邮箱角色服务器地址，比如 EXMBX01.company.local ， 然后点击 "属性"</div><div><br />
<img src="http://www.powerk6.org/upfiles/2010/10/ol_step_6.jpg" />
<img src="http://www.powerk6.org/upfiles/2010/10/ol_step_7.jpg" /></div><div><br /></div><div>
11.&nbsp;&nbsp;&nbsp; 将服务器属性从 "EXMBX01.company.local" 改成 "*.company.local", 点击 OK 确定.</div><div><br />
<img src="http://www.powerk6.org/upfiles/2010/10/ol_step_8.jpg" />
&nbsp;</div><div><br /></div><div><br />

B.&nbsp;&nbsp;&nbsp; Communicator<br />
1. 打开注册表，找到 HKEY_CURRENT_USER\Software\Microsoft\Communicator，新建一个 DWORD记录，名字为 SavePassword ， 修改其值为 1 。当然，你也可以去到微软站点下载OCS的组策略模板，导入AD中，实现批量修改。
2..&nbsp;&nbsp;&nbsp; 关闭并完全退出 communicator ， 然后重新打开, 你会看到 "保存我的密码", 选中后点击登入。</div><div><br />
<img src="http://www.powerk6.org/upfiles/2010/10/ol_step_9.jpg" />
&nbsp;</div><div><br />

注意: 如果你以后修改了你的 Exchange 或者 OC 的密码，要记得再重复第10步 (Step A.10)。<br /><br /><br /></div><div>English Version （For Screenshots, please refer to Chinese Verion Below）<br /><b>A.&nbsp;&nbsp;&nbsp; Outlook 2007</b> (Also applicable to Outlook 2003/2010)<br />1.&nbsp;&nbsp;&nbsp; Exit your Outlook if running.<br /><br />2.&nbsp;&nbsp;&nbsp; Go to Control Panel -&gt; Mail -&gt; Email Accounts..., click "Change...".<br /><br />
3.&nbsp;&nbsp;&nbsp; &nbsp;On "Change Email Account" dialogue box, click "More Settings".<br />
&nbsp;<br />
4.&nbsp;&nbsp;&nbsp; Next to "Connection" tab, click "Exchange Proxy Settings".<br />&nbsp;
<br />
5.&nbsp;&nbsp;&nbsp; Change the Proxy authentication settings is from Basic Authentication to NTLM Authentication.<br /><br />6.&nbsp;&nbsp;&nbsp; Click "OK" twice to confirm.<br />
<br />7.&nbsp;&nbsp;&nbsp; Then click Next and Finish button to exit Mail Configuration.<br />
<br />8.&nbsp;&nbsp;&nbsp; Now open Outlook again, you will see the missing Remember my 
Password option, type your email address and password, then select it 
and click OK to continue. <br />
<br />9.&nbsp;&nbsp;&nbsp; Now is the real trick. Click Start-&gt; Run, type "<b>control 
Keymgr.dll</b>" and enter, you will see the "Stored User Names and 
Passwords" page.<br />
&nbsp;<br />
10.&nbsp;&nbsp;&nbsp; Make sure you select the EXMBX01.domain.local item, then click "Properties"<br />
&nbsp; <br />
11.&nbsp;&nbsp;&nbsp; Change the Server item's value from "EXMBX01.domain.local" to "*.domain.local", click OK and Close to finish.<br />
&nbsp;<br />
<b>B.&nbsp;&nbsp;&nbsp; Communicator</b><br />
1.&nbsp;&nbsp;&nbsp; Close and exit your communicator if running, and reopen it, you 
will see there is a option called "Save my password", check it and click
 Sign In.<br />
&nbsp;<br />
<b>Note: If you change your email/OC password someday, do remember also change the saved password (Step A.10) on your computer.</b><br />
</div>]]>
    </content>
</entry>

<entry>
    <title> 微软 CRM 2011 Beta 快速安装图解</title>
    <link rel="alternate" type="text/html" href="http://www.powerk6.org/2010/09/ms-crm-2011-beta-installation.html" />
    <id>tag:www.powerk6.org,2010://1.278</id>

    <published>2010-09-19T07:31:19Z</published>
    <updated>2010-09-21T07:55:21Z</updated>

    <summary><![CDATA[微软在9月17日在网站上放出了 CRM 2011 （也就是CRM5.0）的 beta 版本，我就先来个简单的快读安装图解，一睹为快，下个月会写点新版 CRM 的使用感受。 下载： Microsoft Dynamics CRM 2011 Beta Microsoft Dynamics CRM 2011 Software Development Kit (SDK)Microsoft Dynamics CRM 2011 Beta Implementation Guide &nbsp; 界面一览...]]></summary>
    <author>
        <name>pOweRK6</name>
        <uri>http://www.powerk6.org</uri>
    </author>
    
        <category term="CRM" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="Microsoft" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="beta" label="Beta" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="crm" label="CRM" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.powerk6.org/">
        <![CDATA[<p>微软在9月17日在网站上放出了 CRM 2011 （也就是CRM5.0）的 beta 版本，我就先来个简单的快读安装图解，一睹为快，下个月会写点新版 CRM 的使用感受。</p>
<p>下载：</p>
<p><a href="http://www.microsoft.com/downloads/details.aspx?FamilyID=0c7dcc45-9d41-4e2e-8126-895517b4274c&amp;displayLang=zh-cn">Microsoft Dynamics CRM 2011 Beta</a></p>
<p><a href="http://www.microsoft.com/downloads/info.aspx?na=40&amp;p=3&amp;SrcDisplayLang=zh-cn&amp;SrcCategoryId=&amp;SrcFamilyId=0c7dcc45-9d41-4e2e-8126-895517b4274c&amp;u=http%3a%2f%2fgo.microsoft.com%2ffwlink%2f%3fLinkID%3d200082">Microsoft Dynamics CRM 2011 Software Development Kit (SDK)</a><br /><br /><a href="http://www.microsoft.com/downloads/info.aspx?na=40&amp;p=2&amp;SrcDisplayLang=zh-cn&amp;SrcCategoryId=&amp;SrcFamilyId=0c7dcc45-9d41-4e2e-8126-895517b4274c&amp;u=http%3a%2f%2fgo.microsoft.com%2ffwlink%2f%3fLinkID%3d200050">Microsoft Dynamics CRM 2011 Beta Implementation Guide</a></p>
<p>&nbsp;</p>
<p>界面一览</p><img src="http://www.powerk6.org/upfiles/2010/09/CRM2011_20.jpg" /> 

]]>
        <![CDATA[<strong>1. 自动更新安装程序；</strong>
<img src="http://www.powerk6.org/upfiles/2010/09/CRM2011_0.jpg" /> 

<strong>2. 输入安装 Key，在 ReadMe 文件里面有， beta 版本试用有效期是 270 天；</strong>
<img src="http://www.powerk6.org/upfiles/2010/09/CRM2011_1.jpg" /> 

<strong>3. 新的组件需求；</strong>
<img src="http://www.powerk6.org/upfiles/2010/09/CRM2011_2.jpg" /> 
<img src="http://www.powerk6.org/upfiles/2010/09/CRM2011_3.jpg" /> 
<img src="http://www.powerk6.org/upfiles/2010/09/CRM2011_4.jpg" /> 

<strong>4. 选择目录，继续；</strong>
<img src="http://www.powerk6.org/upfiles/2010/09/CRM2011_5.jpg" /> 

<strong>5. 新的角色：前端、后端、部署管理；</strong>
<img src="http://www.powerk6.org/upfiles/2010/09/CRM2011_6.jpg" /> 

<strong>6. 和 4.0 一样的选择 AD 用户和组创建位置；</strong>
<img src="http://www.powerk6.org/upfiles/2010/09/CRM2011_7.jpg" /> 
<img src="http://www.powerk6.org/upfiles/2010/09/CRM2011_8.jpg" /> 
<img src="http://www.powerk6.org/upfiles/2010/09/CRM2011_9.jpg" /> 
<img src="http://www.powerk6.org/upfiles/2010/09/CRM2011_10.jpg" /> 
<img src="http://www.powerk6.org/upfiles/2010/09/CRM2011_11.jpg" /> 

<strong>7. 创建一个 CRM 组织；</strong>
<img src="http://www.powerk6.org/upfiles/2010/09/CRM2011_12.jpg" /> 

<strong>8. 选择报表服务器；</strong>
<img src="http://www.powerk6.org/upfiles/2010/09/CRM2011_13.jpg" /> 
<img src="http://www.powerk6.org/upfiles/2010/09/CRM2011_14.jpg" /> 
<img src="http://www.powerk6.org/upfiles/2010/09/CRM2011_15.jpg" /> 

<strong>9. 安装前需求全部满足，开始安装；</strong>
<img src="http://www.powerk6.org/upfiles/2010/09/CRM2011_16.jpg" /> 
<img src="http://www.powerk6.org/upfiles/2010/09/CRM2011_17.jpg" /> 
<img src="http://www.powerk6.org/upfiles/2010/09/CRM2011_18.jpg" /> 

<strong>10. 如果分开部署，这里要安装 Reporting Extensions for SSRS Setup；</strong>
<img src="http://www.powerk6.org/upfiles/2010/09/CRM2011_19.jpg" /> 


















]]>
    </content>
</entry>

<entry>
    <title>升级到 Exchange 2010 SP1 后出现的2个小问题</title>
    <link rel="alternate" type="text/html" href="http://www.powerk6.org/2010/09/upgrade-to-exchange-2010-sp1-issues.html" />
    <id>tag:www.powerk6.org,2010://1.277</id>

    <published>2010-09-12T03:46:03Z</published>
    <updated>2010-09-21T06:14:23Z</updated>

    <summary><![CDATA[今天有空把所有的 Exchange 服务器从 2010 RTM 升级到了 2010 SP1 了， 升级完了后发现了2个小问题： OWA打开正常，但是点到 ECP 的时候报 403 访问拒绝错误 某台 Exchange&nbsp;打开 EMS 时报错如下： [server.mydomain.local] Connecting to remote server failed with the following error message : The client cannot connect to the destination specified in...]]></summary>
    <author>
        <name>pOweRK6</name>
        <uri>http://www.powerk6.org</uri>
    </author>
    
        <category term="Exchange" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="Microsoft" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="ecp" label="ECP" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="ems" label="EMS" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="exchange2010sp1" label="Exchange 2010 SP1" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="winrm" label="WinRM" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.powerk6.org/">
        <![CDATA[<p>今天有空把所有的 Exchange 服务器从 2010 RTM 升级到了 2010 SP1 了， 升级完了后发现了2个小问题：</p>
<ol>
<li>OWA打开正常，但是点到 ECP 的时候报 403 访问拒绝错误</li>
<li>某台 Exchange&nbsp;打开 EMS 时报错如下：</li></ol>
<blockquote dir="ltr" style="MARGIN-RIGHT: 0px">
<p>[server.mydomain.local] Connecting to remote server failed with the following error message : The client cannot connect to the destination specified in the request. Verify that the service on the destination is running and is accepting requests. Consult the logs and documentation for the WS-Management service running on the destination, most commonly IIS or WinRM. If the destination is the WinRM service, run the following command on the destination to analyze and configure the WinRM service: "winrm quickconfig". For more information, see the about_Remote_Troubleshooting Help topic.<br />+ CategoryInfo : OpenError: (System.Manageme....RemoteRunspace:RemoteRunspace) [], PSRemotingTransportException<br />+ FullyQualifiedErrorId : PSSessionOpenFailed</p></blockquote>
<p>&nbsp;</p>
<p>1. 这个错误在经过仔细排查后发现， 取消在IIS虚拟目录里面ecp的 "Require SSL" 就可以了，原来是之前为了做 SSL Offloading，把这个SSL的要求取消了，但是 Exchange 2010 SP1的安装程序在升级的时候又给加上去了，所以就报错了。</p>
<p>2..这个错误在网上查了好久，都没发现有用的答案，包括重装 WinRM IIS 扩展，重新配置 PowerShell 虚拟目录，运行 WinRm QuickConfig 等等，都没有用，最后发现问题还是出在IIS上面，Default Web Site 一开始给禁用了，而且默认的端口也从80改到了8080，EMS在打开的时候需要访问 Default Web Site 下面 PowerShell 的虚拟目录，找不到，报错，改回去80，错误解决。</p>
<p>&nbsp;</p>]]>
        
    </content>
</entry>

<entry>
    <title>小心安装 OCS 2007 R2 Cumulative Update 6 (CU6) 和 .NET 4.0</title>
    <link rel="alternate" type="text/html" href="http://www.powerk6.org/2010/08/problem-installed-ocs2007-r2-cu6-dotnet-40.html" />
    <id>tag:www.powerk6.org,2010://1.276</id>

    <published>2010-08-15T13:23:06Z</published>
    <updated>2010-08-25T13:51:15Z</updated>

    <summary>今天发现有新的 OCS 2007 R2 的更新，于是就跑去把几台 OCS 2007 R2 的服务器都给升级了，为了偷懒，用了那个一体化更新包ServerUpdateInstaller.exe，这个东西好是好，就是下载后没有点版本信息可以从文件名看出来，每次都一样，我只好自己在后面加个尾巴标注。更新完了重启，发现 Front-End 服务死活都起不来，检查系统日志，发现Event ID: 30968 Source: Live Communications User Services Details: The component Live Communications User Services reported a critical error: code C3EE78F8 (Enterprise Edition Server successfully registered with the back-end, but...</summary>
    <author>
        <name>pOweRK6</name>
        <uri>http://www.powerk6.org</uri>
    </author>
    
        <category term="Microsoft" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="OCS" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="net40" label=".NET 4.0" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="cumulativeupdate" label="Cumulative Update" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="ocs" label="OCS" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.powerk6.org/">
        <![CDATA[今天发现有新的 OCS 2007 R2 的更新，于是就跑去把几台 OCS 2007 R2 的服务器都给升级了，为了偷懒，用了那个一体化更新包ServerUpdateInstaller.exe，这个东西好是好，就是下载后没有点版本信息可以从文件名看出来，每次都一样，我只好自己在后面加个尾巴标注。更新完了重启，发现 Front-End 服务死活都起不来，检查系统日志，发现<br /><b><br />Event ID</b>: 30968<br />
<b>Source</b>: Live Communications User Services<br />
<b>Details</b>: The component Live Communications User Services
reported a critical error: code C3EE78F8 (Enterprise Edition Server
successfully registered with the back-end, but a stored procedure
version mismatch was detected. The service will not start until this
problem is resolved. Cause: The database schema and the Enterprise
Edition Server were updated by different installation packages.
Resolution: Ensure both the Enterprise Edition Server and back-end were
installed or modified by the same installation package. The service has
to stop.<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 最后搞了半天才发现是要先升级数据库才行，OCS2009-DBUpgrade.msi 否则会因为前端服务的版本和后端数据库版本不匹配而导致服务启动失败。唉，这种事情也不早说出来，ServerUpdateInstaller.exe 没法升级数据库，只好手动做咯 <br />msiexec /i OCS2009-DBUpdate.msi POOLNAME=xxx<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 打完了数据库补丁后，启动 Front-End 服务正常。<br /><br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 另外还有个问题是关于.NET 4.0 Framework 的，如果你是新装的服务器，在安装OCS之前装了 .NET 4，你会发现安装程序老是会说 .NET 3.5x 没有安装，即便你已经装过，怎么办呢？只有先行卸载.NET 4.0 Framework, 安装 OCS，再安装 .NET 4.0 才行。<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 我一向的原则都是新东西等等再装，因为说不准更新完后会出什么问题，先等等，大家都说没问题了，再装，这样安全。<br />]]>
        
    </content>
</entry>

<entry>
    <title>解决 SQL 2008 Reporting Service 的 TeraData 扩展错误</title>
    <link rel="alternate" type="text/html" href="http://www.powerk6.org/2010/07/how-to-fix-sql2008-ssrs-teradata-extension-load-error.html" />
    <id>tag:www.powerk6.org,2010://1.275</id>

    <published>2010-07-02T03:17:09Z</published>
    <updated>2010-07-02T03:44:45Z</updated>

    <summary><![CDATA[新装的一台 SQL Server 2008 SP1， 上面有跑数据库引擎和报表服务，新装后不久在事件管理器中频繁出现以下错误：Log Name:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ApplicationSource:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Report Server (MSSQLSERVER)Date:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 7/2/2010 12:48:21 AMEvent ID:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 108Task Category: ExtensionLevel:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ErrorKeywords:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ClassicUser:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; N/AComputer:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; M2AHKCRMWEB01.mail2any.localDescription:Report Server (MSSQLSERVER) cannot load the TERADATA extension.发生这个的原因是在2008的报表服务中,默认开启了 TeraData 的扩展，而2008的安装文件是不包含这个扩展的文件的，所以就会找不到扩展所需要的文件。解决方案：大多数情况下应该是没有用到 TeraData 的，所以可以打开 Reporting Service&nbsp; 所在的目录下的 RSReportServer.config 文件，注释掉 TeraData 相关部分即可。比如...]]></summary>
    <author>
        <name>pOweRK6</name>
        <uri>http://www.powerk6.org</uri>
    </author>
    
        <category term="Microsoft" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="SQL" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="reportingservice" label="Reporting Service" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="reportserver" label="ReportServer" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="sqlserver" label="SQL Server" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="teradata" label="TeraData" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.powerk6.org/">
        <![CDATA[新装的一台 SQL Server 2008 SP1， 上面有跑数据库引擎和报表服务，新装后不久在事件管理器中频繁出现以下错误：<br /><blockquote>Log Name:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Application<br />Source:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Report Server (MSSQLSERVER)<br />Date:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 7/2/2010 12:48:21 AM<br />Event ID:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 108<br />Task Category: Extension<br />Level:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Error<br />Keywords:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Classic<br />User:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; N/A<br />Computer:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; M2AHKCRMWEB01.mail2any.local<br />Description:<br />Report Server (MSSQLSERVER) cannot load the TERADATA extension.<br /></blockquote>发生这个的原因是在2008的报表服务中,默认开启了 TeraData 的扩展，而2008的安装文件是不包含这个扩展的文件的，所以就会找不到扩展所需要的文件。<br />解决方案：<br />大多数情况下应该是没有用到 TeraData 的，所以可以打开 Reporting Service&nbsp; 所在的目录下的 RSReportServer.config 文件，注释掉 TeraData 相关部分即可。<br />比如 C:\Program Files\Microsoft SQL Server\MSRS10.MSSQLSERVER\Reporting Services\ReportServer\RSReportServer.config 文件<br />&nbsp;&lt;!-- &lt;Extension Name="TERADATA" Type="Microsoft.ReportingServices.DataExtensions.TeradataConnectionWrapper,Microsoft.ReportingServices.DataExtensions" /&gt; --&gt;<br /><br />&lt;!-- &lt;Extension Name="TERADATA" Type="Microsoft.ReportingServices.SemanticQueryEngine.Sql.Teradata.TdSqlSQCommand,Microsoft.ReportingServices.SemanticQueryEngine"&gt; <br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;Configuration&gt;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;EnableMathOpCasting&gt;True&lt;/EnableMathOpCasting&gt;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;ReplaceFunctionName&gt;oREPLACE&lt;/ReplaceFunctionName&gt;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/Configuration&gt;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/Extension&gt; --&gt;<br />第二：如果有用到 TeraData，那就去其网站下载 TeraData .Net Data Provider，注意要安装版本12以上的，比如 http://www.teradata.com/DownloadCenter/Topic9541-152-1.aspx<br /><br /><br /><br /> ]]>
        
    </content>
</entry>

<entry>
    <title>配置OCS XMPP网关以支持OC和Jabber XCP联系人的通讯</title>
    <link rel="alternate" type="text/html" href="http://www.powerk6.org/2010/06/how-to-configure-ocsr2-xmpp-to-jabber-xcp.html" />
    <id>tag:www.powerk6.org,2010://1.272</id>

    <published>2010-06-23T08:15:18Z</published>
    <updated>2010-06-23T08:49:40Z</updated>

    <summary>占个位...</summary>
    <author>
        <name>pOweRK6</name>
        <uri>http://www.powerk6.org</uri>
    </author>
    
        <category term="Microsoft" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="OCS" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="gateway" label="GateWay" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="jabber" label="Jabber" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="ocsr2" label="OCS R2" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="xmpp" label="XMPP" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.powerk6.org/">
        <![CDATA[占个位<br />]]>
        <![CDATA[<br />]]>
    </content>
</entry>

<entry>
    <title>配置OCS XMPP网关以支持OC和Gmail联系人的通讯</title>
    <link rel="alternate" type="text/html" href="http://www.powerk6.org/2010/06/how-to-configure-ocsr2-xmpp-to-gmail.html" />
    <id>tag:www.powerk6.org,2010://1.271</id>

    <published>2010-06-23T08:15:18Z</published>
    <updated>2010-06-25T03:04:02Z</updated>

    <summary><![CDATA[是的，您没有看错，我也没有写错！现在通过安装配置 XMPP 网关，您可以在 Office Communicator 中添加 Gmail （Google Talk）用户作为联系人，查看对方的忙/闲状态，并即时聊天。 微软的OCS团队早在去年就在其团队博客上面发布了配置指南，请移步 http://communicationsserverteam.com/archive/2009/10/01/599.aspx 查看。 另外本文也参考了MVP-&nbsp;Jeff Schertz&nbsp;的博文 http://blogs.pointbridge.com/Blogs/schertz_jeff/Pages/Post.aspx?_ID=91 基本上，您需要在现有运行良好的 OCS 2007 R2环境中添置至少一台 XMPP 网关服务器，通过配置其相关设定，来支持和Gmail用户的连接。 下面我也说说我自己的经验和步骤: 一、拓扑图 我们先来看看微软官方文档中的一幅图： Gmail o Gmail 云部分是由Google提供的XMPP网关服务器，目前有5个不同的Gtalk主机名，其名称和IP如下所示。 xmpp-server.l.google.com,&nbsp; 74.125.45.125 xmpp-server1.l.google.com, 74.125.155.125 xmpp-server2.l.google.com, 74.125.47.125 xmpp-server3.l.google.com, 74.125.45.125 xmpp-server4.l.google.com, 74.125.45.125...]]></summary>
    <author>
        <name>pOweRK6</name>
        <uri>http://www.powerk6.org</uri>
    </author>
    
        <category term="Microsoft" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="OCS" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="gateway" label="GateWay" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="gmail" label="Gmail" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="googletalk" label="Google Talk" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="ocsr2" label="OCS R2" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="xmpp" label="XMPP" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.powerk6.org/">
        <![CDATA[<p>是的，您没有看错，我也没有写错！现在通过安装配置 XMPP 网关，您可以在 Office Communicator 中添加 Gmail （Google Talk）用户作为联系人，查看对方的忙/闲状态，并即时聊天。</p>
<p>微软的OCS团队早在去年就在其团队博客上面发布了配置指南，请移步 <a href="http://communicationsserverteam.com/archive/2009/10/01/599.aspx">http://communicationsserverteam.com/archive/2009/10/01/599.aspx</a> 查看。</p>
<p>另外本文也参考了MVP-&nbsp;<a href="http://blogs.pointbridge.com/Blogs/schertz_jeff" target="">Jeff Schertz</a>&nbsp;的博文</p>
<p><a href="http://blogs.pointbridge.com/Blogs/schertz_jeff/Pages/Post.aspx?_ID=91">http://blogs.pointbridge.com/Blogs/schertz_jeff/Pages/Post.aspx?_ID=91</a></p><span class="pbc-blogs-footer-spacer"></span>
<p>基本上，您需要在现有运行良好的 OCS 2007 R2环境中添置至少一台 XMPP 网关服务器，通过配置其相关设定，来支持和Gmail用户的连接。</p>
<p>下面我也说说我自己的经验和步骤:</p>
<p><b>一、拓扑图</b><b></b></p>
<p>我们先来看看微软官方文档中的一幅图：</p>
<p><img src="http://www.powerk6.org/upfiles/2010/06/Fig_1.jpg" /> </p>
<ul>
<li><strong>Gmail </strong></li></ul>
<blockquote>
<p>o Gmail 云部分是由Google提供的XMPP网关服务器，目前有5个不同的Gtalk主机名，其名称和IP如下所示。</p></blockquote>
<ul>
<li>xmpp-server.l.google.com,&nbsp; 74.125.45.125 </li>
<li>xmpp-server1.l.google.com, 74.125.155.125 </li>
<li>xmpp-server2.l.google.com, 74.125.47.125 </li>
<li>xmpp-server3.l.google.com, 74.125.45.125 </li>
<li>xmpp-server4.l.google.com, 74.125.45.125 </li></ul>]]>
        <![CDATA[<br /><ul>
  <li><strong>OCS边缘服务器</strong></li>
</ul>

<blockquote>
  <p>o 一台运行良好的 OCS 2007 R2 Edge 服务器</p>
</blockquote>

<ul>
  <li><strong>XMPP 网关</strong></li>
</ul>

<blockquote>
  <p>o 一台运行在 Windows Server 上面的 XMPP 网关服务器。 一般来说，单网卡就够了，可以同时处理来自外部（Gmail）和内部（OCS边缘）的请求。如果根据您的实际情况需要配置两片网卡，当然也是支持的。</p>
</blockquote>

<blockquote>
  <p>o 支持网络地址转换 (NAT)，在本例中我们用的就是NAT。如果你有单独的公网地址能直接分配给XMPP的话,当然更好。</p>
</blockquote>

<p>好了，说了这么久，那你也许会问，什么是 XMPP 呢？</p>

<p><b>XMPP </b>是 E<b>x</b>tensible <b>M</b>essaging and <b>P</b>resence Protocol 的简称，是一种以 XML 为基础的分布式和开放式即时通讯协议，听起来很熟悉？没错，其前身就是 <b>Jabber</b>。<b>XMPP </b>经由 IETF 小组制订，后因为被 Google Talk 采用而被大家所接触。</p>

<p>&nbsp; Jabber / XMPP 历史 
  </p><table border="0" cellpadding="0" cellspacing="0"><tbody>
      <tr>
        <td valign="top">
          <p>&nbsp;&nbsp;&nbsp; Jeremie Miller于1998年开始了Jabber这个项目。第一个公开版本于2000年5月发行。这个项目的主要产品是jabberd，XMPP的服务器端软件。它既可以创建私人的XMPP网络，也可以加入全球的公共XMPP网络。 XMPP的关键特色是，分散式的即时通讯系统，以及使用XML流。 
            <br />Jabber Logo 

            <br />&nbsp;&nbsp;&nbsp; 标准化的Jabber已经由IETF XMPP协议（RFC3920）。 

            <br />&nbsp;&nbsp;&nbsp; Jabber是一个开放源码形式组织产生的网络即时通信协议。 XMPP原本是为Instant Messenger而量身定制，但由于XML Stanza本身是XML元素，在基于XML灵活发展的特性下，使得XMPP也可以适用其他方面，已经得到了IETF的批准。 XMPP与IMPP、PRIM、SIP（SIMPLE）合称四大IM协议主流，在此4大协议中，XMPP是最灵活的。 

            <br />&nbsp;&nbsp;&nbsp; 2005年，Google发布了Google Talk，这是一个IP电话及即时通讯的服务，即时通讯功能采用了开放的XMPP。预计这将对XMPP社区起很大的推动作用。初期此服务不支持服务器到服务器的通讯功能，所以未能完全发挥XMPP的分散式特色；虽然任何XMPP客户端都能连接到Google Talk，但是用户想要登录Google Talk，必须拥有Google Talk帐号（即Gmail帐号），而用户也无法与公共XMPP网络的用户通信。自2006年1月17日起，Google宣布支持服务器到服务器的通讯，Google Talk用户可与其他XMPP公共网络的用户聊天。 

            <br />&nbsp;&nbsp;&nbsp; 2007年，年的Jabber软件基金会已经成为XMPP标准基金会。</p>
        </td>
      </tr>
    </tbody></table>


<p>而微软在去年10月发布的 Office Communications Server 2007 R2 XMPP 网关实现了 Office Communications Server 2007 R2 与指定的基于 XMPP 的 IM 和状态提供程序间的 IM 和状态通信，这里指定的 IM 就是指 Jabber XCP 和 Google Talk。本文先讨论和 Gmail 通讯的部分， Jabber XCP 放到下篇中再讲。</p>

<p><b>二、</b><b>XMPP </b><b>网关服务器安装</b><b></b></p>

<p>系统需求和 OCS Edge 服务器类似，只是说 XMPP 不能和 Edge 安装在一起。</p>

<p>软件需求： 
  </p><table border="1" cellpadding="0" cellspacing="0"><tbody>
      <tr>
        <td valign="top" width="242">
          <p>.NET Framework</p>
        </td>

        <td valign="top" width="254">
          <p>3.5</p>
        </td>
      </tr>

      <tr>
        <td valign="top" width="242">
          <p>操作系统</p>
        </td>

        <td valign="top" width="254">
          <p>Windows Server 2003 SP2 64位标准版/企业版</p>

          <p>Windows Server 2008 64位标准版/企业版</p>

          <p>Windows Server 2008 R2 标准版/企业版*</p>
        </td>
      </tr>

      <tr>
        <td valign="top" width="242">
          <p>MMC控制台</p>
        </td>

        <td valign="top" width="254">
          <p>3.0 </p>
        </td>
      </tr>

      <tr>
        <td valign="top" width="242">
          <p>Microsoft Visual C ++® 2005 Redistributable or Visual C++ 2008 Redistributable</p>
        </td>

        <td valign="top" width="254">&nbsp;</td>
      </tr>

      <tr>
        <td valign="top" width="242">
          <p>Unified Communications Managed API (UCMA)</p>
        </td>

        <td valign="top" width="254">
          <p>安装补丁<b><font color="#ff0000">KB968802</font></b></p>
        </td>
      </tr>
    </tbody></table>


<p>* 微软OCS团队的博文上面说 Windows 2008 R2 暂不支持，但是我测试了，<strong><font color="#ff0000">2008 R2</font></strong>是支持的</p>

<p>支持的服务端</p>

<p>· Microsoft Office Communications Server 2007 R2</p>

<p>· Microsoft Office Communications Server 2007</p>

<p>· Jabber XCP Server version 5.4 </p>

<p>· Google Talk </p>

<p>支持的客户端</p>

<p>· Microsoft Office Communicator 2007 R2</p>

<p>· Microsoft Office Communicator 2007</p>

<p>· Microsoft Office Communicator 2005</p>

<p>· Jabber MomentIM Client version 5.2.1</p>

<p>· Google Talk</p>

<p>下载地址：</p>

<p>&nbsp;&nbsp;&nbsp; 1. Microsoft Office Communications Server 2007 R2 XMPP Gateway</p>

<p><a href="http://www.microsoft.com/downloads/details.aspx?displaylang=zh-cn&amp;FamilyID=aa560bfe-9960-473a-bfb8-53bff678cec4">http://www.microsoft.com/downloads/details.aspx?displaylang=zh-cn&amp;FamilyID=aa560bfe-9960-473a-bfb8-53bff678cec4</a></p>

<p>&nbsp;&nbsp;&nbsp; 2. Hotfix</p>

<p><a href="http://www.microsoft.com/downloads/details.aspx?familyid=80B4E42D-6548-46F4-87B1-7FA0FAF80B82&amp;displaylang=en">http://www.microsoft.com/downloads/details.aspx?familyid=80B4E42D-6548-46F4-87B1-7FA0FAF80B82&amp;displaylang=en</a></p>

<p>安装过程，典型的 Next to Next，不过这还只是解压：</p>

<p><img src="http://www.powerk6.org/upfiles/2010/06/Fig_2.jpg" /> </p>

<p><img src="http://www.powerk6.org/upfiles/2010/06/Fig_3.jpg" /> </p>

<p><img src="http://www.powerk6.org/upfiles/2010/06/Fig_4.jpg" /> </p>

<p><img src="http://www.powerk6.org/upfiles/2010/06/Fig_5.jpg" /> </p>

<p>这里安装程序会把安装文件解压至 C:\Program Files\Microsoft Office Communications Server 2007 R2\XMPP Gateway Installer 目录，运行 setup.exe</p>

<p><img src="http://www.powerk6.org/upfiles/2010/06/Fig_6.jpg" /> </p>

<p>点 Install 进行安装，完毕后我们开始配置。</p>

<p><b>需要注意的是</b><b>,</b><b>一开始你会看到</b><b> Install Files for XMPP Gateway</b><b>这一步是正常的</b><b>,</b><b>但是当你退出后下次再进入该页面时，你也许会看到如下提示，尤其是在</b><b> Windows 2008 R2</b><b>中安装时，那么你还需要安装这个更新</b><b> </b><b>（包含在</b><b> KB968802</b><b>中）：</b><b></b></p>

<p><b>http://download.microsoft.com/download/D/9/6/D967F77F-D0BD-43FB-987B-6FBF7C82251B/UcmaRedist.msp</b></p>

<p>&nbsp;<img src="http://www.powerk6.org/upfiles/2010/06/Fig_7.jpg" /> </p>

<p><b></b><b>三、</b><b>XMPP </b><b>网关配置</b><b></b></p>

<p><b>A. </b><b>要使</b><b> XMPP </b><b>网关能正常和</b><b>Gtalk</b><b>通讯，得满足下面四个条件：</b><b></b></p>

<p>1. 你的环境中的 OCS 2007 R2 运行良好。</p>

<p>2. 你的 OCS 有安装边缘 Edge 角色。</p>

<p>3. 一张用来和内部边缘服务器通讯的证书，私有或者商业的都行（和Gmail的通信，私有就够了）。</p>

<p>4. 需要在你的公网域名下面创建一条 A 记录 和 SRV 记录。</p>

<p>接下来我们再来详细看看 Gmail 和 OCS 的通讯过程</p>

<p><img src="http://www.powerk6.org/upfiles/2010/06/Fig_8.jpg" /> </p>

<p>看看一个 Gtalk 用户如何发送一个即时消息到 contoso.com 这个域中的OCS 用户: </p>

<p>1. GoogleTalk 服务器场中的任意一个 XMPP 服务器向 DNS 请求查询 contoso.com 的 XMPP 服务记录 <b><i>_xmpp-server._tcp.contoso.com</i></b><i>。</i> 这条记录应该指向 contoso.com 组织中 XMPP 网关服务器的公网 A 记录的FQDN地址，A记录的名字任意取，比如 <b><i>xmpp.contoso.com</i></b><i>。</i></p>

<p>2. 得到A记录的地址后，GoogleTalk 服务器会使用标准 TCP 连接去和 <b><i>xmpp.contoso.com</i></b> 的<b>5269 </b>端口发送请求。这个过程是非加密的，所以在这里我们并不需要证书。</p>

<p>3. 在 contoso 组织的防火墙接到 Gtalk 的请求后，会将其路由给 XMPP 网关的，当然，在这之前，contoso 的管理员需要把 TCP <b>5269</b> 端口映射给 <b>XMPP</b>。在上面的图例中，XMPP 网关的内部接口地址是 10.11.12.40。 这一步也是非加密的。</p>

<p>4. 当 XMPP 网关接到请求后，它会查看自己的 SIP 配置来确定下一跳怎么走，那么在我们的例子中，这个下一跳就是 OCS 的边缘访问服务器了 (<i>sip.contoso.com</i>)。要注意的是，这里是使用的 Edge 的外部FQDN地址，所以当你的 XMPP 网关和 Edge 在同一个防火墙后面时，也许 XMPP 会得到 Edge 的公网地址，从而连不到 Edge（除非在防火墙上开启了 DNS 别名- DNS Alias or DNS Doctor）。所以这时你需要在 XMPP 网关的本地 Hosts 文件中添加 Edge 的外部接口的内网地址 (10.11.12.33)。多啰嗦一句，在 Edge 的经典配置中，外部接口指的是 Edge 用来监听外部 SIP 通讯和联盟的那张网卡，不是用来和 OCS Pool 通信的那个内部接口。</p>

<p>5. 在与边缘访问的 Edge 服务器的联盟监听端口 <b>5061 </b>建立连接后，XMPP 网关需要一张证书来做 MTLS 的加密通讯。 同样的，XMPP 必须要连接到 Edge 的外部接口上的联盟监听端口。很多朋友在此碰到的问题大多是把 XMPP 网关去连 Edge 的内部接口地址。到这一步，Gtalk的消息就发到了OCS用户那里。</p>

<p>6. OCS 用户回消息给 Gtalk 用户过程 - Edge 服务器收到来自 OCS 前端服务器的请求后，会将 gmail.com 当做一个联盟的域来处理，就和OCS连接 Yahoo/MSN 等一样，通讯请求将会把去到 gmail.com 的通讯交给 Gmail 的联盟服务器 - XMPP 网关去处理，在上面的图例中就是 <b><i>xmpp.jds.local</i> </b></p>

<p>这里有几个重点要注意下:</p>

<p>· 第一，在 XMPP 网关上的证书一定要安装配置好。</p>

<p>o 该证书只是用在 XMPP 和 Edge 服务器的内部通信中间，并不用来和 Google Talk 服务器通信，所以我们可以使用自建 CA 来颁发证书。证书的SN名称应该和 XMPP 网关的内部 FQDN 名称一致，另外，自建 CA 的根证书链应该要导入到 XMPP 网关的计算机账户下受信任的根证书颁发机构中。</p>

<p>o 证书的申请，你可以通过边缘服务器 Edge 上面的证书向导来做（因为 XMPP 上面没有这个向导），或者使用 lcscmd.exe。注意的是，该证书的导出和导入必须要包含私钥（Private Key）。</p>

<p>· 第二， 证书的必须颁发给 XMPP 服务器的 FQDN 名称。</p>

<p>o 因为 XMPP 网关服务器和 Edge 一样，没有加入域，工作组环境，所以我们需要添加相应的 DNS 后缀，比如 <b>jds.local</b>。</p>

<p>o XMPP 网关服务器的 FQDN， 证书的 CN (或者 SAN 记录) 以及在 Edge 服务器中的 Gmail 联盟服务器的允许列表中，设定的都应该是<b>真实的</b><b> FQDN </b><b>名称</b>，并且要保持<b>一致</b>。</p>

<p>· 最后, 防火墙规则的设定: </p>

<p>o XMPP 网关的 TCP <b>5061</b>，需要和 Edge 的 TCP <b>5061</b> 端口进行双向通信</p>

<p>o XMPP 网关的 TCP <b>5269</b>，需要接受来自外部的 Google Talk 的请求</p>

<p><b>B.&nbsp; DNS </b><b>记录的创建</b><b></b></p>

<p>· 创建 A 记录：<b>xmpp.contoso.com</b> - 12.34.56.78</p>

<p>· 创建 SRV 记录：<b><i>_xmpp-server._tcp.contoso.com</i></b> - <b>xmpp.contoso.com</b><b>，</b><b> Port 5269</b></p>

<p>参照微软的图</p>

<p><img src="http://www.powerk6.org/upfiles/2010/06/Fig_9.jpg" /> </p>

<p><b>C.</b><b>说了很多，下面开始配置</b><b> XMPP :</b></p>

<p>· 修改 <b>TGWConsoleGUI.dll.config</b> 文件</p>

<p>默认位置在 <b>C:\Program Files\Microsoft Office Communications Server 2007 R2\XMPP Gateway</b> 下面，这里需要改到的部分是 <i>SipIP</i> 和 <i>XmppIP </i>两行，这里一定要改，本例中 SipIP 和 XmppIP 都是用的 XMPP 的内部地址。这里如果改的不对或者没有改而留空的话，会导致 XMPP Gateway 服务一启动就马上自动停止!</p>

<p><img src="http://www.powerk6.org/upfiles/2010/06/Fig_10.jpg" /> </p>

<p>· SIP 配置</p>

<p>在 XMPP Gateway 的配置界面中点击 SIP Configuration: </p>

<p>1. <b>Domain</b> 标签卡, Domain 一栏指定你的域名，本例中我们用 <b>litwareinc.com</b>。</p>

<p>2. <b>Host Name</b> 一栏，填上 Edge 边缘服务器的外部 FQDN 名称，本例中我们用 <b>srv.litewareinc.com </b>。</p>

<p><img src="http://www.powerk6.org/upfiles/2010/06/Fig_11.jpg" /> </p>

<p>&nbsp; 3.<b>TLS Certificate</b>，选择之前通过自建 CA 申请的内部证书</p>

<p><img src="http://www.powerk6.org/upfiles/2010/06/Fig_12.jpg" /> </p>

<p>&nbsp;&nbsp;&nbsp; 4. <b>Validate Connection</b> 在下拉列表中选择 <b>litwareinc.com</b>，验证是否配置正确。</p>

<p>· XMPP 配置</p>

<p>选择 <b>XMPP Configuration</b> 节点</p>

<p>1. 在 <b>Allow List</b> 标签卡中, 点击 <b>Add </b>添加。</p>

<p>2. 在弹出的 <b>Federated XMPP Domain names</b> 对话框中,&nbsp; <b>Domain Name</b> 一栏填 <i>gmail.com</i><i>，</i>选择 <b>TCP Dialback</b> (required)，其它留空，确定保存。</p>

<p><img src="http://www.powerk6.org/upfiles/2010/06/Fig_13.jpg" /> </p>

<p>&nbsp;&nbsp;&nbsp; 3.之前提到过，Gmail不使用加密连接，所以这里不需要配置证书。</p>

<p>&nbsp;&nbsp;&nbsp; 4. 验证 Gmail。</p>

<p>· 启动XMPP 服务</p>

<p><img src="http://www.powerk6.org/upfiles/2010/06/Fig_14.jpg" /> </p>

<p><b>D. Edge </b><b>服务器的配置</b><b></b></p>

<p>这里非常简单，就是把 gmail.com 作为联盟域添加: </p>

<p>1. 打开 OCS Edge 的属性配置对话框。</p>

<p><img src="http://www.powerk6.org/upfiles/2010/06/Fig_15.jpg" /> </p>

<p>2. 转到 <b>Allow</b> 标签页, 点击 <b>Add</b>, 按图中所示添加。</p>

<p>Federated partner domain name - <b><i>gmail.com</i></b>, </p>

<p>&nbsp; Federated partner Access Edge Server - <b>srv_xmpp.litewareinc.com</b></p>

<p>3. 为了保证 OCS Edge 服务器能和 XMPP 网关正常通信，你需要在内部 DNS 中添加 XMPP 的记录或者是在本地 Hosts 文件中指定，比如</p>

<p><b>192.168.1.20 srv_xmpp.litwareinc.com</b></p>

<p>四、添加 Gmail 用户并验证</p>

<p>添加 Gmail 用户之前，得保证你的 OCS 用户策略里面有启用联盟</p>

<p><img src="http://www.powerk6.org/upfiles/2010/06/Fig_16.jpg" /> </p>

<p>成功!</p>

<p><img src="http://www.powerk6.org/upfiles/2010/06/Fig_17.jpg" /> </p>

<p><img src="http://www.powerk6.org/upfiles/2010/06/Fig_18.jpg" /></p>]]>
    </content>
</entry>

<entry>
    <title>为 phpBB3 配置 LDAP 认证</title>
    <link rel="alternate" type="text/html" href="http://www.powerk6.org/2010/06/how-to-configure-ldap-auth-for-phpbb3.html" />
    <id>tag:www.powerk6.org,2010://1.273</id>

    <published>2010-06-20T06:05:57Z</published>
    <updated>2010-06-25T07:09:59Z</updated>

    <summary><![CDATA[最近需要架设个论坛,需要支持 LDAP 认证,一番Google之后,选择了来源的 phpBB3 废话不多说了,直接来看看 LDAP 认证设置部分. 管理员控制面板-&gt;客户端通信-&gt;认证设置 关键参数设置 LDAP 服务器名称: 192.168.1.21 --domain.local 域控的IPLDAP基础dn: OUTest, DC=Domain,DC=localLDAP uid: sAMAccountNameLDAP 用户 dn: CN=phpBB,CN=Users,DC=domain,DC=localLDAP 密码: phpBB用户的密码 因为2003以后域不再支持匿名用户查询,所以需要有个域用户来做 LDAP 查询 LDAP uid - 这里用的是&nbsp;sAMAccountName, 当然你也可以使用 UPN - userPrincipalName 属性,甚至自定义字段,比如来个&nbsp;employeeNumber 之类的,让用户以工号登录. 具体的认证过程: 当你第一次填入域用户的用户名和密码时,当 phpBB 发现验证通过,实际上会在php_users表里面添加这个域用户,...]]></summary>
    <author>
        <name>pOweRK6</name>
        <uri>http://www.powerk6.org</uri>
    </author>
    
    <category term="ldap" label="LDAP" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="phpbb" label="phpBB" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.powerk6.org/">
        <![CDATA[<div>最近需要架设个论坛,需要支持 LDAP 认证,一番Google之后,选择了来源的 phpBB3</div>
<div>废话不多说了,直接来看看 LDAP 认证设置部分.</div>
<div>管理员控制面板-&gt;客户端通信-&gt;认证设置</div>
<p><img src="http://www.powerk6.org/upfiles/2010/06/phpbb_ldap.jpg" /> </p>
<div>关键参数设置</div>
<div><a onclick="window.open('http://www.powerk6.org/assets_c/2010/06/phpbb_ldap-8.html','popup','width=450,height=344,scrollbars=no,resizable=no,toolbar=no,directories=no,location=no,menubar=no,status=no,left=0,top=0'); return false" href="http://www.powerk6.org/assets_c/2010/06/phpbb_ldap-8.html"></a>LDAP 服务器名称: <!-- m --><a class="postlink" href="ldap://domain.local">1</a>92.168.1.21<!-- m --> --domain.local 域控的IP<br />LDAP基础dn: OUTest, DC=Domain,DC=local<br />LDAP uid: sAMAccountName<br />LDAP 用户 dn: CN=phpBB,CN=Users,DC=domain,DC=local<br />LDAP 密码: phpBB用户的密码</div>
<div>因为2003以后域不再支持匿名用户查询,所以需要有个域用户来做 LDAP 查询</div>
<div>LDAP uid - 这里用的是&nbsp;sAMAccountName, 当然你也可以使用 UPN - userPrincipalName 属性,甚至自定义字段,比如来个&nbsp;employeeNumber 之类的,让用户以工号登录.</div>
<div><br /></div>
<div>具体的认证过程:</div>
<div>当你第一次填入域用户的用户名和密码时,当 phpBB 发现验证通过,实际上会在php_users表里面添加这个域用户, 而之后的认证其实就分开了, 域用户和论坛用户修改各自的密码都不会影响到对方,这个过程仅仅在第一次登录论坛的时候有效.</div>
<div>那么此时如果你通过论坛页面注册个新用户,这个用户也是会存在于论坛程序的DB里面,而不会在AD中生成,而且,因为开的是 LDAP 认证, 所以这个新建的DB用户也是没法登录论坛的.</div>
<div><br /></div>
<div>解决方法请参考&nbsp;http://www.phpbb.com/community/viewtopic.php?f=46&amp;t=981765</div>
<blockquote style="BORDER-BOTTOM: medium none; BORDER-LEFT: medium none; PADDING-BOTTOM: 0px; MARGIN: 0px 0px 0px 40px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; BORDER-TOP: medium none; BORDER-RIGHT: medium none; PADDING-TOP: 0px" class="webkit-indent-blockquote">
<div>
<dd><code>&lt;?php</code></dd></div>
<div>
<dd><code><br /></code></dd></div>
<div>
<dd><code>include_once($phpbb_root_path . 'includes/auth/auth_ldap.' . $phpEx);</code></dd></div>
<div>
<dd><code>include_once($phpbb_root_path . 'includes/auth/auth_db.' . $phpEx);</code></dd></div>
<div>
<dd><code><br /></code></dd></div>
<div>
<dd><code>function init_ldap_db()</code></dd></div>
<div>
<dd><code>{</code></dd></div>
<div>
<dd><code>&nbsp; &nbsp; &nbsp; &nbsp; init_ldap();</code></dd></div>
<div>
<dd><code>}</code></dd></div>
<div>
<dd><code><br /></code></dd></div>
<div>
<dd><code>function login_ldap_db(&amp;$username, &amp;$password)</code></dd></div>
<div>
<dd><code>{</code></dd></div>
<div>
<dd><code>&nbsp; &nbsp; $test_login_ldap = login_ldap(&amp;$username, &amp;$password);</code></dd></div>
<div>
<dd><code><br /></code></dd></div>
<div>
<dd><code>&nbsp; &nbsp; if (($test_login_ldap[status] == LOGIN_SUCCESS)||($test_login_ldap[status] == LOGIN_SUCCESS_CREATE_PROFILE))</code></dd></div>
<div>
<dd><code>&nbsp; &nbsp; {</code></dd></div>
<div>
<dd><code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; return $test_login_ldap;</code></dd></div>
<div>
<dd><code>&nbsp; &nbsp; }</code></dd></div>
<div>
<dd><code><br /></code></dd></div>
<div>
<dd><code>&nbsp; &nbsp; return login_db(&amp;$username, &amp;$password);</code></dd></div>
<div>
<dd><code>}</code></dd></div>
<div>
<dd><code>?&gt;</code></dd></div></blockquote>
<div><br />
<div><br /></div></div>]]>
        
    </content>
</entry>

</feed>

