Cloud drive can currently use only HTTP storage connection string


ISSUE:Azure worker role instance recycling. Trying to mount Azure cloud drive on role startup.

Event logs showed the following error:

Application: WaWokerHost.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: Microsoft.WindowsAzure.StorageClient.CloudDriveException

Stack:
   at Microsoft.WindowsAzure.CloudDrive.Interop.InteropCloudDrive.Mount(String url, SignatureCallBack sign, String mount, Int32 cacheSize, UInt32 flags)
   at Microsoft.WindowsAzure.StorageClient.CloudDrive.MountAt(String location, Int32 cacheSize, DriveMountOptions options)
   --- End of inner exception stack trace ---
   at Microsoft.WindowsAzure.StorageClient.CloudDrive.MountAt(String location, Int32 cacheSize, DriveMountOptions options)
   at RavenDbWorkerRole.WorkerRole.OnStart()
   at Microsoft.WindowsAzure.ServiceRuntime.RoleEnvironment.InitializeRoleInternal(RoleType roleTypeEnum)
   at Microsoft.WindowsAzure.ServiceRuntime.Implementation.Loader.RoleRuntimeBridge.<InitializeRole>b__0()
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean ignoreSyncCtx)
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Threading.ThreadHelper.ThreadStart()
  
I attached a debugger to the worker process(WaWorkerHost). Saw the following exception:

Microsoft.WindowsAzure.StorageClient.CloudDriveException: ERROR_HTTPS_NOT_SUPPORTED ---> Microsoft.WindowsAzure.CloudDrive.Interop.InteropCloudDriveException: Exception of type 'Microsoft.WindowsAzure.CloudDrive.Interop.InteropCloudDriveException' was thrown.

This was happening because storage was using HTTPS protocol. 
When you are using cloud drive, you need to specify HTTP protocol for your storage.
   
   Role config file:  
   <Setting name="StorageAccount" value="DefaultEndpointsProtocol=http;AccountName=abcd;AccountKey=GUID" />
  
   The following article has a note where it mentions that https endpoint is not supported in mounting cloud drive.
   http://msdn.microsoft.com/en-us/library/windowsazure/microsoft.windowsazure.storageclient.clouddrive.delete.aspx
   "When defining the connection string for connecting to the storage account, you must use the HTTP protocol. The HTTPS protocol is not supported for creating a drive."
  
  
  

 

Comments (0)

Skip to main content