1
Vote

Issues Installing the Solution

description

When I run the CRMInstaller wizard and get to the Azure Auth Step the authentication fails. I login the first time, using my ADFS creds tied to Dynamics and my Azure Subscription, then the login window pops up a 2nd time and after logging in that time I get an error message.

The error in the log shows:
2016-12-16 06:17:58 CrmInstaller.exe 1136-7 [INFO ]: CRM connection established successfully.
2016-12-16 06:18:42 CrmInstaller.exe 1136-1 [ERROR]: An error occurred.One or more errors occurred. at System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions)
at System.Threading.Tasks.Task1.GetResultCore(Boolean waitCompletionNotification)
at System.Threading.Tasks.Task
1.get_Result()
at AzureModelInterfaces.AzureModel.Authenticate() in C:\a\1\s\Common\AzureModelInterfaces\AzureModel.cs:line 76
at CrmInstaller.CrmDetails.BackgroundActivityWorkerTD_DoWork(Object sender, DoWorkEventArgs e) in C:\a\1\s\OpportunityScoring\Installer\Installer\SFDCDetails.xaml.cs:line 217
at System.ComponentModel.BackgroundWorker.OnDoWork(DoWorkEventArgs e)
at System.ComponentModel.BackgroundWorker.WorkerThreadStart(Object argument)

file attachments

comments

jeffsaremi wrote Dec 16, 2016 at 3:51 PM

Hi jwinchell
sorry to hear about your issues. Are you able to login to Azure (not CRM) using a separate browser session (http://portal.azure.com)? If so does Azure show you a valid Subscription? Could you create say an Azure Storage Account to see if you have enough credits to create resources?

jwinchell wrote Dec 16, 2016 at 8:00 PM

Hi Jeff,

I am able to login and have numerous subscriptions under that account. I've got a few other ML sites, a couple SQL DB's & VM's., and unfortunately I'm getting bills from MSFT so it must be working :)

It is my own Azure subscription linked to my AD Creds, which are the same creds I use for CRM. I am a Sys Admin in Dynamics. It is also a Pay as You go account. would it be trying to connect to a Organization Level Azure account instead?

Jeremy

jeffsaremi wrote Dec 16, 2016 at 8:22 PM

Ok. thanks Jeremy
I will first have to find out what the actual error was caused by the Authentication
I will be preparing a developer build which has more error logging to first isolate that. Then we'll worry about how to get passed the error.
Please contact me using jesaremi@microsoft.com
thanks
JEFF

jeffsaremi wrote Dec 16, 2016 at 8:47 PM

Pls run this utility that i uploaded:
https://opportunity.codeplex.com/downloads/get/1624614
It should prompt you with the Azure login window. If you see any errors at the bottom right corner of the screen let us know.
Here's how you run it after unzipping it to some folder:
CD extraction_folder
AzureAuthenticate.exe
...
Authentication successful: TokenType=Bearer, Expires on=12/16/2016 10:40:17 PM +00:00, TenantId=72xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxdb47, UserInfo=jesaremi@microsoft.com

jeffsaremi wrote Dec 19, 2016 at 9:51 PM

Hi Jeremy
Just checking to see if you had a chance trying out the utility I gave you so we could find out more about the authentication issues which didn't show up in the installer's log file. thanks

jwinchell wrote Dec 20, 2016 at 12:04 PM

Hi Jeff,

Sorry for the delay, I'm going to download it now and give it a shot.

Jeremy

jwinchell wrote Dec 20, 2016 at 12:12 PM

Jeff,

I ran the utility and get the below error. I'm assuming it's either an Azure AD issue or it is trying to access the Organization Level Subscriptions.


Unhandled Exception: System.AggregateException: One or more errors occurred. ---> Microsoft.IdentityModel.Clients.ActiveDirectory.AdalServiceException: AADSTS50000: There was an error issuing a token. AADSTS65005: The application needs access to a service that your organization Avtex Solutions LLC has not subscribed to. Please contact your Administrator to review the configuration of your service subscriptions.
Trace ID: e8746b39-33c6-4a4c-8608-906613fe73a9
Correlation ID: 14618bd8-b58e-4301-a269-510ff22cb600
Timestamp: 2016-12-20 13:07:46Z
at Microsoft.IdentityModel.Clients.ActiveDirectory.AcquireTokenInteractiveHandler.VerifyAuthorizationResult()
at Microsoft.IdentityModel.Clients.ActiveDirectory.AcquireTokenInteractiveHandler.<PreTokenRequest>d__8.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)
at Microsoft.IdentityModel.Clients.ActiveDirectory.AcquireTokenHandlerBase.<RunAsync>d__55.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.IdentityModel.Clients.ActiveDirectory.AuthenticationContext.<AcquireTokenCommonAsync>d__54.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.IdentityModel.Clients.ActiveDirectory.AuthenticationContext.<AcquireTokenAsync>d__45.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.Azure.IdentityExtensions.UserAuthenticator.<AuthenticateAnew>d__16.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.Azure.IdentityExtensions.UserAuthenticator.<Authenticate>d__15.MoveNext()
--- End of inner exception stack trace ---
at System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions)
at System.Threading.Tasks.Task1.GetResultCore(Boolean waitCompletionNotification)
at System.Threading.Tasks.Task
1.get_Result()
at AzureAuthenticate.Program.Main(String[] args) in D:\Projects\AzureAuthenticate\AzureAuthenticate\Program.cs:line 16

Thanks,

Jeremy

jeffsaremi wrote Dec 20, 2016 at 4:19 PM

Ok Thanks a lot Jeremy.
Let me investigate this error

jeffsaremi wrote Dec 21, 2016 at 5:33 AM

Jeremy,
Please download and try to install Release 1.2.4 and let me know of the success of failure of the install.
thanks
Jeff

jwinchell wrote Jan 9 at 10:20 PM

Jeff,

I did download v 1.2.4 and got a little bit farther. It threw an exception about the Azure Storage Account name.

The log is attached.

Jeremy

jwinchell wrote Jan 9 at 10:21 PM

Just in case the file didn't upload properly, here is the error message:

2017-01-03 04:22:58 CrmInstaller.exe 16812-7 [INFO ]: CRM connection established successfully.
2017-01-03 04:24:03 CrmInstaller.exe 16812-7 [INFO ]: Enabled subscriptions have been populated to the list box
2017-01-03 04:24:57 CrmInstaller.exe 16812-12 [INFO ]: CRM connection established successfully.
2017-01-03 04:24:57 CrmInstaller.exe 16812-12 [INFO ]: Enabled subscriptions have been populated to the list box
2017-01-03 04:30:27 CrmInstaller.exe 16812-20 [INFO ]: Resource group :avtex.comcisrsg has been successfully deployed.
2017-01-03 04:30:28 CrmInstaller.exe 16812-12 [ERROR]: avtex.ccis6ulnk56sstg is not a valid storage account name. Storage account name must be between 3 and 24 characters in length and use numbers and lower-case letters only.
Microsoft.Rest.Azure.CloudException: avtex.ccis6ulnk56sstg is not a valid storage account name. Storage account name must be between 3 and 24 characters in length and use numbers and lower-case letters only.
at Microsoft.Azure.Management.Storage.StorageAccountsOperations.<BeginCreateWithHttpMessagesAsync>d__7.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.Azure.Management.Storage.StorageAccountsOperations.<CreateWithHttpMessagesAsync>d__6.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.Azure.Management.Storage.StorageAccountsOperationsExtensions.<CreateAsync>d__3.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.Azure.ManagementExtensions.StorageOps.<NewStorageAccountAsync>d__16.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.Azure.ManagementExtensions.StorageOps.<NewStorageAccountAsync>d__12.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)
at AzureModelInterfaces.AzureModel.<AzureInstallation>d__31.MoveNext() in C:\a\1\s\Common\AzureModelInterfaces\AzureModel.cs:line 158
2017-01-03 04:30:28 CrmInstaller.exe 16812-1 [ERROR]: avtex.ccis6ulnk56sstg is not a valid storage account name. Storage account name must be between 3 and 24 characters in length and use numbers and lower-case letters only.

Jeremy

msharath wrote Jan 10 at 5:29 PM

Hi Jeremy,

This error is because the azure storage account does not allow dots (.) in it and we were extracting out the first 7 characters of the tenant (which ended up with a dot in your case).
I will have an update for this shortly (later today or tomorrow).

thanks,
Sharath.

jwinchell wrote Jan 30 at 10:59 PM

Sharath,

No rush, just curious whether or not you've had a chance to dig into this.

Thanks,

Jeremy

jwinchell wrote Apr 7 at 2:42 AM

Sharath,

Any luck on handling Azure account names < 7 characters? My account is still failing because the Azure account name is only 5 characters so the solution adds the .comxxxx.

Thanks,

Jeremy

msharath wrote Apr 13 at 9:05 PM

Hi Jeremy,

Please try out Release 1.2.6 which should have the fix for this issue.

-Sharath.