Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[„gelöst“]Probleme mit der initrd
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

 
Reply to topic    Gentoo Forums Forum Index Deutsches Forum (German)
View previous topic :: View next topic  
Author Message
bas89
Apprentice
Apprentice


Joined: 02 Mar 2010
Posts: 243
Location: Germany ;)

PostPosted: Mon Jan 03, 2011 3:51 pm    Post subject: [„gelöst“]Probleme mit der initrd Reply with quote

Hallo,

ich habe ein kopfzerbrechendes Problem mit der init: Sie wird nicht gefunden. Mein /boot liegt auf sda4, GRUB läuft gut, erst der Kernel gibt einen Panic: „No init found. Try passing init= option to kernel.“ (siehe Bild).

Die Datei initramfs wurde nach http://en.gentoo-wiki.com/wiki/Root_filesystem_over_LVM2,_DM-Crypt_and_RAID erzeugt. Die Kernel-Optionen
initrd-support
support gzip-compressed ramdisks
built-in initramfs compression mode = gzip
SCSI disk support = Y (SATA-Platte)

sind aktiv. Nach ewigem Probieren wollte ich die init in den Kernel einbauen, frei nach dieser Anleitung (ich gab dem Kernel das init-Verzeichnis an und löschte den initrd-Eintrag in Grub), was jedoch in derselben Fehlermeldung endet(?!). Inzwischen habe ich die Einstellung auf externe initramfs umgestellt. Ich glaube irgendwie, dass der Kernel in der Datei initramfs das init-Script nicht findet. Es ist ausführbar.

Nebenbei: Auf dem Laptop läuft nebenher genau das gleiche Prinzip einwandfrei, dies wurde vor einem Jahr eingerichtet.


http://wase.urz.uni-magdeburg.de/hupfeld/DSC03644.JPG


Last edited by bas89 on Wed Jan 05, 2011 9:34 pm; edited 2 times in total
Back to top
View user's profile Send private message
bas89
Apprentice
Apprentice


Joined: 02 Mar 2010
Posts: 243
Location: Germany ;)

PostPosted: Mon Jan 03, 2011 6:34 pm    Post subject: Reply with quote

Hier noch die wichtigsten Sachen:
.config: pastebin

Code:
[root@localhost gen]# mount /dev dev/ -o bind
[root@localhost gen]# mount -t proc none proc/
[root@localhost gen]# mount /dev/sda3 boot/
[root@localhost gen]# umount boot/
[root@localhost gen]# ls boot/
[root@localhost gen]# mount /dev/sda3 boot/
[root@localhost gen]# chroot . /bin/bash
localhost / # cd usr/src/linux
localhost linux # ls /boot/
boot  gentoo  gentoo-backup  grub  initramfs  initramfs-backup  lost+found
localhost linux # ls
arch           drivers   Kbuild       modules.builtin  samples     usr
block          firmware  kernel       modules.order    scripts     virt
COPYING        fs        lib          Module.symvers   security    vmlinux
CREDITS        include   MAINTAINERS  net              sound       vmlinux.o
crypto         init      Makefile     README           System.map
Documentation  ipc       mm           REPORTING-BUGS   tools
localhost linux # cd ..
localhost src # ls
initramfs  linux  linux-2.6.34-tuxonice-r6
localhost src # ls -R initramfs/
initramfs/:
bin  dev  etc  init  newroot  proc  sys
initramfs/bin:
busybox  cat  cryptsetup  loadkmap  lvm  mdadm  mount  sh  sleep  switch_root  umount  vgchange  vgscan
initramfs/dev:
console  mapper  null  sda4  urandom  vc
initramfs/dev/mapper:
vg-root
initramfs/dev/vc:
0
initramfs/etc:
kmap-de
initramfs/newroot:
initramfs/proc:
initramfs/sys:

localhost src # cat initramfs/init
#!/bin/sh

mount -t proc proc /proc
CMDLINE=`cat /proc/cmdline`

mount -t sysfs sysfs /sys

#wait a little to avoid trailing kernel output
sleep 3

#If you don't have a qwerty keyboard, uncomment the next line
loadkmap < /etc/kmap-de


#dm-crypt
/bin/cryptsetup luksOpen /dev/sda4 vault

#lvm
#/bin/vgscan
/bin/vgchange -ay vg

#root filesystem
mount -r /dev/mapper/vg-root /newroot

#unmount pseudo FS
umount /sys
umount /proc

#root switch
exec /bin/busybox switch_root /newroot /sbin/init ${CMDLINE}

