Failed to create a session revisited

Today I was experiencing this error again when working a new Hyper-V with imported demo data in AX 2012 R3:

Failed to create a session; confirm that the user has the proper privileges to log on to Microsoft Dynamics

In a previous post, I stated a solution for this, but today, the script in that post didn’t cut it. And the reason is that there are more partitions in it now. So I wanted to tell you a bit more on how to solve it.

The cause of the issue remains in the UserInfo table. But to show you, first start up a client in the Initial partition and open the partition form.


When we add a partition here, there is some stuff going on in the background. The AOS will also create new user entries in the UserInfo table for the ‘Admin’ and ‘guest’ users. When you modify the client config to log on to the new partition, it will work and you can run the partition initialization checklist.



But, when importing demo data using the Data Transfer Tool, partitions are imported, but the background procedure of adding the Admin and Guest users to the UserInfo table is not executed. So the real problem is that the UserInfo table does not contain the Admin and Guest records for each of the partitions. So you need to make sure that for every partition available there is a matching pair of records in the UserInfo table. (In my case I created the records and played with the recId’s, but be careful with that.)