1
Vote

All attempted actions using the posted binary result in unhandled exception

description

Below is the stack trace generated by invoking the "Role Info" button. This is from a W2K8 R2 Enterprise VM Role
 
If anyone is interested to investigate further I can provide additional environmental options on request
 
See the end of this message for details on invoking
just-in-time (JIT) debugging instead of this dialog box.
 
************** Exception Text **************
System.UnauthorizedAccessException: Attempted to perform an unauthorized operation.
at Microsoft.WindowsAzure.ServiceRuntime.RoleEnvironment.Initialize(TimeSpan timeout)
at Microsoft.WindowsAzure.ServiceRuntime.RoleEnvironment.get_IsAvailable()
at VHDMountAzureVM.FrmMain.validateRoleEnvironment()
at VHDMountAzureVM.FrmMain.tsMainRoleInfo_Click(Object sender, EventArgs e)
at System.Windows.Forms.ToolStripItem.RaiseEvent(Object key, EventArgs e)
at System.Windows.Forms.ToolStripItem.HandleClick(EventArgs e)
at System.Windows.Forms.ToolStripItem.HandleMouseUp(MouseEventArgs e)
at System.Windows.Forms.ToolStrip.OnMouseUp(MouseEventArgs mea)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ToolStrip.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
 
 
************** Loaded Assemblies **************
mscorlib
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.5448 (Win7SP1GDR.050727-5400)

CodeBase: file:///C:/Windows/Microsoft.NET/Framework64/v2.0.50727/mscorlib.dll

VHDMountAzureVM
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0

CodeBase: file:///C:/Users/Arthur/Desktop/VHDMountAzureVM.exe

System.Windows.Forms
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.5446 (Win7SP1GDR.050727-5400)

CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Windows.Forms/2.0.0.0__b77a5c561934e089/System.Windows.Forms.dll

System
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.5453 (Win7SP1GDR.050727-5400)

CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System/2.0.0.0__b77a5c561934e089/System.dll

System.Drawing
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.5420 (Win7SP1.050727-5400)

CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Drawing/2.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll

System.Configuration
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.5420 (Win7SP1.050727-5400)

CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Configuration/2.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll

System.Xml
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.5420 (Win7SP1.050727-5400)

CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Xml/2.0.0.0__b77a5c561934e089/System.Xml.dll

Microsoft.WindowsAzure.ServiceRuntime
Assembly Version: 1.0.0.0
Win32 Version: 6.0.6002.18314

CodeBase: file:///C:/Windows/assembly/GAC_MSIL/Microsoft.WindowsAzure.ServiceRuntime/1.0.0.0__31bf3856ad364e35/Microsoft.WindowsAzure.ServiceRuntime.dll

Microsoft.WindowsAzure.IntegrationComponents.Agent
Assembly Version: 1.6.0.0
Win32 Version: 6.0.6002.18314

CodeBase: file:///C:/Windows/assembly/GAC_MSIL/Microsoft.WindowsAzure.IntegrationComponents.Agent/1.6.0.0__31bf3856ad364e35/Microsoft.WindowsAzure.IntegrationComponents.Agent.dll

System.Xml.Linq
Assembly Version: 3.5.0.0
Win32 Version: 3.5.30729.5420 built by: Win7SP1

CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Xml.Linq/3.5.0.0__b77a5c561934e089/System.Xml.Linq.dll

System.Core
Assembly Version: 3.5.0.0
Win32 Version: 3.5.30729.5420 built by: Win7SP1

CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Core/3.5.0.0__b77a5c561934e089/System.Core.dll

System.EnterpriseServices
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.5420 (Win7SP1.050727-5400)

CodeBase: file:///C:/Windows/assembly/GAC_64/System.EnterpriseServices/2.0.0.0__b03f5f7f11d50a3a/System.EnterpriseServices.dll

 
************** JIT Debugging **************
To enable just-in-time (JIT) debugging, the .config file for this
application or computer (machine.config) must have the
jitDebugging value set in the system.windows.forms section.
The application must also be compiled with debugging
enabled.
 
For example:
 
<configuration>
<system.windows.forms jitDebugging="true" />
</configuration>
 
When JIT debugging is enabled, any unhandled exception
will be sent to the JIT debugger registered on the computer
rather than be handled by this dialog box.

comments

ewann wrote Jun 10, 2012 at 4:29 AM

True to form, posting made me figure out the solution:

Application needs to be run with elevated permissions - Runas administrator solved the above for me

wrote Feb 13, 2013 at 9:27 PM