Our Nop v3.50 instance hosted on Azure received the following errors:
The process cannot access the file 'D:\home\site\wwwroot\Plugins\SevenSpikes.Core\Resources\ConditionsResources.en-us.xml' because it is being used by another process.
Our Nop v3.50 instance hosted on Azure received the following errors:
The process cannot access the file 'D:\home\site\wwwroot\Plugins\SevenSpikes.Core\Resources\ConditionsResources.en-us.xml' because it is being used by another process.
Would you have any idea why that is? Thanks,
Lorenz
Hi lorenz,
it seems that the file is locked by some other process. Could you please restart your website and see if the problem will disappear.
Process information: Process ID: 4928 Process name: w3wp.exe Account name: IIS APPPOOL\pluscanvas-web-euwest__ebee
Exception information: Exception type: HttpException Exception message: The process cannot access the file 'D:\home\site\wwwroot\Plugins\SevenSpikes.Core\Resources\ConditionsResources.en-us.xml' because it is being used by another process. at System.Web.HttpApplicationFactory.EnsureAppStartCalledForIntegratedMode(HttpContext context, HttpApplication app) at System.Web.HttpApplication.RegisterEventSubscriptionsWithIIS(IntPtr appContext, HttpContext context, MethodInfo[] handlers) at System.Web.HttpApplication.InitSpecial(HttpApplicationState state, MethodInfo[] handlers, IntPtr appContext, HttpContext context) at System.Web.HttpApplicationFactory.GetSpecialApplicationInstance(IntPtr appContext, HttpContext context) at System.Web.Hosting.PipelineRuntime.InitializeApplication(IntPtr appContext) The process cannot access the file 'D:\home\site\wwwroot\Plugins\SevenSpikes.Core\Resources\ConditionsResources.en-us.xml' because it is being used by another process. at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost) at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options, String msgPath, Boolean bFromProxy) at System.IO.FileStream..ctor(String path, FileMode mode) at SevenSpikes.Nop.Framework.InstallHelper.Mv4DQIYrba(Object , Object , Object , Boolean ) at SevenSpikes.Nop.Framework.InstallHelper.Cu7vDNsqrwWGsapGMcj(Object , Object , Object , Boolean ) at SevenSpikes.Nop.Framework.InstallHelper.InstallLocaleResources(String pluginFolderName, String fileNameWithoutCultureAndExtension, Boolean updateExistingResources) at SevenSpikes.Nop.Plugins.Core.RouteProvider.InkJaeGCBVJBhmemefM(Object , Object , Object , Boolean ) at SevenSpikes.Nop.Plugins.Core.RouteProvider.InstallMissingResources() at SevenSpikes.Nop.Framework.Routing.BaseRouteProvider.D6vvRF7hHmZ4stfCKFi(Object ) at SevenSpikes.Nop.Framework.Routing.BaseRouteProvider.RegisterRoutes(RouteCollection routes) at Nop.Web.Framework.Mvc.Routes.RoutePublisher.<>c__DisplayClass3.b__1(IRouteProvider rp) at System.Collections.Generic.List`1.ForEach(Action`1 action) at Nop.Web.Framework.Mvc.Routes.RoutePublisher.RegisterRoutes(RouteCollection routes) at Nop.Web.MvcApplication.RegisterRoutes(RouteCollection routes) at Parabol.Web.MvcApplication.Application_Start()
It only happens after deployment and disappears after a while. But this issue causing big problems for our continious integration. It delays our applications warm up times about 2-3 minutes.
It only happens after deployment and disappears after a while. But this issue causing big problems for our continious integration. It delays our applications warm up times about 2-3 minutes.
We got to ressolve this problem.
Hi,
could you please tell us what are the steps of the deployment? Do you stop your site before the deploy? And do you deploy only the changed files or the whole site? Please provide as much information as you can, so that we can resolve this problem faster.
We deploy the app with ms web deploy, with changed files only. We take app offline before deployment app_offline file, but not stop the IIS which is not possible in our setup.
We deploy the app with ms web deploy, with changed files only. We take app offline before deployment app_offline file, but not stop the IIS which is not possible in our setup.
Thanks Kerem
Hi,
We use the same approach when uploading files on our demo sites and we never had such an issue.
We use the "ConditionsResources.en-us.xml" file to read the resources from it and upload it to the database. Right after we finish with the file, we dispose it so it should not be open after the operation is done. Actually, we do this for a lot of .xml files, there is no reason that the problem will be with this file only. Can you check if the files has the correct permissions ?
Is there a way to find out which process is locking the file? This may be helpful to identify the problem.