Solved

Ubuntu - reset root password

Posted on 2010-11-11
7
988 Views
Last Modified: 2013-11-15
Hi

I have 'inherited' a linux machine and need to reset the root password. I tried restarting in recovery mode and dropping to a root shell prompt as advised on various websites but then got
Give root password for maintenance shell (or type Control-D to continue):

I don't know where to go from here as I'm a novice really. I have seen this page but don't know how to follow it

http://www.uluga.ubuntuforums.org/showthread.php?t=1433097

I tried starting again in recovery mode and pressing e to edit it but this just gave me an screen with some output on it and th option for a command prompt which just takes you to a  grub command prompt .

I don't know what to do :)
thanks a lot
0
Comment
Question by:andieje
7 Comments
 
LVL 8

Accepted Solution

by:
Wilder_Admin earned 500 total points
ID: 34115074
the only really working is to boot from cd linux distribution like ubuntu or knoppix. Then search the /etc/shadow file and delete all behind root.
then you should reboot and you can enter with root again without password.

If this is not working then boot again from the linux distribution and enter the file /etc/group and give a different user then root the root rights for example the www-data user of apache and log in with.

If this is not working and you dont have local access to machine then you are srewed.
0
 
LVL 3

Expert Comment

by:alpharom
ID: 34115082
if you have a ubuntu cd-rom you can run it from the configuration in a graphical mode
0
 
LVL 6

Expert Comment

by:sagiamar
ID: 34115083
0
Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

 

Author Comment

by:andieje
ID: 34115134
i don't have a cd rom.
Here is what i get
linux.jpg
0
 

Author Comment

by:andieje
ID: 34115145
what do you mean by don't have local access?

I am running linux as a virtual machine. It is someone else's VM and I can't get it to load.

I actually get these errors when I try and log on as the user I have the password for:


Could not update ICEauthority file home/mkhweb/.ICEauthority

I click the only option, cancel and then get this error

There is a problem with the configuration server (/usr/lib/libgconf2-4/conf-sanity-check exited with status 256

So i can't log on at all. All the fixes for the above solution require dropping to a root shell and I can't do that!!!
0
 

Author Comment

by:andieje
ID: 34115152
I probably have the original linux iso file if that helps
0
 

Author Closing Comment

by:andieje
ID: 34115425
thanks
0

Featured Post

Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Are you sitting there reading this and wondering how to get started with Linux? It almost seems like picking the right Linux distribution is about like picking the right college or buying a new car if you read some of the article out there. Relax… l…
After running Ubuntu some time, you will be asked to download updates for fixing bugs and security updates. All the packages you download replace the previous ones, except for the kernel, also called "linux-image". This is due to the fact that w…
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…

820 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question