'CreateInstanceLic is failing on Windows Server 2016 but not on Windows Server 2019

I have a console application that crashes on Windows Server 2016 at the CreateInstanceLic() API. But the same application is running fine on Windows Server 2019.



Solution 1:[1]

My first guess would be that you have a valid license for the Windows Server 2019 and not for the Windows Server 2016. The failing call tries to aquire a valid license and this fails for 2016 but not for 2019.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 KimKulling