Note -If you have a Dynamics 365 for Operations VM then follow below link
(“Provisioning the administrator” user section)
to set up and be able to login – https://docs.microsoft.com/en-us/dynamics365/unified-operations/dev-itpro/dev-tools/access-instances
If you are using AX 2012 please continue reading-
When you have just installed AX or got a backup of the AX database from someone, you may not be able to log on to Microsoft Dynamics AX 2012. A following error message may be displayed
The issue is that you have not been configured as a user in the AX database.
Resolution: The solution has following two steps
1. In AX 2012 Extract your SID as follows-(Credit to Rudhra Kumar- https://community.dynamics.com/ax/f/33/t/125845)
To get SID for the current logged in domain user, please type the following in your command prompt–> C:\> whoami /user
To get SID for all domain users, please type the following in your command prompt–>wmic useraccount get name,sid whoami /user
2. Copy the SID into your AX database in SQL Management Studio in the table dbo.USERINFO, also change the Network Domain and NetworkAlias as per your credentials.