Issue the following commands on the server (the mknbi package should be installed):
# cd /tftpboot # chmod 0555 zImage # chown root:root zImage # mknbi-linux zImage --output=kernel --rootdir=/nfsroot |
If you are using LanWorks EPROMs, also issue the following commands (you need the imggen utility):
# mv -f kernel tmpkernel # imggen -a tmpkernel kernel # rm -f tmpkernel |
Create an empty filesystem with the appropriate size on this ramdisk:
# mke2fs -m0 /dev/ram0 300 |
# mount -t ext2 /dev/ram0 /mnt |
# cp -a /tmp/rootfs/* /mnt |
# umount /mnt |
Save the ramdisk image to some file and free it:
# dd if=/dev/ram0 of=initrd bs=1024 count=300 # freeramdisk /dev/ram0 |
Then, you have to modify the kernel image, as was told above, with the mknbi-linux utility. Its invocation will slightly differ from the above, though (I will assume your just compiled zImage resides in /tftpboot/zImage and your initial ramdisk image resides in /tmp/initrd):
# cd /tftpboot # chmod 0555 zImage # chown root:root zImage # rdev zImage /dev/ram0 # mknbi-linux zImage --output=kernel --rootdir=/dev/ram0 /tmp/initrd |
Закладки на сайте Проследить за страницей |
Created 1996-2024 by Maxim Chirkov Добавить, Поддержать, Вебмастеру |