LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   Kernel Panic: can't bootup (https://www.linuxquestions.org/questions/linux-general-1/kernel-panic-cant-bootup-4175491729/)

JosephS 01-20-2014 08:14 PM

Quote:

Originally Posted by jailbait (Post 5101753)
Probably. You need to make an initrd against the Crunchbang kernel not the rescue CD kernel. From the error messages I think that it may have been looking for 3.2.0-4-amd64 3.2.0-4-rt-amd64 kernel modules on the rescue CD which is using a 3.4.62-std380-amd64 kernel.

------------------------------
Steve Stites

How would I do that? I can't boot with the kernel in Cruchbang

I have some additional info. I wasn't sure how much was needed
in smartctl.
Quote:

root@crunchbang:~# dd if=/boot/initrd.img-3.2.0-4-amd64 of=/dev/null
dd: reading `/boot/initrd.img-3.2.0-4-amd64': Input/output error
19256+0 records in
19256+0 records out
9859072 bytes (9.9 MB) copied, 48.5806 s, 203 kB/s
root@crunchbang:~# dmesg | tail
[ 881.982948] sd 0:0:0:0: [sda] Unhandled sense code
[ 881.982953] sd 0:0:0:0: [sda] Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
[ 881.982961] sd 0:0:0:0: [sda] Sense Key : Medium Error [current] [descriptor]
[ 881.982973] Descriptor sense data with sense descriptors (in hex):
[ 881.982977] 72 03 11 04 00 00 00 0c 00 0a 80 00 00 00 00 00
[ 881.982991] 05 23 2e 6e
[ 881.982998] sd 0:0:0:0: [sda] Add. Sense: Unrecovered read error - auto reallocate failed
[ 881.983007] sd 0:0:0:0: [sda] CDB: Read(10): 28 00 05 23 2e 68 00 00 08 00
[ 881.983021] end_request: I/O error, dev sda, sector 86191726
[ 881.983051] ata1: EH complete
root@crunchbang:~# smartctl -a /dev/sda | grep _Sector
5 Reallocated_Sector_Ct 0x0033 063 063 050 Pre-fail Always - 1921
197 Current_Pending_Sector 0x0032 100 100 000 Old_age Always - 126

jailbait 01-20-2014 09:20 PM

section 6.3 of this web page:

http://kernel-handbook.alioth.debian.org/ch-initrd.html

explains how to generate a new initrd for an existing kernel in Debian. Crunchbang is based on Debian so it may work the same way (maybe) in Crunchbang. Notice that you tell dpkg which kernel you want to make an initrd for so that dpkg is not necessarily making a new initrd for the kernel you are running on. I suggest that you boot into Crunchbang using the rescue CD and then try to recreate the Crunchbang initrd using dpkg.

Another way to do this is to use the rescue CD to boot into Crunchbang and reinstall your kernel. I am pretty sure that reinstalling a kernel also includes making a new initrd. I use the Synaptic GUI for apt-get so I would use Synaptic to find the kernel (probably) named linux-image-3.2.0-4-rt-amd64, mark it for reinstallation, and click on APPLY. After the reinstalling the kernel you have to reboot. If you don't use Synaptic then I think that the apt-get command is:

apt-get install --reinstall linux-image-3.2.0-4-rt-amd64

but whichever command you try you better check to make sure that linux-image-3.2.0-4-rt-amd64 is actually what Crunchbang calls the kernel package that you are using. I am more sure that what I told you about Synaptic is correct than I am about what I told you about apt-get.

---------------------
Steve Stites

Ser Olmy 01-20-2014 09:48 PM

Quote:

Originally Posted by JosephS (Post 5101883)
I have some additional info. I wasn't sure how much was needed
in smartctl.

Your drive has bad sectors, which means it is probably failing and needs to be replaced.

JosephS 01-21-2014 02:55 PM

thanks for the help

I followed jailbait's advice today and reinstalled the kernel. The computer is booting up again with the flash drive. The sound also is working again.

I might still have to look into getting another hard drive or computer. Yesterday the computer froze on me and I lost the mouse and screen; had to reboot and got it working again.


All times are GMT -5. The time now is 11:47 AM.