Melodie,
If you think that would be a better way, why not explain it yourself? Why ask me to explain your idea?
Let's do it ! In case I don't give enough details you will complete : do you agree ?
Start for explanation:
When our beloved distro is in trouble, we have at least 3 means to access to it for repair.
1) from init1
2) from a livecd
3) from another distribution which is installed in the same machine, same hard driver or next hard drive
The most important in theses 3 methods is the ability to access to the root partition (the / )
Let's show how to do it from a Live CD:
* Boot a Live CD;
* Once you are logued in a X session as user, open a console;
* Become root in the console;
* Mount the partition where you have the sick / partition, in order to cure it (mount it to /mnt directory for instance);
* Move to the /mnt partition where the / from hard drive is mounted;
* Now check you have all of the / directories there, with a "ls -l" command, if you see all the directories : /bin, /sbin, /home, and so on, it's all ok.
* Now you need to mount a few stuff to make the / from hard drive feel well (no technical language here, just do... I don't have the right tech explanation in english for that):
From within the /mnt directory where the partition of hard drive that need to be repaired, as with root priviledge:
# mount -o bind /dev dev/this is to have same as /dev, but in the partition which is mounted. Then:
mount -t proc none proc/about same for "none". For both commands beware of the place of the slashes ! /dev is not the same as dev/ !!!
Then you will do this, which is where all begins:
# chroot . Beware of the dot after the chroot command !!! There is "chroot", then _a space_, then a dot ! If you do not do the same it won't work. This command has the following effect : it makes the shell think that it is in the real / directory of the system. In other words, it raises the mounted partition to the same level as the / directory : but only in that one shell.
Once done, connect the chrooted partition to internet:
# dhclient eth0 // if eth0 is the cable network interface... usually this works, and sometimes it's not even necessary
Then:
# apt-get update && apt-get dist-upgrade
Then:
# apt-get install kernel-<here choose a version>
If you don't know what version, look in the Synaptic which you probably have in the PCLinuxOS Live CD of your's, to find one that is not yet installed in the hard drive install.
Hope this will help you. Some details for a complete howto might be missing, if necessary : ask.
