Find the answer to your Linux question:
Results 1 to 2 of 2
hi I'm new to kernel build/rebuild, and reading an article about it but got a little confused at the configuration step. I'm wondering how I can get the hardware info ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Apr 2008
    Posts
    1

    Red face Build/rebuild kernel


    hi

    I'm new to kernel build/rebuild, and reading an article about it but got a little confused at the configuration step. I'm wondering how I can get the hardware info from the target machine if it has nothing on it yet? The "make xconfig" is to run on the target machine, I suppose.

    thanks.

  2. #2
    Linux Guru
    Join Date
    Nov 2007
    Location
    Córdoba (Spain)
    Posts
    1,513
    Quote Originally Posted by jwxc View Post
    hi

    I'm new to kernel build/rebuild, and reading an article about it but got a little confused at the configuration step.
    If you need advise about the contents of that article, I suggest that you post a link to it. Otherwise, we can't read it, and therefore we can't comment on it either.

    I'm wondering how I can get the hardware info from the target machine if it has nothing on it yet?
    You can't compile a kernel on a machine that has nothing on it.

    If you use a binary distro, you install it, and after the installation is completed, then you can download the kernel sources (or install them using your package manager, if it's supported by your distro) and configure and compile them.

    If you use a source based distro, like lfs, sourcemage or gentoo, then you will be forced to compile your own kernel while installing. I don't know about the others, but Gentoo has excellent documentation for the whole installation process.

    In any case, you need to boot linux on a machine, to be able to compile a linux kernel on it. And, as such, you will have access to lspci and the rest of tools that will help you to identify your hardware.

    The "make xconfig" is to run on the target machine, I suppose.

    thanks.
    Nothing stops you from compiling the kernel on one machine and then copy it over to any other. In fact, this is what you do when you install a binary distro (the kernel is compiled by the people who make the distro on their machines, and then copied to yours). You need to include all the relevant drivers for the machine you intend to run it on, of course.

    Of course, both machines must be running compatible architectures. There's no easy way to compile a kernel for amd64 on a powerpc.

    Also, I advise in favor of menuconfig, instead of xconfig. If your hardware is limited, or X is not running for any other reason, you are better using menuconfig. Plus I find the mouse to be a pain in the ass when you have to dive though thousands of options.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •