Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[Erledigt] Gentoo übers Netzwerk booten
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
dsiggi
Tux's lil' helper
Tux's lil' helper


Joined: 28 Aug 2007
Posts: 92
Location: Wilhermsdorf

PostPosted: Tue Mar 01, 2016 5:32 pm    Post subject: [Erledigt] Gentoo übers Netzwerk booten Reply with quote

Hi,
ich versuche verzweifelt Gentoo über das Netzwerk zu booten.
Zum testen habe ich mir VirtualBox emergt.

Auf meinem PXE-Server habe ich ein stage4-Archiv entpackt und zum testen zusätzlich noch ein aktuelles Ubuntu.

Der PXE-Ordner ist über NFS freigeben und kann gemountet werden.
Code:

server boot # cat /etc/exports
###PXE
/mnt/storage/pxe   192.168.0.0/24(rw,sync,no_root_squash,no_subtree_check)


Ich habe zum einen einen Kernel selber gebaut.
Hier die .config: https://bpaste.net/show/6eb7d90eb344
Für diesen kernel habe ich mit dracut --kver 4.1.15-nfs -f -v --modules "busybox nfs" gentoo.initrd eine initramfs erstellt.
Zusätzlich habe ich noch den ubuntu kernel und die ubuntu initramfs in mein tftboot Verzeichnis kopiert.

So schaut der Eintrag im Bootloader aus:
Code:

menuentry 'NFS' {
   set root=(pxe)
   linux /boot/kernel root=/dev/nfs nfsroot=${pxe_default_server}:/mnt/storage/pxe/ubuntu ip=dhcp rw
   initrd /boot/initrd
}


Boote ich nun den ubuntu kernel mit den NFS-Pfad /mnt/storage/pxe/ubuntu funktioniert alles super.
Auch mit dem NFS-Pfad /mnt/storage/pxe/gentoo läuft dieser Kernel.

Versuche ich nun mit meinem eigenen Kernel ubuntu oder gentoo zu booten funktioniert dieses nicht.
In der Kernelausgabe sieht man, das der Kernel eine IP-Adresse bezieht. Diese lässt sich auch anpingen.
Code:

....
[    2.782336] IP-Config: Got DHCP answer from 169.254.255.1, my address is 192.168.0.125
[    2.785138] IP-Config: Complete:
[    2.786270]      device=eth0, hwaddr=08:00:27:da:f3:fd, ipaddr=192.168.0.125, mask=255.255.255.0, gw=192.168.0.1
[    2.789693]      host=192.168.0.125, domain=, nis-domain=(none)
[    2.791811]      bootserver=192.168.0.1, rootserver=192.168.0.111, rootpath=
[    2.794213]      nameserver0=192.168.0.1
....
[   97.910425] VFS: Unable to mount root fs via NFS, trying floppy.
[   98.051843] VFS: Cannot open root device "nfs" or unknown-block(2,0): error -6
[   98.062039] Please append a correct "root=" boot option; here are the available partitions:
[   98.073521] 0800         8388608 sda  driver: sd
[   98.073974]   0801         8386560 sda1 ee8f49a1-01
[   98.074425] Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(2,0)
[   98.075182] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 4.1.15-nfs #1
[   98.075761] Hardware name: innotek GmbH VirtualBox/VirtualBox, BIOS VirtualBox 12/01/2006
[   98.081454]  ffffea0001efaa40 ffff88007d3dfdb8 ffffffff816656b6 ffffffff81c3b838
[   98.082195]  ffffffff8193bbf0 ffff88007d3dfe38 ffffffff81664455 ffffffff81c83ea0
[   98.082931]  ffff880000000010 ffff88007d3dfe48 ffff88007d3dfde8 0000000031616473
[   98.083670] Call Trace:
[   98.083910]  [<ffffffff816656b6>] dump_stack+0x45/0x57
[   98.168975]  [<ffffffff81664455>] panic+0xb6/0x1da
[   98.169700]  [<ffffffff81d06329>] mount_block_root+0x17b/0x21f
[   98.170564]  [<ffffffff81002930>] ? __switch_to+0x520/0x590
[   98.175346]  [<ffffffff81d0649d>] mount_root+0xd0/0xfb
[   98.176068]  [<ffffffff81d06600>] prepare_namespace+0x138/0x171
[   98.176897]  [<ffffffff81d06060>] kernel_init_freeable+0x1be/0x1d3
[   98.177777]  [<ffffffff81662530>] ? rest_init+0x80/0x80
[   98.178557]  [<ffffffff81662539>] kernel_init+0x9/0xf0
[   98.179335]  [<ffffffff8166bed2>] ret_from_fork+0x42/0x70
[   98.180101]  [<ffffffff81662530>] ? rest_init+0x80/0x80
[   98.180905] Kernel Offset: disabled
[   98.181417] ---[ end Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(2,0)

Die komplette Ausgabe findet ihr hier: https://bpaste.net/show/15682160a6b6

Ich kann einfach nicht nachvollziehen warum es mit meinem Kernel nicht klappen will.
Ich hoffe ihr könnt mir helfen.

Gruß Siggi


Last edited by dsiggi on Mon Mar 14, 2016 8:11 am; edited 1 time in total
Back to top
View user's profile Send private message
musv
Advocate
Advocate


Joined: 01 Dec 2002
Posts: 3337
Location: de

PostPosted: Thu Mar 03, 2016 7:32 pm    Post subject: Reply with quote

Code:
[   97.910425] VFS: Unable to mount root fs via NFS, trying floppy.
[   98.051843] VFS: Cannot open root device "nfs" or unknown-block(2,0): error -6
[   98.062039] Please append a correct "root=" boot option; here are the available partitions:
[   98.073521] 0800         8388608 sda  driver: sd
[   98.073974]   0801         8386560 sda1 ee8f49a1-01
[   98.074425] Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(2,0)

Der Kernel hat bei Dir Probleme mit nfs versucht von der lokalen Platte zu booten. Irgendwas wird wohl mit dem nfs-Modul nicht passen.
Back to top
View user's profile Send private message
dsiggi
Tux's lil' helper
Tux's lil' helper


Joined: 28 Aug 2007
Posts: 92
Location: Wilhermsdorf

PostPosted: Mon Mar 14, 2016 8:11 am    Post subject: Reply with quote

Hi,
bin erst jetzt dazu gekommen hier weiter zu testen.

Die benötigten FEATURES habe cih fest im kernel.

Code:

CONFIG_NFS_FS=y
CONFIG_NFS_V3=y
CONFIG_NFS_V3_ACL=y
CONFIG_NFS_V4=y
CONFIG_ROOT_NFS=y
CONFIG_NFS_USE_KERNEL_DNS=y
CONFIG_IP_PNP=y
CONFIG_IP_PNP_DHCP=y


Mit dem kernel alleine habe ich es nicht geschaft mit einem nfsroot zu booten.
Auf meinem odroid C1+ habe cih es jetzt in Zusammenspiel mit dracut hinbekommen.
Das Problem war hier das --modules "busybox nfs" . Hierdurch haben wohl anderer wichtige Module gefehlt.

Auf meinem Laptop habe ich es zusammen mit genkernel hin bekommen.

dsiggi
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