Windows VM password reset under Windows Azure

Source: Internet
Author: User

Windows VM password reset under Windows Azure

Speaking of the password problem, I believe that the administrator is a headache, especially as a large enterprise administrator, the use of server password is very troublesome, why so to say, because the information security requirements of large enterprises, require user password 45 days change, of course, do not change the words that means expired, can not be used, There is also a situation that is the user's password, for not in the company office, but the external users do not often access the occasional access to the company's information system user password is indeed a problem, for our company, the problem is more, often let the assistant email to the administrator to reset their password, This gives the administrator a great deal of trouble, later, in order to completely solve the problem, it has done a verification system, binding the user's private information to allow users to reset their passwords, which reduces the administrator's daily work pressure. And today, we're going to focus on creating a Windows VM under Windows Azure if the password forgets how to reset it, because after creating the VM on Windows Azure it's impossible to crack the password by Consloe to mount the cracked password image. Of course, Microsoft will definitely take this issue into account, just use PowerShell to reset the password, see below:

There are two ways to forget a password, one is to know the account password to reset, the other is to not know the password that needs to be reset. For example, the last administrator after the creation of the work has not handed over and left, the current administrator does not know the password, do not know to reset the password, so Windows Azure uses the overridden method to complete the password operation from the reset.

First, it is clear that the Windows Azure poral page does not have password-related reset options, so it needs to be done with Windows Azure PowerShell, and again we don't have more information about how to download Windows Azure Pwoershell and install. We've already installed it in advance, and we've covered the previous article on how to download and install Windows Azure PowerShell, which you can refer to in the previous article.

As we all know, Windows 8 systems are installed with Windows PowerShell components by default and only need to enable the service. Specific also not more introduced. My experiment is the Windows 2008R2 operating system, so the system is also installed by default, we downloaded Windows Azure Powershel, that Windows Azure Poershell with the system comes with Windows What is the difference between PowerShell and the biggest difference is there is no Azure-related service module

Difference: The installation of road strength is different

650) this.width=650; "title=" clip_image002 "style=" border-top:0px;border-right:0px;background-image:none; border-bottom:0px;padding-top:0px;padding-left:0px;margin:0px;border-left:0px;padding-right:0px; "border=" 0 "alt = "clip_image002" src= "http://s3.51cto.com/wyfs02/M01/53/E4/wKioL1RzPibhmzw3AAFybA825Mo228.jpg" height= "279"/>

Create a Windows VM

650) this.width=650; "title=" clip_image004 "style=" border-top:0px;border-right:0px;background-image:none; border-bottom:0px;padding-top:0px;padding-left:0px;margin:0px;border-left:0px;padding-right:0px; "border=" 0 "alt = "clip_image004" src= "http://s3.51cto.com/wyfs02/M01/53/E6/wKiom1RzPaejqjY0AAEQIcGKnl4567.jpg" height= "305"/>

Fill in the information about the virtual machine

650) this.width=650; "title=" clip_image006 "style=" border-top:0px;border-right:0px;background-image:none; border-bottom:0px;padding-top:0px;padding-left:0px;margin:0px;border-left:0px;padding-right:0px; "border=" 0 "alt = "clip_image006" src= "http://s3.51cto.com/wyfs02/M02/53/E6/wKiom1RzPafB7tWyAADRnTqNWbE251.jpg" height= "310"/>

Start creating

650) this.width=650; "title=" clip_image008 "style=" border-top:0px;border-right:0px;background-image:none; border-bottom:0px;padding-top:0px;padding-left:0px;margin:0px;border-left:0px;padding-right:0px; "border=" 0 "alt = "clip_image008" src= "http://s3.51cto.com/wyfs02/M00/53/E6/wKiom1RzPafBvFpyAADAQkCjXJ0877.jpg" height= "282"/>

Once created, we will be able to log on to the Remote Desktop.

After logging in we check the user and group information, found that the system does not administrator users and permissions.

650) this.width=650; "title=" clip_image010 "style=" border-top:0px;border-right:0px;background-image:none; border-bottom:0px;padding-top:0px;padding-left:0px;margin:0px;border-left:0px;padding-right:0px; "border=" 0 "alt = "clip_image010" src= "http://s3.51cto.com/wyfs02/M01/53/E6/wKiom1RzPaeCGiZaAAEBjkGures081.jpg" height= "385"/>

Next we need to install Windows Azure PowerShell to manage:

