SharePoint 2016 – Central Administration – ScriptResource.axd 404 error

Recently my colleague and I came across a SharePoint2016 Farm, that had some issues with the suitebar not loading. In the network trace we found a 404 error for the ScriptResource.axd request. Using the event viewer we came across the following error message:

Event code: 3012
Event message: An error occurred processing a web or script resource request. The requested resource 'ZSystem.Web.Extensions,4.0.0.0,,31bf3856ad364e35|MicrosoftAjax.js|' does not exist or there was a problem loading it. 
Event time: 21.03.2018 09:57:57
Event time (UTC): 21.03.2018 08:57:57
Event ID: 59637ef8b92b43b59cadfd4b3ce61619 Event sequence: 7 Event occurrence: 1 Event detail code: 0 
 
Application information: 
 Application domain: /LM/W3SVC/275657850/ROOT-1-131660962662183250 
 Trust level: Full 
 Application Virtual Path: / 
 Application Path: C:\inetpub\wwwroot\wss\VirtualDirectories\4432\ 
 Machine name: SERVERNAME 
 
Process information: 
 Process ID: 6916 
 Process name: w3wp.exe 
 Account name: ***\***** 
 
Exception information: 
 Exception type: ZLibException 
 Exception message: The underlying compression routine could not be loaded correctly.
 at System.IO.Compression.DeflaterZLib.DeflateInit(CompressionLevel compressionLevel, Int32 windowBits, Int32 memLevel, CompressionStrategy strategy)
 at System.IO.Compression.DeflaterZLib..ctor(CompressionLevel compressionLevel)
 at System.IO.Compression.DeflateStream.CreateDeflater(Nullable`1 compressionLevel)
 at System.IO.Compression.DeflateStream..ctor(Stream stream, CompressionMode mode, Boolean leaveOpen)
 at System.IO.Compression.GZipStream..ctor(Stream stream, CompressionMode mode)
 at System.Web.Handlers.ScriptResourceHandler.ProcessRequestInternal(HttpResponseBase response, String decryptedString, VirtualFileReader fileReader)
 at System.Web.Handlers.ScriptResourceHandler.ProcessRequest(HttpContextBase context, VirtualFileReader fileReader, Action`2 logAction, Boolean validatePath)

The type initializer for 'NativeZLibDLLStub' threw an exception.
 at System.IO.Compression.ZLibNative.ZLibStreamHandle.DeflateInit2_(CompressionLevel level, Int32 windowBits, Int32 memLevel, CompressionStrategy strategy)
 at System.IO.Compression.DeflaterZLib.DeflateInit(CompressionLevel compressionLevel, Int32 windowBits, Int32 memLevel, CompressionStrategy strategy)

Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED))
 at System.Runtime.InteropServices.Marshal.ThrowExceptionForHRInternal(Int32 errorCode, IntPtr errorInfo)
 at System.Runtime.InteropServices.Marshal.ThrowExceptionForHR(Int32 errorCode, IntPtr errorInfo)
 at System.IO.Compression.ZLibNative.ZLibStreamHandle.NativeZLibDLLStub.LoadZLibDLL()
 at System.IO.Compression.ZLibNative.ZLibStreamHandle.NativeZLibDLLStub..cctor()

Request information: 
 Request URL: http://SERVERNAME:10000/ScriptResource.axd?d=8QMyovunFMoY381OpYQyz9XcLkCjJ_XuifoGDX5Q8vatF2gNXkCNXfW0-6Dz_mvZVHapsY1FH-l9zy2l3q3V1Z5dqWndvspmAcN7L1hB-UomBeamTvhHGIe5ZcW_f-DqtS3ymyGl5Bk-ybE1j6mAb8ZMhM8n4e_WwQEe8IkCMRsq_DHxVXNP720ZZXWT1ATa0&t=ffffffffad4b7194 
 Request path: /ScriptResource.axd 
 User host address: ***SERVERNAME 
 User: 
 Is authenticated: False 
 Authentication Type: 
 Thread account name: NT AUTHORITY\IUSR 
 
Thread information: 
 Thread ID: 20 
 Thread account name: NT AUTHORITY\IUSR 
 Is impersonating: False 
 Stack trace: at System.IO.Compression.DeflaterZLib.DeflateInit(CompressionLevel compressionLevel, Int32 windowBits, Int32 memLevel, CompressionStrategy strategy)
 at System.IO.Compression.DeflaterZLib..ctor(CompressionLevel compressionLevel)
 at System.IO.Compression.DeflateStream.CreateDeflater(Nullable`1 compressionLevel)
 at System.IO.Compression.DeflateStream..ctor(Stream stream, CompressionMode mode, Boolean leaveOpen)
 at System.IO.Compression.GZipStream..ctor(Stream stream, CompressionMode mode)
 at System.Web.Handlers.ScriptResourceHandler.ProcessRequestInternal(HttpResponseBase response, String decryptedString, VirtualFileReader fileReader)
 at System.Web.Handlers.ScriptResourceHandler.ProcessRequest(HttpContextBase context, VirtualFileReader fileReader, Action`2 logAction, Boolean validatePath)

After several hours of a nerve-wracking search for a solution, we came across this blog by Mike Lee . He saw the same issue and did find a solution. In the end we did change some additional GPO settings (Replace a process level token) for our application pool accounts.

In the first place we were in the search for FIPS settings, as there are many results in google pointing in that direction. We did:

  • Disable FIPS in the registry
  • Changed the GPO that got applied to this server
  • Tried the GZIP compression using a console application.

These settings did not help. Thanks to Mike Lee we were able to resolve this issue.

Advertisements

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 )

Google photo

You are commenting using your Google 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 )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.