[plug] I hate myself :( rm -r gone too far....

craig at postnewspapers.com.au craig at postnewspapers.com.au
Thu Aug 22 13:39:52 WST 2002


> This should do the trick I think. However, I've just found a more 
> immediate problem:
> 
> I have no name!@localhost$
> 
> I can't become root because one of the user config files has been 
> zapped, so I don't have enough permission to write anything to /etc. 
> Any ideas????

reboot and pass the following to the kernel at boot:

init=/bin/bash

That'll give you root w/o a password (this is why boot sector passwords
are a must for real security, along with BIOS setup passwords). 

That'll give you a very limited environment but you can begin system
recovery from there. Consider using "open" to open a few virtual
consoles before beginning, as shell job control won't work at this
level.

You'll probably need to :
devfsd /dev (if your system uses devfs)
mount -t proc none /proc

to get anything working. 

-- 
Craig Ringer
GPG Key Fingerprint: AF1C ABFE 7E64 E9C8 FC27  C16E D3CE CDC0 0E93 380D
	-- if it ain't broke, add features 'till it is. (or:)
	while (! broken) { features ++ ; broken = isBroken(features) }



More information about the plug mailing list