Can not create default Keyset when using AXBuild

We have a large deploy with a customer this week which is a very bad time for AXBuild to stop working… really bad time. And ofcourse that is what happened Smile (screw you Murphy). There are of course other ways to to a compile in AX byt doing it from within AX is really slow so AXBuild is much nicer and faster.

The problem was that when I launched AXBuild the process kept crashing with this error:

clip_image002

I also got the following events in Event viewer:

Error 14.11.2016 17:49:05 Dynamics Server 01 110 None
Object Server 01:
Can not create default Keyset. Error code -2146893809.

Error 14.11.2016 17:49:05 Dynamics Server 01 110 None
Object Server 01:
The license information can not be decoded.

Error 14.11.2016 17:49:06 .NET Runtime 1026 None
Application: Ax32Serv.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception
Exception Info: System.Runtime.InteropServices.SEHException
Stack:
at <Module>.wmainCRTStartup()
at <Module>.wmainCRTStartup()

When doing research we found that this is most likely a permissions issue and I got somen hints on what to check:

  • Are you running elevated: Check
  • Are you local admin on the AOS computer: Check
  • Is the AOS user local admin on the AOS computer: Check
  • Check AOS user permissions on the AX database and modelstore: Check

I was not able to find the solution so I resorted to Microsoft Support and they sait the same thing… it is a permission issue. So finally I fired up ProcessMonitor (which I don’t do often enough) and the it was after some looking around and filtering. I filtered out everything except the Ax32Serv.exe process and I also removed the SUCCESS lines.

The issue was that my user (the one doing the the compiling) got access denied on a file in the folder:

C:\ProgramData\Microsoft\Crypto\RSA\MachineKeys

I changed the permission on the file and Presto! (or as one of my colleugues said – I am going to get a Cappuchino with cinnamon)

The compile is running and things are good

/Johan

Comments

One response to “Can not create default Keyset when using AXBuild”

  1. Mark N
    Mark N

    Thanks for sharing. Spot on.

Leave a Reply

To respond on your own website, enter the URL of your response which should contain a link to this post's permalink URL. Your response will then appear (possibly after moderation) on this page. Want to update or remove your response? Update or delete your post and re-enter your post's URL again. (Find out more about Webmentions.)