Ubuntu cloud img ova 等云镜像修改登录密码的方法

本文介绍了如何在VirtualBox中导入Ubuntu Bionic 18.04 Cloudimg.ova镜像,并通过修改shadow和passwd文件来改变默认登录密码。首先创建并启动Ubuntu桌面虚拟机,然后导入ova文件,将ova磁盘添加到桌面VM,通过GUI文件管理器找到磁盘,以root权限修改文件,最后删除passwd文件中第一条记录的x,重启导入的ova虚拟机即可无密码登录。

Ubuntu Cloud img file and virtualbox ova ovf files that a way to change the default  login user password.

运行环境:virtualbox

镜像名称:ubuntu-bionic-18.04-cloudimg.ova

下载地址:http://uec-images.ubuntu.com/bionic/current/

修改默认账号密码思路:修改 shadow ,passwd 文件实现。

一句话概括:创建一个桌面版本ubuntu,然后导入ova到虚拟机,把导入的虚拟机下的磁盘给桌面ubuntu装载,然后启动桌面ubuntu,去修改shadow,passwd文件,来实现改密码。

首先创建并启动一个ubuntu桌面虚拟机。

导入cloud ova到virtualbox,关闭ubuntu桌面虚拟机。

配置ubuntu桌面VM磁盘选项,添加之前您导入ova img VM磁盘作为桌面VM磁盘的一部分。

启动桌面虚拟机,在GUI文件管理器接口的其他位置找到磁盘,同时磁盘将由系统装入指令加载。

现在,您可以在文件系统中修改影子文件和passwd文件(可能需要在命令行中使用root运行vi)。

您可以删除passwd文件的第一个文本行中的x,保存文件并关闭当前的桌面系统,删除磁盘,启动导入ova虚拟机,您可以登录Linux不需要密码。

参考:http://blog.sina.com.cn/s/blog_a04184c101010kq7.html

EN

Runtime environment: VirtualBox

Ubuntu - Bionic -18.04- Cloudimg. ova

Download address: http://uec-images.ubuntu.com/bionic/current/

Modify the default account password: modify shadow, passwd file implementation

In a nutshell: Create a desktop version of Ubuntu, import the OVA into the virtual machine, load the disk from the imported virtual machine into desktop Ubuntu, launch Desktop Ubuntu, modify the shadow, passwd file, and change the password.

First  create and start a ubuntu desktop VM.

Import the cloud ova into the virtualbox,shutdown the ubuntu desktop VM.

Configure the ubuntu desktop VM disk options,add the before you import ova img VM disk as apart of desktop VM disk.

Start the desktop VM,In the GUI file manager interface others location find the disk meantime the disk will be loaded by the system mount instruction.

Now,you can modify the shadow file and passwd file in the file system,(may you need to run the vi in the commandline with root).

Your can delete the x in the first text line of the passwd file,save file and shutdown current desktop system ,remove disk apart,start the Import ova VM ,you can login Linux with no password.

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值