Because the Windows Azure poral page does not have a password-related reset option, it needs to be done with Windows Azure PowerShell, and again we don't have more information on how to download Windows Azure Pwoershell and install. We've already installed it in advance, and we've covered the previous article on how to download and install Windows Azure PowerShell, which you can refer to in the previous article.

As we all know, Windows 8 systems are installed with Windows PowerShell components by default and only need to enable the service. Specific also not more introduced. My experiment is the Windows 2008R2 operating system, so the system is also installed by default, we downloaded Windows Azure Powershel, that Windows Azure Poershell with the system comes with Windows What is the difference between PowerShell, the biggest difference is there is no Azure related service module, again no more introduced, with PowerShell after we need Windows Azure subscription file, we need to access windows The portal interface for Azure is downloaded or downloaded through PowerShell.

Https://manage.windowsazure.cn/publishsettings/index?client=powershell

650) this.width=650; "title=" clip_image012 "style=" border-top:0px;border-right:0px;background-image:none; border-bottom:0px;padding-top:0px;padding-left:0px;margin:0px;border-left:0px;padding-right:0px; "border=" 0 "alt = "clip_image012" src= "http://s3.51cto.com/wyfs02/M01/53/E4/wKioL1RzPibT6xdJAAEXDjlx8vQ786.jpg" height= "340"/>

When the environment is ready, we start to work.

650) this.width=650; "title=" clip_image014 "style=" border-top:0px;border-right:0px;background-image:none; border-bottom:0px;padding-top:0px;padding-left:0px;margin:0px;border-left:0px;padding-right:0px; "border=" 0 "alt = "clip_image014" src= "http://s3.51cto.com/wyfs02/M00/53/E4/wKioL1RzPibxjVisAAD5Kwz_KWg349.jpg" height= "356"/>

To start is to import a subscription file:

Import-azurepublishsettingfile ' D:xxxxx.publishseetingfiles '

650) this.width=650; "title=" clip_image016 "style=" border-top:0px;border-right:0px;background-image:none; border-bottom:0px;padding-top:0px;padding-left:0px;margin:0px;border-left:0px;padding-right:0px; "border=" 0 "alt = "clip_image016" src= "http://s3.51cto.com/wyfs02/M01/53/E4/wKioL1RzPieDV4baAAD8KZ4egr0709.jpg" height= "353"/>

When the import is complete, all current subscription files are displayed.

650) this.width=650; "title=" clip_image018 "style=" border-top:0px;border-right:0px;background-image:none; border-bottom:0px;padding-top:0px;padding-left:0px;margin:0px;border-left:0px;padding-right:0px; "border=" 0 "alt = "clip_image018" src= "http://s3.51cto.com/wyfs02/M02/53/E4/wKioL1RzPieAXeAnAAFpUKtsQXI016.jpg" height= "349"/>

Because I have multiple subscriptions in my environment, we need to set a default subscription

650) this.width=650; "title=" clip_image020 "style=" border-top:0px;border-right:0px;background-image:none; border-bottom:0px;padding-top:0px;padding-left:0px;margin:0px;border-left:0px;padding-right:0px; "border=" 0 "alt = "clip_image020" src= "http://s3.51cto.com/wyfs02/M00/53/E4/wKioL1RzPiexZJE9AAGKWTqllBI917.jpg" height= "357"/>

Check whether the default Azure account in Azure PowerShell is the account you want to operate on:

Input command: Get-azuresubscription–default, check out the results will appear in the subscription ID, see if this sub ID is your own Azure management platform on the subscription ID.

If the sub ID is different, you will need to reset the default account (it should be the same if you are doing it for the first time). To change a command:

Select-select-azuresubscription-subscriptionname "Add account name"-default

650) this.width=650; "title=" clip_image022 "style=" border-top:0px;border-right:0px;background-image:none; border-bottom:0px;padding-top:0px;padding-left:0px;margin:0px;border-left:0px;padding-right:0px; "border=" 0 "alt = "clip_image022" src= "http://s3.51cto.com/wyfs02/M02/53/E4/wKioL1RzPieSAd9nAACErBLGXV8272.jpg" height= "the"/>

Note: If there are multiple subscription IDs under a subscription file, we can also choose to modify the specified subscription ID as the default

650) this.width=650; "title=" clip_image024 "style=" border-top:0px;border-right:0px;background-image:none; border-bottom:0px;padding-top:0px;padding-left:0px;margin:0px;border-left:0px;padding-right:0px; "border=" 0 "alt = "clip_image024" src= "http://s3.51cto.com/wyfs02/M01/53/E4/wKioL1RzPiexsmOUAACafIwh1hw665.jpg" height= "118"/>

