Unable to GetPassword on AWS EC2 Launched from Windows Server 2016 Custom AMI
We found out that our custom AMI doesn't allow us to enable GetPassword from AWS console on any EC2 launched from it. After reading and some trial and error, we found out that InitializeInstance.ps1 has to be enabled for the next boot. https://docs.aws.amazon.com/AWSEC2/latest/WindowsGuide/ec2launch.html#ec2launch-inittasks To be complete, LaunchConfig.json has to have adminPasswordtype set to Random (default). Then, run the following PowerShell command: C:\ProgramData\Amazon\EC2-Windows\Launch\Scripts\InitializeInstance.ps1 -Schedule