博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
ubuntu 重置密码_从Ubuntu Live CD更改或重置Windows密码
阅读量:2512 次
发布时间:2019-05-11

本文共 8801 字,大约阅读时间需要 29 分钟。

ubuntu 重置密码

ubuntu 重置密码

If you can’t log in even after trying your twelve passwords, or you’ve inherited a computer complete with password-protected profiles, worry not – you don’t have to do a fresh install of Windows. We’ll show you how to change or reset your Windows password from a Ubuntu Live CD.

如果您尝试输入十二个密码后仍然无法登录,或者您继承了一台带有密码保护的配置文件的计算机,请不必担心-您不必全新安装Windows。 我们将向您展示如何通过Ubuntu Live CD更改或重置Windows密码。

This method works for all of the NT-based version of Windows – anything from Windows 2000 and later, basically. And yes, that includes Windows 7.

该方法适用于所有基于NT的Windows版本-基本上是Windows 2000和更高版本中的任何版本。 是的,其中包括Windows 7。

Note: If you have files on your hard disk encrypted using built-in Windows encryption, they may not be available after changing the Windows password using this method. Exercise caution if you have important encrypted files.

注意:如果您的硬盘上的文件使用内置Windows加密加密,则使用此方法更改Windows密码后,这些文件可能不可用。 如果您有重要的加密文件,请当心。

You’ll need a Ubuntu 9.10 Live CD, or a bootable Ubuntu 9.10 Flash Drive. If you don’t have one, or have forgotten how to boot from the flash drive, check out our article on .

您将需要Ubuntu 9.10 Live CD或可启动的Ubuntu 9.10闪存驱动器。 如果您没有,或者忘记了如何从闪存驱动器启动,请查看有关 。

The program that lets us manipulate Windows passwords is called chntpw. The steps to install it are different in 32-bit and 64-bit versions of Ubuntu.

让我们操作Windows密码的程序称为chntpw 。 在32位和64位版本的Ubuntu中,安装它的步骤有所不同。

Installation: 32-bit

安装:32位

Open up Synaptic Package Manager by clicking on System at the top of the screen, expanding the Administration section, and clicking on Synaptic Package Manager.

通过单击屏幕顶部的“系统”,展开“管理”部分,然后单击“ Synaptic软件包管理器”,以打开Synaptic软件包管理器。

sshot-1

chntpw is found in the universe repository. Repositories are a way for Ubuntu to group software together so that users are able to choose if they want to use only completely open source software maintained by Ubuntu developers, or branch out and use software with different licenses and maintainers.

chntpwUniverse库中找到。 信息库是Ubuntu将软件组合在一起的一种方式,因此用户可以选择只使用由Ubuntu开发人员维护的完全开源的软件,还是分支并使用具有不同许可证和维护者的软件。

To enable software from the universe repository, click on Settings > Repositories in the Synaptic window.

要从Universe存储库启用软件,请在Synaptic窗口中单击“设置”>“存储库”。

sshot-2

Add a checkmark beside the box labeled “Community-maintained Open Source software (universe)” and then click close.

在标有“社区维护的开源软件(Universe)”的框旁边添加选中标记,然后单击“关闭”。

sshot-3

When you change the repositories you are selecting software from, you have to reload the list of available software. In the main Synaptic window, click on the Reload button.

更改要从中选择软件的存储库时,必须重新加载可用软件列表。 在Synaptic主窗口中,单击Reload按钮。

sshot-4

The software lists will be downloaded.

软件列表将被下载。

sshot-5

Once downloaded, Synaptic must rebuild its search index. The label over the text field by the Search button will read “Rebuilding search index.” When it reads “Quick search,” type chntpw in the text field. The package will show up in the list.

一旦下载,Synaptic必须重建其搜索索引。 “搜索”按钮在文本字段上方的标签将显示为“重建搜索索引”。 当它显示“快速搜索”时,在文本字段中键入chntpw 。 该软件包将显示在列表中。

sshot-6

Click on the checkbox near the chntpw name. Click on Mark for Installation.

单击chntpw名称附近的复选框。 单击标记为安装。

sshot-7

chntpw won’t actually be installed until you apply the changes you’ve made, so click on the Apply button in the Synaptic window now.

