Reputation: 1211
I'm trying to replace the Windows Azure AppFabric Cache with the newly released Role-based caching that was introduced in the June 2012 SDK release by following the guides on Microsoft's website.
However, when checking the "Enable Caching (Preview)" in my Web Role, the emulator will not successfully instantiate the web site (emulator log: http://pastebin.com/dwbDvak2). It seems it is getting stuck in some kind of loop. Disabling the Web Role caching makes it work again. I have gotten the same result after uninstalling all previous Azure SDKs and re-installed the 1.7 version.
Visual Studio is telling me that "Role instances are taking longer than expected to start. Do you want to continue waiting?" [Yes][No]. Pressing Yes keeps it waiting, and shows up over and over again.
Are there anyone who might know how to solve the issue described above, or perhaps have tried the new web role caching functionality and got it working in the azure emulator?
Screen shot of the azure local debugging environment deployment dialog
Thank you.
Update:
I created a new solution, and added just a simple MVC site, added the web role and enabled caching, and the same thing happened. So, I took a look at the Event Viewer, and found 3 entries relating to the issue:
Fault bucket 3034750239, type 5
Event Name: CLR20r3
Response: Not available
Cab Id: 0
Problem signature:
P1: cacheinstaller.exe
P2: 1.0.4655.0
P3: 4fb0f3f9
P4: CacheInstaller
P5: 1.0.4655.0
P6: 4fb0f3f9
P7: 11
P8: 47
P9: System.TypeLoadException
P10:
Attached files:
C:\Users\anan\AppData\Local\Temp\WEREA8F.tmp.WERInternalMetadata.xml
These files may be available here:
C:\Users\anan\AppData\Local\Microsoft\Windows\WER\ReportArchive\AppCrash_cacheinstaller.e_1fbc3b72afb6acf93335ca8611850d289906c25_2ddaf529
Analysis symbol:
Rechecking for solution: 0
Report Id: 3138ba06-b344-11e1-a8d6-402cf41c1e07
Report Status: 0
Application: CacheInstaller.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.MissingMethodException
Stack:
at Microsoft.ApplicationServer.Caching.AzureCommon.Package.InitializeExternalStoreIfRequired()
at System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object)
at System.Threading.ThreadHelper.ThreadStart()
And then:
Application: CacheInstaller.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.MissingMethodException
Stack:
at Microsoft.ApplicationServer.Caching.AzureCommon.Package.InitializeExternalStoreIfRequired()
at System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object)
at System.Threading.ThreadHelper.ThreadStart()
And:
Faulting application name: CacheInstaller.exe, version: 1.0.4655.0, time stamp: 0x4fb0f3f9
Faulting module name: KERNELBASE.dll, version: 6.1.7601.17651, time stamp: 0x4e21213c
Exception code: 0xe0434352
Fault offset: 0x000000000000cacd
Faulting process id: 0x17b4
Faulting application start time: 0x01cd4750f5db0096
Faulting application path: c:\users\anan\documents\visual studio 11\Projects\AzureCacheTest\AzureCacheTest\csx\Debug\roles\WebRole\plugins\Caching\CacheInstaller.exe
Faulting module path: C:\Windows\system32\KERNELBASE.dll
Report Id: 33a53608-b344-11e1-a8d6-402cf41c1e07
FYI: This is a Windows 7 x64 Enterprise edition, using Visual Studio 2012 RC.
Upvotes: 5
Views: 3040
Reputation: 1662
For me, the problem was that I was running my project off of a UNC Share (actually its running in a VM on my macbook). When I'd start the debugger after checking the "Enable Caching" box on the worker role, it would just hang. Come to find out, about every 2 seconds it was creating a 160MB dump file in C:\Windows\System32\%LOCALAPPDATA%\CrashDumps. After debugging one of those, I could see the first error was when it tried to start cmd.exe on the caching stuff in my worker role and it said CMD cannot be run on a network share, so it would default to windows/system32 or something.
That's when I found this handy dandy 7 year old MS KB article: http://support.microsoft.com/kb/156276 When I added DisableUNCCheck REG_DWORD
and set the value to 0 x 1 (Hex)
under the registry path HKEY_CURRENT_USER\Software\Microsoft\Command Processor
everything started up just like a champ. Hopefully this helps someone else.
Upvotes: 1
Reputation: 2116
Do you mean as long as you check the CheckBox
to enable caching, this error occurs? This should not happen... It works fine on my machine.
Are you creating a new project or upgrading an existing project? Try to create a new project.
Also check the following logs:
Attached files:
C:\Users\anan\AppData\Local\Temp\WEREA8F.tmp.WERInternalMetadata.xml
These files may be available here:
C:\Users\anan\AppData\Local\Microsoft\Windows\WER\ReportArchive\AppCrash_cacheinstaller.e_1fbc3b72afb6acf93335ca8611850d289906c25_2ddaf529
Upvotes: 0
Reputation: 36
I had the same issue. To do with an AppFabric Server dll conflict - check whether you have AppFabric Server installed and either deinstall the cache or remove the cache assemblies from the GAC. I removed and the emulated cache works fine.
I have some information which may be helpful on our blog:
http://blog.elastacloud.com/2012/06/09/using-the-windows-azure-cache-preview-with-sdk-1-7/
Upvotes: 2
Reputation: 11
Missing method probably means that the assembly loaded doesn't have the method in there. Can you make sure that you've the proper assembly being added to your project ?
Ensure that you don't have Windows AppFabric Server installed in the machine as well, as it'll GAC the caching dll which will get picked up during runtime
Upvotes: 1