Linux Kernel (Topic 2.201)

Review Questions

  1. You find that the make modules command fails repeatedly when trying to compile a new kernel. What can you do to solve this problem?

  2. You need to know the CPU type on a system before updating the kernel. Which of the files in the /proc directory can tell you what CPU you are using?

  3. You want to learn more about the PCI-based hardware in a typical Intel-based computer so that you can update the kernel. What command can you use?

  4. The older computer you are using does not support the make bzImage command. What commands can you execute if you want to create a smaller kernel?

  5. You have just compiled a new kernel, but it will not boot. You intend on booting a kernel on the second partition of the first hard drive. Currently, the GRUB configuration file reads as follows:

    title Test Kernel (2.6.0)
                root (hd0,2)
                kernel /boot/bzImage-2.6.1 ro root=LABEL=/
                initrd /boot/initrd-2.6.1.img

    What change needs to be made?

  6. When building and installing modules during the process of creating a new kernel, when do you need to be root?

Answers

  1. Use the make mrproper command, then make clean. If these two commands do not solve the problem, you are using the wrong configuration file for your CPU type. Go to the /usr/src/linux/configs/ kernelname directory and copy the correct file.

  2. /proc/cpuinfo.

  3. /bin/lspci -vv.

  4. Any of the following: make zImage, make zdisk, or make zlilo.

  5. Change root (hd0,2) to read root (hd0,1). GRUB uses a zero-based counting system, so the second partition ...

Get LPI Linux Certification in a Nutshell, 2nd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.