除非您应用所做的更改,否则实际上不会安装chntpw ,因此现在单击Synaptic窗口中的Apply按钮。

sshot-8

You will be prompted to accept the changes. Click Apply.

系统将提示您接受更改。 单击应用。

sshot-9

The changes should be applied quickly. When they’re done, click Close.

所做的更改应尽快应用。 完成后,单击“关闭”。

sshot-10

chntpw is now installed! You can close Synaptic Package Manager. Skip to the section titled Using chntpw to reset your password.

chntpw现在已安装! 您可以关闭Synaptic软件包管理器。 跳至标题为“ 使用chntpw重置密码”的部分

Installation: 64-bit

安装:64位

The version of chntpw available in Ubuntu’s universe repository will not work properly on a 64-bit machine. Fortunately, a patched version exists in Debian’s Unstable branch, so let’s download it from there and install it manually.

Ubuntu的Universe存储库中可用的chntpw版本在64位计算机上无法正常工作。 幸运的是,Debian的Unstable分支中存在一个补丁版本,因此让我们从那里下载并手动安装。

Open Firefox. Whether it’s your preferred browser or not, it’s very readily accessible in the Ubuntu Live CD environment, so it will be the easiest to use. There’s a shortcut to Firefox in the top panel.

打开Firefox。 不管它是否是您的首选浏览器,都可以在Ubuntu Live CD环境中轻松访问,因此它将是最易于使用的。 顶部面板中有Firefox的快捷方式。

sshot-24

Navigate to and download the latest version of chntpw for 64-bit machines.

浏览至并下载适用于64位计算机的最新版本的chntpw

Note: In most cases it would be best to add the Debian Unstable branch to a package manager, but since the Live CD environment will revert to its original state once you reboot, it’ll be faster to just download the .deb file.

注意:在大多数情况下,最好将Debian Unstable分支添加到软件包管理器中,但是由于Live CD环境在重新启动后将恢复为原始状态,因此下载.deb文件会更快。

sshot-17

Save the .deb file to the default location.

将.deb文件保存到默认位置。

sshot-18

You can close Firefox if desired. Open a terminal window by clicking on Applications at the top-left of the screen, expanding the Accessories folder, and clicking on Terminal.

如果需要,可以关闭Firefox。 通过单击屏幕左上方的“应用程序”,展开“附件”文件夹,然后单击“终端”,以打开一个终端窗口。

sshot-14

In the terminal window, enter the following text, hitting enter after each line:

在终端窗口中,输入以下文本,在每一行之后按Enter键:

cd Downloads sudo dpkg –i chntpw*

cd下载sudo dpkg –i chntpw *

sshot-19

chntpw will now be installed.

chntpw现在将被安装。

Using chntpw to reset your password

使用chntpw重设密码

Before running chntpw, you will have to mount the hard drive that contains your Windows installation. In most cases, Ubuntu 9.10 makes this simple.

在运行chntpw之前,您必须安装包含Windows安装的硬盘驱动器。 在大多数情况下,Ubuntu 9.10使这一过程变得简单。

Click on Places at the top-left of the screen. If your Windows drive is easily identifiable – usually by its size – then left click on it.

点击屏幕左上角的位置。 如果您的Windows驱动器很容易识别(通常是按其大小),则请在其上单击鼠标左键。

sshot-11

If it is not obvious, then click on Computer and check out each hard drive until you find the correct one.

如果不明显,请单击“计算机”并检出每个硬盘驱动器,直到找到正确的硬盘驱动器。

sshot-12

The correct hard drive will have the WINDOWS folder in it. When you find it, make a note of the drive’s label that appears in the menu bar of the file browser.

正确的硬盘驱动器中将有WINDOWS文件夹。 找到后,记下出现在文件浏览器菜单栏中的驱动器标签。

sshot-13

If you don’t already have one open, start a terminal window by going to Applications > Accessories > Terminal.

如果尚未打开,请通过转到应用程序>附件>终端来启动终端窗口。

sshot-14

In the terminal window, enter the commands

在终端窗口中,输入命令

cd /media ls

cd / media ls

pressing enter after each line. You should see one or more strings of text appear; one of those strings should correspond with the string that appeared in the title bar of the file browser earlier.

