Serious IIS Application Pool recycling bug/design flaw

1 year ago
Is there anything need to be configured for a 4.1 fresh install on Azure Web App?

I've setup a fresh 4.1 install and after a while of inactivity, I get the same error. Note that I've not changed any configuration settings.
1 year ago
out of the box, you're still going to get this error.

The work arounds work though.

Check them out and let me know if you get stuck.

I personally think nopcommerce should be run in a vm until the architecture cleans up a little.
1 year ago
RoastedBytes wrote:
Is there anything need to be configured for a 4.1 fresh install on Azure Web App?

I've setup a fresh 4.1 install and after a while of inactivity, I get the same error. Note that I've not changed any configuration settings.


According to Nop devs, this problem is solved in 4.1.

Perhaps you could provide screenshots / logs?
1 year ago
timmit wrote:
According to Nop devs, this problem is solved in 4.1.

Perhaps you could provide screenshots / logs?


I think it had something to do with the webapp configuration. I deleted and created a new webapp on azure and then setup the app again. The problem seems to have been fixed now.
1 year ago
I am running 4.1 on Azure and the problem is still occurring.
1 year ago
there is an option in appsettings.json to turn shadow copy off now,
you can, if necessary, control it there.
1 year ago
Same issue on azure (nopcommerce 4.10).
I tried to just set CopyLockedPluginAssembilesToSubdirectoriesOnStartup to true and I get the System.UnauthorizedAccessException: Access to the path exception
It happens when NopFileProvider tries to copy the dll from Plugins\bin to the subdirectories (reverse shadow paths)

If I disable shadow copy (UsePluginsShadowCopy -> false) then I get multiple exceptions from the plugins not being able to load plugin assemblies. For example Nivo slider widget cannot find Nop.Plugin namespace:

(One or more compilation references are missing. Ensure that your project is referencing 'Microsoft.NET.Sdk.Web' and the 'PreserveCompilationContext' property is not set to false.
The type or namespace name 'Plugin' does not exist in the namespace 'Nop' (are you missing an assembly reference?))

Maybe I'm missing something.
Any help is appreciated
1 year ago
angeor wrote:

If I disable shadow copy (UsePluginsShadowCopy -> false) then I get multiple exceptions from the plugins not being able to load plugin assemblies. For example Nivo slider widget cannot find Nop.Plugin namespace...


When disabling shadow copy and running the web site it seems that the Razor view engine is trying to find Razor precompiled Views. I assume that this is because it finds the deps file that is generated and moved to the Plugins folder. I had to use <GenerateDependencyFile>false</GenerateDependencyFile> in order to skip generation of the Deps file for every plugin project that contained some type of View.
Alternatively one could alter the Clear Plugin Assemblies task to delete the deps file too.

Nopcommerce 4.10 with Shadow copy disabled seems to be working right now, too soon to be 100% sure.

It would be awesome if it could work with shadow copy and "CopyLockedPluginAssembilesToSubdirectoriesOnStartup" enabled as it makes deployment of plugins somewhat easier.
1 year ago
Is it still working fine?
1 year ago
Hi,

FYI I am using NopCommerce 4.1 and I set disallowOverlappingRotation to true on Azure websites as explained here:
https://stackoverflow.com/questions/27421024/disable-pool-recycling-on-azure-websites

However, I still get this error times to times. What is the real fix for NopCommerce 4.1 ?
FYI, I have enabled Azure diagnostics logs and here is what i get


<div id="content">
<div class="content-container">
<h3>HTTP Error 500.0 - Internal Server Error</h3>
<h4>The page cannot be displayed because an internal server error has occurred.</h4>
</div>
<div class="content-container">
<fieldset><h4>Most likely causes:</h4>
<ul>   <li>IIS received the request; however, an internal error occurred during the processing of the request. The root cause of this error depends on which module handles the request and what was happening in the worker process when this error occurred.</li>   <li>IIS was not able to access the web.config file for the Web site or application. This can occur if the NTFS permissions are set incorrectly.</li>   <li>IIS was not able to process configuration for the Web site or application.</li>   <li>The authenticated user does not have permission to use this DLL.</li>   <li>The request is mapped to a managed handler but the .NET Extensibility Feature is not installed.</li> </ul>
</fieldset>
</div>
<div class="content-container">
<fieldset><h4>Things you can try:</h4>
<ul>   <li>Ensure that the NTFS permissions for the web.config file are correct and allow access to the Web server's machine account.</li>   <li>Check the event logs to see if any additional information was logged.</li>   <li>Verify the permissions for the DLL.</li>   <li>Install the .NET Extensibility feature if the request is mapped to a managed handler.</li>   <li>Create a tracing rule to track failed requests for this HTTP status code. For more information about creating a tracing rule for failed requests, click <a href="http://go.microsoft.com/fwlink/?LinkID=66439">here</a>. </li> </ul>
</fieldset>
</div>

<div class="content-container">
<fieldset><h4>Detailed Error Information:</h4>
<div id="details-left">
<table border="0" cellpadding="0" cellspacing="0">
<tr class="alt"><th>Module</th><td>&nbsp;&nbsp;&nbsp;AspNetCoreModule</td></tr>
<tr><th>Notification</th><td>&nbsp;&nbsp;&nbsp;ExecuteRequestHandler</td></tr>
<tr class="alt"><th>Handler</th><td>&nbsp;&nbsp;&nbsp;aspNetCore</td></tr>
<tr><th>Error Code</th><td>&nbsp;&nbsp;&nbsp;0x00000000</td></tr>

</table>
</div>
<div id="details-right">
<table border="0" cellpadding="0" cellspacing="0">
<tr class="alt"><th>Requested URL</th><td>&nbsp;&nbsp;&nbsp;http://<BALALALA>:80/</td></tr>
<tr><th>Physical Path</th><td>&nbsp;&nbsp;&nbsp;D:\home\site\wwwroot</td></tr>
<tr class="alt"><th>Logon Method</th><td>&nbsp;&nbsp;&nbsp;Anonymous</td></tr>
<tr><th>Logon User</th><td>&nbsp;&nbsp;&nbsp;Anonymous</td></tr>

Do you have informations that can help me ?
Thanks a lot