PDA

View Full Version : The dreaded chroot !



exxfile
08-02-2009, 05:45 AM
Hi All

I am a linux newbie , i decided to give it a try when some malware hijacked my windows even after being scanned twice . It downloaded and f... me in real time . So I have decided no more and thats how I would up here .

I am a linux newbie so all I ask is that if you have a suggestion please provide a concise code example or I will be totally lost at the slightest assumption .

I ahve scouered the internet looking for an answer and can't seem to find anything useful even through posts of people that have had exactly the same problem.

Whenever I try to chrooot into the directory I want to use for remastering the error is cannot run bin/bash " O suchFi8le or Directory"

Checklist of what I did .

mounter the drive as root and set rw permissions
copies the Knoppix cd as root
checked to make sure all copies directories had the appropriate permissions for gid and uid .

I know that when the chroot command is executed , after specifying the new root directory you can run a command otherwise the system defaults to bin/bash . I am pretty sure all necessary directories and libs are present since everything off the cd has been copied .

I kind of like the idea of remastering cuz I think its a great way to learn about the internals of linux . Just wish I was getting off to a better start .

All help mych appreciated .

exxfile
08-02-2009, 05:35 PM
Hi

Ok for all that are stumped by this one .

I reformatted the drive from FAT 32 to ext 3 . I don't get the NO Such file or directory error anymore but noy I am getting a dev null permission denied error . However this prob is fully documented and the asnwer to it is in the forum already as well as other places .

Cause

Linux doesn't understand how to preserve ownership of files on a Fat32 drive and I have a sneaky suspicion that chroot doesn't support Fat32 either. I am not about to go checking the other fat partions . I reformatted to Ext 3 and now I am ok again ...welll that is until the next stumper !

lesson learned : Windows hated Linux not necessarily the other way around !