OCS/ Lync Client address Book showing old data

Hi Readers,

Want to share the below batch script that we use when addressbook gets out of sync, some times user complains in our enviornment that he or she is not able to see new titles of the user although it is populated in outlook GAL.

1.      Exit user’s communicator.

2.      Run the following file from an admin/elevated command prompt: (Batch file)

——————————————————————————————————————

@echo off
echo Clearing Address Books…
reg add HKCU\Software\Policies\Microsoft\Communicator /v GALDownloadInitialDelay /t REG_DWORD /d 0 /f
If %errorlevel%==1 goto Error
if “%LOCALAPPDATA%”==”” Set LOCALAPPDATA=%USERPROFILE%\Local Settings\Application Data
dir “%LOCALAPPDATA%\Microsoft\Communicator\sip_*” /b > list.txt
FOR /F “tokens=1” %%i in (list.txt) do del “%LOCALAPPDATA%\Microsoft\Communicator\%%i\gal*.*”
echo.
echo Sign out of Lync and sign back in to download the current address book.
goto End
:Error
echo You must run this command from an elevated Command Prompt.
echo.
:End

——————————————————————————————————————————

3.      Launch communicator and ask user to sign in.

4.      Check whether the Galcontacts.db file has been downloaded.

Galcontacts.db path:

  • ·         In XP:- C:\Documents and Settings\<User Profile>\Local Settings\Application Data\Microsoft\Communicator\<Users SIP>\
  • ·         In Win 7:- C:\Users\<User Profile>\AppData\Local\Microsoft\ Communicator\<Users SIP>\

5.      Run the following file from an admin/elevated command prompt:(This step is so that Gal is not downloaded everytime)

——————————————————————————————————————————

@echo off
echo Clearing Communicator Address Books…
reg delete HKCU\Software\Policies\Microsoft\Communicator /v GALDownloadInitialDelay /f
If %errorlevel%==1 goto Error
echo.
goto End
:Error
echo You must run this command from an elevated Command Prompt.
echo.
:End

——————————————————-

found on Some whrere on Net but modified a bit & included second batch file so that Gal is not downloaded again & again.

Thanks

Vikas

Advertisements

One thought on “OCS/ Lync Client address Book showing old data

  1. Hey There. I found your blog using msn. This is
    an extremely well written article. I’ll make sure
    to bookmark it and return to read more of your useful information.

    Thanks for the post. I’ll certainly return.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s