[This is preliminary documentation and is subject to change. Blank topics are included as placeholders.]

Tests the ability of a user to access the Address Book Server.

Syntax

Test-CsAddressBookService -TargetFqdn <String> [-Force <SwitchParameter>] [-OutVerboseVariable <String>] [-RegistrarPort <Nullable>] [-UserSipAddress <String>]
Test-CsAddressBookService -TargetFqdn <String> -UserCredential <PSCredential> -UserSipAddress <String> [-Force <SwitchParameter>] [-OutVerboseVariable <String>] [-RegistrarPort <Nullable>]

Parameters

Parameter Required Type Description

TargetFqdn

Required

String

Fully qualified domain name of the registrar pool where the Address Book service is to be tested. For example: -TargetFqdn "atl-cs-001.litwareinc.com".

You cannot use both the –TargetUri parameter and the –TargetFqdn parameter in the same command.

TargetUri

Required

String

URI of the Address Book service’s Web service. For example: -TargetUri "https://atl-cs-001.litwareinc.com/abs/handler".

You cannot use both the –TargetUri parameter and the –TargetFqdn parameter in the same command.

Certificate

Required

X509 certificate

Enables you to use an X.509 certificate for authentication purposes when running Test-CsAddressBookService.

UserCredential

Required

PS credential object

User credential object for the user account to be used in the test. The value passed to -UserCredential should be an object reference obtained by using the Get-Credential cmdlet. For example, this code returns a credentials object for the user litwareinc\kenmyer and stores that object in a variable named $x:

$x = Get-Credential "litwareinc\kenmyer"

You need to supply the user password when running this command.

UserSipAddress

Required

SIP address

SIP address of the user to be used in the test. If this parameter is not specified then Test-CsAddressBookService will conduct its checks using the account of the logged-in user.

External

Optional

Switch Parameter

Enables you to verify that external users can use the Address Book service.

Verbose

Required

Switch Parameter

Reports detailed activity to the screen as the cmdlet runs.

Force

Optional

Switch Parameter

Suppresses the display of any non-fatal error message that might arise when running the command.

Detailed Description

Any user who has been enabled for Microsoft Communications Server relies heavily on the Address Book service. After all, when users employ Microsoft Communicator to search for a new contact they do not search Active Directory itself. Instead, they typically search through files that have been downloaded from the Address Book service. These files represent relevant information that the Address Book service has extracted from Active Directory, and the Address Book is charged with periodically synchronizing with the directory service and keeping these files up-to-date. If a person cannot connect to the Address Book service then he or she will not have access to the current list of available users and groups.

The Test-CsAddressBookService cmdlet provides a way for you to verify that a user can connect to the Address Book service. When you run the cmdlet, Test-CsAddressBookService connects to the Address Book service on the specified pool and requests the location of the Address Book files. If the Address Book service supplies that location the test is considered successful. If the request is denied then the test is considered a failure. You can run the cmdlet using a user account configured for a health monitoring registrar or by using the credentials of another user. In the latter case, you will need to supply the logon name, password, and SIP address of the user being impersonated. See the help topic New-CsHealthMonitoringConfiguration for more information.

In addition to that, you can test the Address Book service in two different ways: by testing the service itself, or by testing the associated Web service.

Return Types

Test-CsAddressBookService returns an instance of the Microsoft.Rtc.SyntheticTransactions.TaskOutput object.

Examples

-------------------------- Example 1 --------------------------

Copy Code
Test-CsAddressBookService -TargetFqdn atl-cs-001.litwareinc.com 

The preceding example tests the Address Book service for the pool atl-cs-001.litwareinc.com. This command tests the Address Book service using a health monitoring user account preconfigured for the pool atl-cs-001.litwareinc.com.

-------------------------- Example 2 --------------------------

Copy Code
$cred1 = Get-Credential "litwareinc\jhaas"

Test-CsAddressBookService -TargetFqdn atl-cs-001.litwareinc.com -UserCredential $cred1

The commands shown in Example 2 also test the availability of the Address Book server; in this case, however, the commands are running under the credentials for the user Jonathan Haas (litwareinc\jhaas). To do this, the first command uses the Get-Credential cmdlet to create a PowerShell credential object containing the name and password of the user Jonathan Haas. (Because the logon name - litwareinc\jhaas - has been included as a parameter, the resulting Windows PowerShell Credential Request dialog box only requires the administrator to enter the password for the Jonathan Haas account.) The resulting credential object is then stored in a variable named $cred1.

In the second command, Test-CsAddressBookService is used to test the Address Book service for the pool atl-cs-001.litwareinc.com. To run this command under Jonathan Haas’ user credentials, the -UserCredential parameter is included, along with the parameter value $cred1.

-------------------------- Example 3 --------------------------

Copy Code
$cred1 = Get-Credential "litwareinc\jhaas"

Test-CsAddressBookService -TargetUri https://atl-cs-001.litwareinc.com/abs/handler -UserCredential $cred1

Example 3 shows how you can test the Web service associated with the Address Book service for atl-cs-001.litwareinc.com. To do, the first command in the example uses Get-Credential to create a PowerShell credential object for the user litwareinc\jhaas; this credential object is then stored in a variable named $cred1. In the second command, Test-CsAddressBookService is called along with two parameters: -TargetUri, which specifies the URI of the Address Book Web service; and –UserCredential, which contains the PowerShell credential object for the user account being utilized in the test.