Azure new VM account disabled by default (Custom Image) - azure

I'm having trouble when creating a VM in Microsoft Azure using a custom windows image.
Issue
When connecting to the newly spawned VM using the credentials entered in Azure Portal, I get the following message :
The user account is currently disabled and cannot be used.
Running a Get-LocalAccount script using the "Run Command" menu of the Azure Portal I get the following output:
Name Enabled Description
---- ------- -----------
DefaultAccount False A user account managed by the system.
Guest False Built-in account for guest access to the computer/domain
myusername False Built-in account for administering the computer/domain
WDAGUtilityAccount False A user account managed and used by the system for Windows Defender Application
Workaround
If I use procedure from Azure VM connection error - The user account is currently disabled and cannot be used, I'm able to unlock the user and connect to the VM via RDP.
I also try creating a new user prior to sysprepping the VM so the local admin account is renamed and disable by Azure during VM creation but the user account created remain enabled.
Image Info
OS: Windows 10 LTSC 2019
Source: Custom deployed image used by my company. It was installed with an ISO on local HyperV machine, uploaded to Azure and SysPrep from a managed disk.
WindowsAzureVmAgent version 2.7.41491.949_191001-1418 installed on the VM prior to running sysprep.
Step Taken
Re-enabling the account and running Sysprep again to create a new snapshot does not fix the issue
Renaming the local administrator account prior to Sysprep the device does not have any effect.
Checked the local policies and nothing look unusual.

Found the solution with the help of Microsoft Azure support engineer. For a VM uploaded from on premise source, you would need to add a SetupComplete2.cmd and EnableLocalAdminAccount.ps1 in C:/Windows/OEM to unlock the user account automatically upon VM creation. Strangely enough this does not appear on anywhere on Microsoft's guideline on how to migrate a on-prem VM to Azure, but the official windows image from the Marketplace do have those 2 files that are run after Sysprep.
This blog article was also very useful and points towards the creation of a SetupComplete2.cmd https://matt.kotsenas.com/posts/azure-setupcomplete2

Related

MDE.Windows Azure VM extension provisioning failed

We have recently migrated Windows server 2016 from Onprem to Azure Cloud. After that i notice that the "MDE.Windows" extension shows "Provisioning Failed" message. And below is the error message. Can someone help me on how to fix this?
[2022-10-18 13:19:05Z][Error] Failed to configure Microsoft Defender for Endpoint: Onboarding to MDE via Microsoft Defender for Cloud for this operating system is done using Microsoft Monitor Agent. If you would like to install the new MDE Unified Solution/Agent, please enable the Unified Solution setting in Microsoft Defender for Cloud (vNextEnabled parameter is not 'true')\r\n
I tried to reproduce the same issue in my environment and got the below results
I have enabled the defender cloud
When enabling the defender for servers plan 1 or plan 2 and configuring the defender for end point integration
The end point defender is automatically provisioned for all supported machines
If we want we can change the sever plan also
we have to enable the defender for endpoint integration
by clicking on settings => integrations
I have enabled the auto provisioning when using defender for cloud
I have selected the appropriate Virtual Machine
We have to monitor the installation via azure machine extension page
Open the specific VM => Open the extension&Application => open the MDE.windows for related information
While clicking on the MDE.Windows extensions we can see the state is succeeded
NOTE:
When the extension is failed we have to check the all below the pre requisites are correctly configured or not
1). Defender not running inactive mode for 2019
2). Defender server role is not installed for server 2016
3). connect pre requisites updates not installed
4). Defender disabled via registry key setting

Service Bus existing farm join issue in windows 10 (home premium)

I am facing issue while joining an existing farm using service bus configuration manager. This what happening at Configuration Process window:
Starting
Validating input and configuration parameters.
Installing auto-generated certificate.
Granting 'Log on as Service' privilege to the run as account.
Windows Fabric configuration started.
Group WindowsFabricAdministrators not found.
I have service bus1.1 and the Windows 10 home premium. I have gone through lots of blogs to add the Fabric host service account to other groups but in home premium version of windows 10, I could not see the Users and Groups.
Anyone have any idea , kindly suggest what I am missing and could do to make it work.

Basic Azure Storage getting started. Create Scheduled File back up

This is probably a basic question but all I am looking for in Azure is the ability to back up files on my Windows Server at a scheduled time. MS SQL, MySQL and Web Site Files.
I have created a Trial account and a Storage plan but need a pointer to which section of the Dashboard I should be visiting - it isn't immediately apparent!
I assume you are asking about backing up your Windows server running as a VM instance on Azure.
Below is the latest Azure VM backup guide from Microsoft.
Hope it helps!
Azure virtual machine back up

Are Azure VMs or their user accounts locked after too much activity/uploads on MSDN Premium subscription accounts?

I have created an Azure VM for the purpose of testing a new installation process for my software. The VM is using Windows 10 Preview.
Yesterday I uploaded an ISO file which contained our software plus installers for SQL Server Express (various editions). (About 1.8 gb)
I ran our custom setup program which installs SQL express, restores a new user database, adds firewall exceptions etc. etc.
This morning I cannot RDP into that VM. The connection is made, but when I attempt to login, I am simply returned to the Windows Security Dialog, with the message "Your credentials did not work..."
I know I am typing the password correctly, I have double checked things like typos in the user name and password, Caps Lock is not on ;-) and so on.
This happened to a VM I had set up last week too, after a similar test and after attempting various options including resetting credentials using Powershell (found here) I accepted that I must have forgotten the password or done something wrong, so I started again.
Now the same things has happened I am wondering if that level of activity (uploading 1.8gb then running a setup which retrieved and installed .Net runtime 3.5) on an Azure VM that runs under an MSDN Premium subscription Azure account, caused the user account to be locked out for a period of time - have I hit some limit of uploads to that machine or activity or some other limit I'm not aware of?

Cannot enable Azure Connect in Management Portal

I am new to Windows Azure platform and I am trying to set up Azure Load test. I have already set up Storage account, hosted service and Virtual Network. However, I cannot find Connect tab under Networks -> Virtual Network. The prerequites i.e. Windows Azure SDK and Windows Azure Tools for VS 2010 have been installed. My local machine OS is 64 bit Windows 7.
You must use the previous Management Portal to manage Connect VPNs. The new Management Portal cannot yet manage them. It's under "Virtual Network" tab in there. Also, this CTP must be enabled for your subscription(s) or it may not be present in the portal.
First of all Azure Connect is still in Preview and there is no significant improvements in this component for over a years so I would suggest not to use it.
If you really want to see Windows Azure Connect, it is only available in older portal so please go to older portal to see it.

Resources