在每行之后按Enter。 您应该看到一个或多个文本字符串。 这些字符串之一应与先前在文件浏览器标题栏中显示的字符串相对应。

Change to that directory by entering the command

通过输入命令转到该目录

cd <hard drive label>

cd <硬盘标签>

Since the hard drive label will be very annoying to type in, you can use a shortcut by typing in the first few letters or numbers of the drive label (capitalization matters) and pressing the Tab key. It will automatically complete the rest of the string (if those first few letters or numbers are unique).

由于输入硬盘标签很烦人,因此可以通过键入驱动器标签的前几个字母或数字(大写字母)并按Tab键来使用快捷方式。 它将自动完成字符串的其余部分(如果前几个字母或数字是唯一的)。

sshot-15

We want to switch to a certain Windows directory. Enter the command:

我们想切换到某个Windows目录。 输入命令:

cd WINDOWS/system32/config/

光盘WINDOWS / system32 / config /

Again, you can use tab-completion to speed up entering this command.

同样,您可以使用制表符补全来加快输入此命令的速度。

sshot-16

To change or reset the administrator password, enter:

要更改或重置管理员密码,请输入:

sudo chntpw SAM

须藤chntpw SAM

SAM is the file that contains your Windows registry. You will see some text appear, including a list of all of the users on your system.

SAM是包含Windows注册表的文件。 您将看到一些文本,包括系统上所有用户的列表。

sshot-20

At the bottom of the terminal window, you should see a prompt that begins with “User Edit Menu:” and offers four choices. We recommend that you clear the password to blank (you can always set a new password in Windows once you log in). To do this, enter “1” and then “y” to confirm.

在终端窗口的底部,您应该看到一个以“用户编辑菜单:”开头的提示,并提供四个选项。 我们建议您将密码清除为空白(登录后始终可以在Windows中设置新密码)。 为此,输入“ 1”,然后输入“ y”进行确认。

sshot-21

If you would like to change the password instead, enter “2”, then your desired password, and finally “y” to confirm.

如果您想更改密码,请输入“ 2”,然后输入所需的密码,最后输入“ y”进行确认。

sshot-25

If you would like to reset or change the password of a user other than the administrator, enter:

如果您想重置或更改管理员以外用户的密码,请输入:

sudo chntpw –u <username> SAM

sudo chntpw –u <用户名> SAM

sshot-22

From here, you can follow the same steps as before: enter “1” to reset the password to blank, or “2” to change it to a value you provide.

在这里,您可以执行与之前相同的步骤:输入“ 1”将密码重置为空白,或输入“ 2”将其更改为您提供的值。

sshot-23

And that’s it!

就是这样!

Conclusion

结论

chntpw is a very useful utility provided for free by the open source community. It may make you think twice about how secure the Windows login system is, but knowing how to use chntpw can save your tail if your memory fails you two or eight times!

chntpw是开源社区免费提供的非常有用的实用程序。 这可能会让您三思而后行,以确保Windows登录系统的安全性,但是知道如何使用chntpw可以在内存不足两次或八次的情况下省掉您的尾巴!

翻译自:

ubuntu 重置密码

转载地址:http://clcwd.baihongyu.com/

你可能感兴趣的文章
xmpp IOS开发高级
查看>>
[转] - linux下使用write\send发送数据报 EAGAIN : Resource temporarily unavailable 错
查看>>
从0开始 图论学习 拓扑排序 链式前向星表示法
查看>>
centos6.5安装pip方法
查看>>
WCF常用绑定选择
查看>>
OGRE COMMAND-LINE UTILITIES
查看>>
IO:in、out和err
查看>>
Linux记录-使用python临时搭建web服务器
查看>>
日期转换为新数据类型CONVERT() 函数
查看>>
C#设计模式之十外观模式(Facade Pattern)【结构型】
查看>>
Redis进阶实践之十五 Redis-cli命令行工具使用详解第二部分(结束)
查看>>
Git使用gitignore建立项目过滤规则
查看>>
Can you solve this equation?
查看>>
经典算法50题
查看>>
广义距离变换
查看>>
2019年Q1总结+Q2大体规划
查看>>
struts2常用标签
查看>>
初次学习CentOS需要注意的问题
查看>>
初学C#之方法
查看>>
[Kubernetes]深入理解StatefulSet
查看>>