Friday, December 19, 2008

HOW TO Resolve Recurring 6482 SharePoint Server 2007 Search Related Errors

From time to time, our SharePoint Server is hit by the 6482 error related to MOSS 2007 Search.

Detailed info on this 6482 error is shown below:

Event Type: Error
Event Source: Office SharePoint Server
Event Category: Office Server Shared Services
Event ID: 6482
Date: 11/6/2008
Time: 3:46:06 PM
User: N/A
Computer: xxxxxxx
Description:
Application Server Administration job failed for service instance Microsoft.Office.Server.Search.Administration.SearchServiceInstance (db3c5f85-a70c-4901-98ed-a3e9a9030493).
Reason: Object bfc3dba7-666c-4968-9f4e-3c426d85c6b4 not found.
Techinal Support Details:
System.Collections.Generic.KeyNotFoundException: Object bfc3dba7-666c-4968-9f4e-3c426d85c6b4 not found.
at Microsoft.Office.Server.Search.Administration.SearchApi.get_App()
at Microsoft.Office.Server.Search.Administration.SearchApi.SetUsersPermittedToQuery(String[] userNames, Boolean force)
at Microsoft.Office.Server.Search.Administration.SearchServiceInstance.Synchronize()
at Microsoft.Office.Server.Administration.ApplicationServerJob.ProvisionLocalSharedServiceInstances(Boolean isAdministrationServiceJob)
For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.

Complete the steps below to resolve the recurring 6482 error

1. Access the SharePoint Central Administration site.

2. Click on the “Operations” tab.

3. Click on “Services on Server” under “Topology and Services” section.

4. Stop the “Office SharePoint Server Search” and “Windows SharePoint Services Search” Services. Stopping these will uninstall the services, and once you re-start them and re-configure with the same settings, site content will start indexing properly again. You should not see the 6482 Errors anymore.

The KeyNotFoundException error reported in the Event Viewer message above was related to the following Object:

Object bfc3dba7-666c-4968-9f4e-3c426d85c6b4 not found.

This is actually a Registry key which is usually found under the following hives in the Registry on the SharePoint server:

HKLM\SOFTWARE\Microsoft\Office Server\12.0\Search\Applications\
HKLM\SOFTWARE\Microsoft\Office Server\12.0\Search\Setup\ContentIndexCommon\LanguageResources\Override\

You DON’T have to manually delete the “offending” Object from the above hives in the Registry. Stopping the 2 services in Central Administration site will remove the “offending” Object from the Registry.


NOTE:
If you need to modify the Registry, REMEMBER TO CREATE A FULL BACKUP BEFORE MAKING ANY UPDATES.

Related Resources on the Web

http://www.eggheadcafe.com/software/aspnet/30014783/moss-2007-errors--still.aspx

http://social.technet.microsoft.com/forums/en-US/sharepointsearch/thread/81872231-0218-440f-b96f-2f5b02dd949f/

http://www.microsoft.com/communities/newsgroups/en-us/default.aspx?dg=microsoft.public.sharepoint.windowsservices&tid=69c450d4-97a2-412c-978a-94919e41c224&cat=&lang=en&cr=US&sloc=&p=1

http://blogs.pointbridge.com/Blogs/bragdon_dwight/Pages/Post.aspx?_ID=16

HOW TO Resolve recurring SharePoint Server 6398, 7076, 6482 errors in Event Viewer

Run the following commands from the command prompt on the SharePoint Server to resolve recurring 6398, 7076, 6482 errors in the Event Viewer.

net stop "Office SharePoint Server Search"
net start "Office SharePoint Server Search"
net stop "Windows SharePoint Services Timer"
net start "Windows SharePoint Services Timer"

From time to time you will see these errors occur in the Event Viewer on the SharePoint server. And when they do occur they occur very frequently (2-4 minutes apart) and they occur in groups. MOSS 2007 SP1 supposedly resolves this issue, but we applied SP1 on our SharePoint Server and these errors still occur intermittently. And when they do occur, it causes a blood bath in the Event Viewer.

Error details are shown below:

6398 Error

Event Type: Error
Event Source: Windows SharePoint Services 3
Event Category: Timer
Event ID: 6398
Date: 11/26/2008
Time: 7:59:14 AM
User: N/A
Computer: xxxxxxxxx
Description:
The Execute method of job definition Microsoft.Office.Server.Administration.ApplicationServerAdministrationServiceJob (ID a7450998-ba3e-4dc1-8528-1f1f851c41bf) threw an exception. More information is included below.

