Resetting a user password on a Windows Server virtual machine
To reset a user password on a Windows Server virtual machine using Nebius Israel tools, you require:
- Password reset agent. The agent is part of standard Windows Server images. If you are using a custom image, follow the instructions to install the password reset agent.
-
The
compute.admin
service role, theeditor
primitive role, or any other role that inherits all permissions of these two. For more information about roles, see Access management in Compute Cloud. -
Running VM (with the
RUNNING
status).
To reset a password:
-
Select the folder the VM belongs to.
-
Select Compute Cloud.
-
Select the VM.
-
Click Reset password.
Note
In the window that opens, if you see a message that the password reset agent is not running on the VM, make sure it is installed and review its runtime logs. For more information, see Verifying password reset operation on a Windows Server virtual machine.
-
Specify the Username to reset the password for. If there is no user with that name on the VM, this user will be created with administrator access.
-
Click Generate password.
-
Save the New password. It will become unavailable once you close the window.
-
Run PowerShell as an administrator.
-
Install the password reset module (once):
-
Install the CLI and configure it to run commands under a user or a service account with the required role (see above).
-
Run this command:
Install-Module -Name YCPasswordReset
Answer
Y
(for "Yes") to any installer questions such as those regarding the NuGet package manager and repositories.
-
-
Run this command:
Reset-YCUserPassword -InstanceName <VM name> -Username <VM username>
Note
If a command takes too long to run, stop it using the Ctrl + C key combination. After you do this, verify that the password reset agent has been installed. For more information, see Verifying password reset operation on a Windows Server virtual machine.
If the VM does not have the username specified in the
-Username
parameter, the user will be created with administrator access. -
Save the generated password. It will become unavailable once you close the window.