After modifying, we enter the command

Get-azurevm

(Check your virtual machine name and cloud service name)

650) this.width=650; "title=" clip_image026 "style=" border-top:0px;border-right:0px;background-image:none; border-bottom:0px;padding-top:0px;padding-left:0px;margin:0px;border-left:0px;padding-right:0px; "border=" 0 "alt = "clip_image026" src= "http://s3.51cto.com/wyfs02/M02/53/E4/wKioL1RzPifz46ALAACzL-bhvGA595.jpg" height= "277"/>

Input command

$VM 1 = get-azurevm-servicename "xxxx"-name "mxxx"

Define a variable vm1, and then view information about the current service

650) this.width=650; "title=" clip_image028 "style=" border-top:0px;border-right:0px;background-image:none; border-bottom:0px;padding-top:0px;padding-left:0px;margin:0px;border-left:0px;padding-right:0px; "border=" 0 "alt = "clip_image028" src= "http://s3.51cto.com/wyfs02/M00/53/E4/wKioL1RzPifD_jl-AACUqCL6_Rc530.jpg" height= "216"/>

Input command

$VM 1. Vm. Provisionguestagent

(see if the output is ' True ')

If the virtual machine installs the agent, the display of the demerit is true, if the agent is not installed, the display false

Generic virtual machines are installed by default when you create a new agent

650) this.width=650; "title=" clip_image030 "style=" border-top:0px;border-right:0px;background-image:none; border-bottom:0px;padding-top:0px;padding-left:0px;margin:0px;border-left:0px;padding-right:0px; "border=" 0 "alt = "clip_image030" src= "http://s3.51cto.com/wyfs02/M01/53/E4/wKioL1RzPifTQiCSAACfCp7pPZc277.jpg" height= "265"/>

If it is ' True ' then you can do the following to modify the virtual machine's user name and password:

Enter the command:

SET-AZUREVMACCESSEXTENSION-VM $VM 1–username "Adminaccountname" –password "NewPassword" | Update-azurevm

Note: If username is a previously created user, it will reset the new password directly, and if you forget the previously created user name, rename the previous username and set the new password again.

My previous system account is Gavin, if I forget the previous user is Gavin, I enter the new user and the new password will overwrite my previous user and password.

650) this.width=650; "title=" clip_image032 "style=" border-top:0px;border-right:0px;background-image:none; border-bottom:0px;padding-top:0px;padding-left:0px;margin:0px;border-left:0px;padding-right:0px; "border=" 0 "alt = "clip_image032" src= "http://s3.51cto.com/wyfs02/M02/53/E4/wKioL1RzPifzHOxcAAD-9tgACXw495.jpg" height= "275"/>

After the operation is completed, we log in to the server to view:

650) this.width=650; "title=" clip_image034 "style=" border-top:0px;border-right:0px;background-image:none; border-bottom:0px;padding-top:0px;padding-left:0px;margin:0px;border-left:0px;padding-right:0px; "border=" 0 "alt = "clip_image034" src= "http://s3.51cto.com/wyfs02/M00/53/E4/wKioL1RzPijjP0RKAAEW_gEcWCA855.jpg" height= "396"/>

650) this.width=650; "title=" clip_image036 "style=" border-top:0px;border-right:0px;background-image:none; border-bottom:0px;padding-top:0px;padding-left:0px;margin:0px;border-left:0px;padding-right:0px; "border=" 0 "alt = "clip_image036" src= "http://s3.51cto.com/wyfs02/M01/53/E4/wKioL1RzPiiQGTaKAAEMwdN2NgU978.jpg" height= "352"/>

The operation is complete.

The above separately executed code we can write to a. pst1 file, provided the confirmation condition is met, and then the file is executed:

$VM 1 = get-azurevm-servicename "miyaw2008"-name "miyaw2008" SET-AZUREVMACCESSEXTENSION-VM $VM 1–username " Adminaccountname "–password" NewPassword "| Update-azurevm

650) this.width=650; "title=" clip_image038 "style=" border-top:0px;border-right:0px;background-image:none; border-bottom:0px;padding-top:0px;padding-left:0px;border-left:0px;padding-right:0px, "border=" 0 "alt=" clip_ image038 "src=" http://s3.51cto.com/wyfs02/M02/53/E4/wKioL1RzPiigXQS6AABQEK_zC9c384.jpg "height=" 118 "/>

This article is from the "Gao Wenrong" blog, make sure to keep this source http://gaowenlong.blog.51cto.com/451336/1582175

Windows VM password reset under Windows Azure

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.