Attempted to read or write protected memory. This is often an indication that other memory is corrupt.

For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.

7076 Error

Event Type: Error
Event Source: Office SharePoint Server
Event Category: Office Server Shared Services
Event ID: 7076
Date: 11/26/2008
Time: 7:59:14 AM
User: N/A
Computer: xxxxxxxxxx
Description:
An exception occurred while executing the Application Server Administration job.

Message: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.

Techinal Support Details:
System.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
at System.DirectoryServices.Interop.UnsafeNativeMethods.IntADsOpenObject(String path, String userName, String password, Int32 flags, Guid& iid, Object& ppObject)
at System.DirectoryServices.Interop.UnsafeNativeMethods.ADsOpenObject(String path, String userName, String password, Int32 flags, Guid& iid, Object& ppObject)
at System.DirectoryServices.DirectoryEntry.Bind(Boolean throwIfFail)
at System.DirectoryServices.DirectoryEntry.Bind()
at System.DirectoryServices.DirectoryEntry.get_IsContainer()
at System.DirectoryServices.DirectoryEntries.CheckIsContainer()
at System.DirectoryServices.DirectoryEntries.Find(String name, String schemaClassName)
at Microsoft.SharePoint.Metabase.MetabaseObjectCollection`1.Find(String name)
at Microsoft.SharePoint.Metabase.MetabaseObjectCollection`1.get_Item(String name)
at Microsoft.SharePoint.Administration.SPProvisioningAssistant.ProvisionIisApplicationPool(String name, ApplicationPoolIdentityType identityType, String userName, SecureString password, TimeSpan idleTimeout, TimeSpan periodicRestartTime)
at Microsoft.SharePoint.Administration.SPMetabaseManager.ProvisionIisApplicationPool(String name, Int32 identityType, String userName, SecureString password, TimeSpan idleTimeout, TimeSpan periodicRestartTime)
at Microsoft.Office.Server.Administration.SharedWebServiceInstance.CreateSharedWebServiceApplicationPool(SharedResourceProvider srp)
at Microsoft.Office.Server.Administration.ApplicationServerJob.ProvisionLocalSharedServiceInstances(Boolean isAdministrationServiceJob)

For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.

6482 Error
Event Type: Error
Event Source: Office SharePoint Server
Event Category: Office Server Shared Services
Event ID: 6482
Date: 11/26/2008
Time: 7:59:14 AM
User: N/A
Computer: xxxxxxxxx
Description:
Application Server Administration job failed for service instance Microsoft.Office.Excel.Server.ExcelServerSharedWebServiceInstance (3db28ccf-4536-48d1-a04a-17ff31d6df9f).

Reason: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.

Techinal Support Details:
System.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
at System.DirectoryServices.Interop.UnsafeNativeMethods.IntADsOpenObject(String path, String userName, String password, Int32 flags, Guid& iid, Object& ppObject)
at System.DirectoryServices.Interop.UnsafeNativeMethods.ADsOpenObject(String path, String userName, String password, Int32 flags, Guid& iid, Object& ppObject)
at System.DirectoryServices.DirectoryEntry.Bind(Boolean throwIfFail)
at System.DirectoryServices.DirectoryEntry.Bind()
at System.DirectoryServices.DirectoryEntry.get_IsContainer()
at System.DirectoryServices.DirectoryEntries.CheckIsContainer()
at System.DirectoryServices.DirectoryEntries.Find(String name, String schemaClassName)
at Microsoft.SharePoint.Metabase.MetabaseObjectCollection`1.Find(String name)
at Microsoft.SharePoint.Metabase.MetabaseObjectCollection`1.get_Item(String name)
at Microsoft.SharePoint.Administration.SPProvisioningAssistant.ProvisionIisApplicationPool(String name, ApplicationPoolIdentityType identityType, String userName, SecureString password, TimeSpan idleTimeout, TimeSpan periodicRestartTime)
at Microsoft.SharePoint.Administration.SPMetabaseManager.ProvisionIisApplicationPool(String name, Int32 identityType, String userName, SecureString password, TimeSpan idleTimeout, TimeSpan periodicRestartTime)
at Microsoft.Office.Server.Administration.SharedWebServiceInstance.Synchronize()
at Microsoft.Office.Excel.Server.ExcelServerSharedWebServiceInstance.Synchronize()
at Microsoft.Office.Server.Administration.ApplicationServerJob.ProvisionLocalSharedServiceInstances(Boolean isAdministrationServiceJob)

For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.

