Feeds:
Posts
Comments

Archive for April, 2017

One possible reason to have an error accessing a SharePoint site (page not found, 404 error) is that content database is not accessible by Pool user.

This could happen after restoring content database using SQL restore if you don’t follow the steps exactly.

In this case you will likely find in the ULS logs an error like

SqlError: ‘Cannot open database “WSS_Content_XYZ” requested by the login. The login failed.’

Quick fix: from central administration -> Manage content databases -> select the content database and check the “remove” to remove it from the farm and then add it again. when SP adds the content database back, it makes sure all required permissions are added and this could fix the problem.

Read Full Post »

When running Enable-SPFeature, you may get the weird error:

“Enable-SPFeature : The file is currently checked out or locked for editing by another user.”

 

One possible cause of this issue could be that some file(s) the are deployed by the feature could be checked out by a user.

Checking the ULS logs you could find something like

 

Instantiating module “NAMEOFMODULE”: File could not be added at URL “FILENAME.jpg: Error 689225296 99e77593-d0d4-49df-adcc-c8f8251fbb82
04/06/2017 20:53:42.02 PowerShell.exe (0x107C) 0x1334 SharePoint Foundation Monitoring b4ly High Leaving Monitored Scope (SPSqlClient). Execution Time=11589.5652 99e77593-d0d4-49df-adcc-c8f8251fbb82
04/06/2017 20:53:42.02 PowerShell.exe (0x107C) 0x1334 SharePoint Foundation General 8kh7 High The file is currently checked out or locked for editing by another user.<nativehr>0x80070021</nativehr><nativestack></nativestack> 99e77593-d0d4-49df-adcc-c8f8251fbb82
04/06/2017 20:53:42.03 PowerShell.exe (0x107C) 0x1334 SharePoint Foundation General aix9j High SPRequest.EnableModuleFromXml: UserPrincipalName=i:0).w|s-1-5-21-995927836-1113283497-4239367599-17896, AppPrincipalName= ,bstrSetupDirectory=C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\15\Template ,bstrFeatureDirectory=Features\ABCDEP ,bstrUrl=,bstrXML=<Module Name=”images” Path=”Style Library\images” Url=”Style Library/images” RootWebOnly=”TRUE” xmlns=”http://schemas.microsoft.com/sharepoint/”><File ReplaceContent=”True” Type=”GhostableInLibrary” Path=”favicon.ico” Url=”favicon.ico” /><File ReplaceContent=”True” Type=”GhostableInLibrary” Path= ,fForceUnghost=False ,pModuleContext=<null> 99e77593-d0d4-49df-adcc-c8f8251fbb82
04/06/2017 20:53:42.03 PowerShell.exe (0x107C) 0x1334 SharePoint Foundation General ai1wu Medium System.Runtime.InteropServices.COMException: The file is currently checked out or locked for editing by another user.<nativehr>0x80070021</nativehr>

Read Full Post »

We had a very weird issue today with a SharePoint publishing site. Some js and css files (which were deployed as part of a WSP) were not updated in the publishing zone.

When checking from the authoring zone, everything looked ok: the latest file was published and approved (was v1.0 since it was deployed as part of a solution). In the publishing site though, for end users, We were getting an older version of the file.

Tried clearing browser cache, close and open browser, use in-private browsing, resetting IIS, restarting server, restarting client machine, nothing worked.

After a lot of investigation and trials and errors, the issue turned out to be caused by the BlobCache. When we disabled the blob cache in the publishing zone, latest files started to work fine. With Blob Cache enabled, we were getting an older version.

For some reason even flush cache powershell command didnt seem to fix this issue. We had to disable the blobcache in the web.config for the publishing site and then manually delete the blob cache files. We then enabled blobcache again and things seemed to work fine.

More details about the nuts and bolts of BlobCache (long but interesting read) can be found at: https://sharepointinterface.com/2012/03/12/do-you-know-whats-going-to-happen-when-you-enable-the-sharepoint-blob-cache/ 

 

Read Full Post »