Operating System - Linux
1752777 Members
6165 Online
108789 Solutions
New Discussion юеВ

Re: how to copy a file in rescue mode.

 
nataraj.kn
Advisor

how to copy a file in rescue mode.

My kernal is corrupted Accidentally. I want copy file from other system. I tried SCP,SSH,TELNET,FTP but not coping the file.
is it having any option for coping a file?

I am not able to see my kermal in boot partision?
how can i get it back?
6 REPLIES 6
~sesh
Esteemed Contributor

Re: how to copy a file in rescue mode.

A similar issue has been discussed in another forum thread. Basically, you would need to install the kernel (assuming you have redhat), the command would be something like:


rpm -ivh "kernel file name".rpm

http://forums12.itrc.hp.com/service/forums/questionanswer.do?threadId=1186693
Srimalik
Valued Contributor

Re: how to copy a file in rescue mode.

rescue mode will not start networking.

What you can try is ...

copy the file on a usb stick(thumb drive) / floppy disk(if u have one)

boot the machine in rescue mode

mount the usdb/floppy and copy the file.

If you have multiple CD drives you can also use a CD in palce of USB/floppy.

abandon all hope, ye who enter here..
Ivan Ferreira
Honored Contributor

Re: how to copy a file in rescue mode.

>>> rescue mode will not start networking

If you are using redhat, rescue mode ask you if you want to start network services.

The problem is that your file system is located in /mnt/sysimage, so your boot partition will be at /mnt/sysimage/boot.

You should copy your files there.
Por que hacerlo dificil si es posible hacerlo facil? - Why do it the hard way, when you can do it the easy way?
Gary L
Super Advisor

Re: how to copy a file in rescue mode.

1. Boot Redhat Linux system into "rescue mode", set original network configurations like IP, Submask, Gateway, DNS etc. at start networking prompt.

2. chroot /mnt/sysimage

3. service sshd start -- start ssh, if the server required.

4. use "cmd" command line or some FTP tools like Reflection FTP Client Program, do the file(s) upload or download.
palaniappan.sp
Regular Advisor

Re: how to copy a file in rescue mode.

Hi,

U can copy the file through floppy or pendrive.But u should have the ext2 filesystem in the media.so that it will be readable by the system.
this method nothing like, loading a kernel module while installing the OS for Sata drives.
U can try this method also for copying ur data,when network copying doesn,t works.

Regds
Palani
Everything is Possible and Anything is Feasible if u try
Jeeshan
Honored Contributor

Re: how to copy a file in rescue mode.

If you kernel is corrupted, how do you copy files?

If your kernel is corrupted please paste the actual message here.

>>I am not able to see my kermal in boot partision?

Actually kernel reside in /usr directory

in /boot partition you can see the boot image of kernel.

>>how can i get it back?

please paste the actual message where you get the message kernel is corrupted or kernel panic
a warrior never quits