Extract Date portion only from SQL DateTime

I discovered that in both SQL Server 2000 and SQL Server 2005 there is no out-of-the-box function that returns just the Date portion only from a SQL DateTime. But I found this function that returns just the date:

SELECT CONVERT(varchar, getdate(), 101)

Also, check out Jeff Smith's excellent blog here regarding SQL user-defined functions related to SQL DateTime data type.

Visual Studio 2005 related issues and resolutions

Issue 1

When installing Visual Studio Pro Edition using the MSDN CDs CD1 and CD2, you will run into an error saying that the following files are missing. These files are NOT on CD1. They are on CD2. So before installing VS 2005, copy all the files from the CD2 folder to CD1. DO NOT overwrite the “autorun.exe” or “autorun.inf” files on CD1. Then execute “autorun.exe” from CD1 and follow the steps in the installation wizard.1311.

Source file not found: c:\vs 2005 setup\cd1\_15780_RTL_x86_enu_NETCF_v2.0.cab. Verify that the file exists and that you can access it. c:\vs 2005 setup\cd1\_15780_RTL_x86_enu_NETCF_v2.0.cab. Verify that the file exists and that you can access it.

Error 1309.Error reading from file: c:\vs 2005 setup\cd1\Program Files\Microsoft Visual Studio 8\SDK\v2.0\GuiDebug\shortcutCLRDbg32.txt. Verify that the file exists and that you can access it.

Error 1309.Error reading from file: c:\vs 2005 setup\cd1\wcu\JSharpRedistCore\vjredist.exe. Verify that the file exists and that you can access it.

Error 1309.Error reading from file: c:\vs 2005 setup\cd1\wcu\SSE\sqlexpr32.exe. Verify that the file exists and that you can access it.

Related Web Resources:
http://social.msdn.microsoft.com/Forums/en-US/vssetup/thread/bd9c13a6-beba-4c94-8157-f48170e663a8/


Issue 2
If you don’t have the Web Application Project type installed on top of Visual Studio 2005, you will get an error saying that the “project type is not supported by this installation.” To resolve this issue, install the following components in the order listed below:

1. VS80-KB915364-X86-ENU.exe - http://www.microsoft.com/downloads/details.aspx?familyid=8b05ee00-9554-4733-8725-3ca89dd9bfca&displaylang=en

2. WebApplicationProjectSetup.msi - http://download.microsoft.com/download/9/0/6/906064ce-0bd1-4328-af40-49dca1aef87c/WebApplicationProjectSetup.msi

Related Web Resources:http://www.devnewsgroups.net/group/microsoft.public.dotnet.framework/topic49512.aspx
http://msdn.microsoft.com/en-us/asp.net/aa336618.aspx

Monday, December 1, 2008

WSS 3.0/MOSS 2007 SP1 and Custom Action in SharePoint Designer

We implemented SharePoint Designer based workflows at a client site. One of these workflows copies a document that is created at the "root" level of a document library (which hosts InfoPath-based documents) to a designated folder and then deletes the document from the "root" level. We were using a custom Action titled "Copy List Item Extended" that we got from CodePlex (http://www.codeplex.com/SPDActivities/Wiki/View.aspx?title=Copy%20List%20Item%20Extended%20Activity&referringTitle=Available%20Activities) to perform the Copy operation, and the out-of-the-box provided "Delete Item" Action to delete the document. Once the document is copied, we have another dependent workflow that runs (when a new Item is created in the folder) and generates an e-mail that is sent to an Approver. The e-mail contains a link to the document that now resides inside a folder. These workflows were working fine until we applied WSS 3.0 Service Pack 1 and MOSS 2007 Service Pack 1. After we applied both Service Packs, we found that the document was being successfully copied by the "Copy List Item Extended" Action to the folder, but the dependent workflow (the one that generates the e-mail) was not running.

After a lot of troubleshooting, we contacted Microsoft Support and we discovered that the "Copy List Item Extended" Action was NOT being recognized by SharePoint as an Event after the SPs were applied. And therefore the dependent workflow was not being triggered.

To resolve this issue, we are now using the out-of-the-box provided "Update List Item" Action to move the document from the "root" level to the designated folder in the document library. With this we don't have to explicitly call the "Delete Item" Action to delete the document from the "root" level. The "Update List Item" Action simply moves the document to the new location (i.e. the designated folder). And this is recognized as an Event by SharePoint and therefore the dependent workflow is triggered and the e-mail is generated successfully.

I am hoping this information will help others out there who might encounter this issue.