[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Messed up root (SOLVED)



On 11/27/2012 04:05 AM, Klearchos-Angelos Gkountras wrote:
Take a live CD with same architecture as your currently machine.
D
chroot is one solution ... i think you need to do that from knoppix live
cd if the architecture is the same as your machine ; knoppix is i386 so
If your machine is i386 or amd64 with mutiarch will work

boot the live cd

open a terminal as root

create the partiontable on /mnt directory of the live Cd

for instance / partion as /mnt and home partition as /mnt/home and etc.

now mount the devices of your HDD to /mnt/  i.e. for / partion

mount /dev/sda1 /mnt/


alright , as we go now ...

chroot /mnt/ /bin/bash

and now is on your debian

and you can change the owner to root ...

chown -hR root /etc



On Mon, Nov 26, 2012 at 04:43:29PM -0800, Gary Roach wrote:
I've done the unthinkable. I accidentally changed root to qroot in
my /etc/passwd file and then proceeded to log out of root. All of
the files in /etc were changed to owner qroot and the root password
doesn't work any more. I have a new Knoppix CD and a new Debian
network install CD. Can I use either of these to edit the passwd
file and correct the problem. If so, how.

Thanks in advance

Gary R.


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org with a
subject of "unsubscribe". Trouble? Contact
listmaster@lists.debian.org
Archive: http://lists.debian.org/50B40CB1.8060903@verizon.net

I thank everyone for the help. I loaded a live copy of Knoppix into the system. It did most of the work form me. The hard drive automatically loaded. I logged in as root, opened the passwd file with Knoppix's copy of nano, made the corrections, rebooted the system with the Knoppix disk removed and was home free.

Thank you all

Gary R.


Reply to: