S
S
syxoi2016-07-23 08:19:24
linux
syxoi, 2016-07-23 08:19:24

Gentoo: manual kernel build?

Hi all.
I want to get off genkernel already, but there are a lot of questions.
If you build the kernel like this:
1) cd /usr/src/linux
2) zcat /proc/config.gz >.config
3) make menuconfig - configure
4) make -j5
5) make modules_install
6) make -j5 install - but what is this a command if I still manually get the kernel file?
7) make headers_install
And copy to /boot, configure the bootloader, etc.
But how to build an initramfs, and is it necessary? Will it be a monolithic kernel? And if monolithic, then after all, we compiled the kernel modules and installed them. The loader, it seems, will not load without an initramfs?
And is it possible to force emerge to download in multiple threads?
Thanks :)

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Alexander, 2016-07-23
@syxoi

Main article: https://wiki.gentoo.org/wiki/Handbook:AMD64/Instal...
Commands:

eselect kernel list
eselect kernel set linux-X.Y.Z-gentoo
cd /usr/src/linux
zcat /proc/config.gz >.config
make menuconfig # настраиваем
make -j5
make install modules_install # нет смысла делать -j при установке

make install copies the finished kernel (bzImage) to /boot/vmlinuz-XYZ-gentoo, so you don't have to manually extract it.
Initramfs is not needed if your root FS and /usr are on the same disk partition (/dev/sdxN) and RAID, LVM, LUKS, etc. are not used for the root FS.
If the bootloader is grub2, then grub2-mkconfig looks for the corresponding /boot/initrd-XYZ-gentoo. If it is not there, then the download will be without initramfs.

D
Dmitry, 2016-07-23
@zmitrok62

Почитайте зачем нужен initramfs. Оно решает проблему "курицы и яйца". Чтобы загрузить ваше ядро - его надо считать с диска, для этого соответственно надо загрузить драйвер файловой системы. А откуда его загрузить если мы не умеем читать с этого диска?
По остальным вопросам даже не знаю как ответить....

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question