Code:
00:00.0 Host bridge: Intel Corporation 82G33/G31/P35/P31 Express DRAM Controller (rev 02)
00:01.0 PCI bridge: Intel Corporation 82G33/G31/P35/P31 Express PCI Express Root Port (rev 02)
00:1a.0 USB Controller: Intel Corporation 82801I (ICH9 Family) USB UHCI Controller #4 (rev 02)
00:1a.1 USB Controller: Intel Corporation 82801I (ICH9 Family) USB UHCI Controller #5 (rev 02)
00:1a.2 USB Controller: Intel Corporation 82801I (ICH9 Family) USB UHCI Controller #6 (rev 02)
00:1a.7 USB Controller: Intel Corporation 82801I (ICH9 Family) USB2 EHCI Controller #2 (rev 02)
00:1c.0 PCI bridge: Intel Corporation 82801I (ICH9 Family) PCI Express Port 1 (rev 02)
00:1c.3 PCI bridge: Intel Corporation 82801I (ICH9 Family) PCI Express Port 4 (rev 02)
00:1c.4 PCI bridge: Intel Corporation 82801I (ICH9 Family) PCI Express Port 5 (rev 02)
00:1d.0 USB Controller: Intel Corporation 82801I (ICH9 Family) USB UHCI Controller #1 (rev 02)
00:1d.1 USB Controller: Intel Corporation 82801I (ICH9 Family) USB UHCI Controller #2 (rev 02)
00:1d.2 USB Controller: Intel Corporation 82801I (ICH9 Family) USB UHCI Controller #3 (rev 02)
00:1d.7 USB Controller: Intel Corporation 82801I (ICH9 Family) USB2 EHCI Controller #1 (rev 02)
00:1e.0 PCI bridge: Intel Corporation 82801 PCI Bridge (rev 92)
00:1f.0 ISA bridge: Intel Corporation 82801IB (ICH9) LPC Interface Controller (rev 02)
00:1f.2 IDE interface: Intel Corporation 82801IB (ICH9) 2 port SATA IDE Controller (rev 02)
00:1f.3 SMBus: Intel Corporation 82801I (ICH9 Family) SMBus Controller (rev 02)
00:1f.5 IDE interface: Intel Corporation 82801I (ICH9 Family) 2 port SATA IDE Controller (rev 02)
01:00.0 VGA compatible controller: ATI Technologies Inc RV770 [Radeon HD 4850]
01:00.1 Audio device: ATI Technologies Inc HD48x0 audio
03:00.0 SATA controller: JMicron Technology Corp. 20360/20363 Serial ATA Controller (rev 02)
03:00.1 IDE interface: JMicron Technology Corp. 20360/20363 Serial ATA Controller (rev 02)
04:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168B PCI Express Gigabit Ethernet controller (rev 01)
05:01.0 Multimedia audio controller: Creative Labs SB Audigy (rev 04)
05:01.1 Input device controller: Creative Labs SB Audigy Game Port (rev 04)
05:01.2 FireWire (IEEE 1394): Creative Labs SB Audigy FireWire Port (rev 04)

Code:
  GNU nano 2.2.4                                   Datei: /boot/grub/grub.conf                                                                               

default 0
timeout 15
#splashimage=(hd0,0)/boot/grub/splash.xpm.gz

title Gentoo
root (hd0,2)
kernel /gentoo crypt_root=/dev/sda4 resume=/dev/vg/swap
initrd /initramfs

title Gentoo-Backup
root (hd0,2)
kernel /gentoo-backup crypt_root=/dev/sda4 noresume
initrd /initramfs-backup

title Windows 7
rootnoverify (hd0,0)
makeactive
chainloader +1
Code:
Platte /dev/sda: 500.1 GByte, 500106780160 Byte
255 Köpfe, 63 Sektoren/Spur, 60801 Zylinder
Einheiten = Zylinder von 16065 × 512 = 8225280 Bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x47e147e0

   Gerät  boot.     Anfang        Ende     Blöcke   Id  System
/dev/sda1   *           1          13      102400    7  HPFS/NTFS
Partition 1 endet nicht an einer Zylindergrenze.
/dev/sda2              14       40943   328770225    7  HPFS/NTFS
/dev/sda3           40944       40977      273105   83  Linux
/dev/sda4           40978       60801   159236280   83  Linux
Back to top
View user's profile Send private message
bas89
Apprentice
Apprentice


Joined: 02 Mar 2010
Posts: 243
Location: Germany ;)

PostPosted: Wed Jan 05, 2011 1:04 pm    Post subject: Reply with quote

Problem ist erledigt, aber ich weiß nicht warum. Ich habe komplett vom Neuen angefangen und nun hats geklappt.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Deutsches Forum (German) All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum