Find the answer to your Linux question:
Results 1 to 6 of 6
Hey guys, I have few question on how to get started to build a custom kernel for one my project. As you see that I am posting it in newbie ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Mar 2007
    Posts
    36

    Help me get started with custom unix kernel


    Hey guys,

    I have few question on how to get started to build a custom kernel for one my project. As you see that I am posting it in newbie section so I have almost little to no knowledge of how to do it. I am not going to ask that give me step by step procedure to do it, just some pointers, guidelines and keywords which will help me in google stuff.

    Here is what i am looking at
    • . I need something which supports ARM processor. For this reason I have shortlisted Debian and Android. Haven't decided which will be beneficial
    • . I don't need most of the hardware modules of the kernel (except for io disks, storage etc). I have no idea that if i have kernel source how to delete/remove such modules. Searching with *remove modules custom kernel* comes up with results which aren't relevant
    • . I want to make the kernel boot from SD card ( I am able to get a decent resource on it). HOWEVER, What I want to ask that how can i emulate an SD Card to do testing ? I don't want to use real SD card for each custom kernel i build.

  2. #2
    Trusted Penguin
    Join Date
    May 2011
    Posts
    4,353
    Hi,

    I went ahead and moved your question to the Kernel forum. The hope is that the kernel gurus here will more likely see your post. Hopefully any that respond will keep your limited knowledge in this area in mind.

  3. #3
    Trusted Penguin
    Join Date
    May 2011
    Posts
    4,353
    Quote Originally Posted by DanglingChap View Post
    I am not going to ask that give me step by step procedure to do it, just some pointers, guidelines and keywords which will help me in google stuff.
    That is more refreshing than you know!

    I need something which supports ARM processor. For this reason I have shortlisted Debian and Android. Haven't decided which will be beneficial
    IMHO, Debian would be much better to start with, from a development perspective. Android is basically close-sourced and is much more of a process to dive into. There are other Linux ARM distros to choose from, too (Fedora, Ubuntu, Arch, etc.).

    I don't need most of the hardware modules of the kernel (except for io disks, storage etc). I have no idea that if i have kernel source how to delete/remove such modules. Searching with *remove modules custom kernel* comes up with results which aren't relevant
    if you want a custom kernel, look into the Documentation for compiling a Linux kernel. Start with the README file in the root of the kernel source. Selecting and de-selecting kernel/drivers modules is in the "make config" process of kernel compilation.

    I want to make the kernel boot from SD card ( I am able to get a decent resource on it). HOWEVER, What I want to ask that how can i emulate an SD Card to do testing ? I don't want to use real SD card for each custom kernel i build.
    Can you set up a Linux VM and do your kernel testing in that?

  4. #4
    Just Joined!
    Join Date
    Mar 2007
    Posts
    36
    Quote Originally Posted by atreyu View Post
    That is more refreshing than you know!


    IMHO, Debian would be much better to start with, from a development perspective. Android is basically close-sourced and is much more of a process to dive into. There are other Linux ARM distros to choose from, too (Fedora, Ubuntu, Arch, etc.).


    if you want a custom kernel, look into the Documentation for compiling a Linux kernel. Start with the README file in the root of the kernel source. Selecting and de-selecting kernel/drivers modules is in the "make config" process of kernel compilation.


    Can you set up a Linux VM and do your kernel testing in that?
    Awesome, thanks for answers ...

    One question regarding VM. Do i have to setup my vm with some special configurations or would it be a standard VM (custom installation) ?

    another question, I want my system to boot up quickly. So which distro would you recommend. I am right now looking into Debian and Ubuntu (after your reply). Do you think there should be another one which i should study too before making a final decision ? (p.s: I wouldn't need any GUI for linux as well .. It will be an embedded system)

  5. #5
    Trusted Penguin
    Join Date
    May 2011
    Posts
    4,353
    Quote Originally Posted by DanglingChap View Post
    One question regarding VM. Do i have to setup my vm with some special configurations or would it be a standard VM (custom installation) ?
    nothing special would be needed, as far as I can see.

    another question, I want my system to boot up quickly. So which distro would you recommend. I am right now looking into Debian and Ubuntu (after your reply). Do you think there should be another one which i should study too before making a final decision ? (p.s: I wouldn't need any GUI for linux as well .. It will be an embedded system)
    i could recommend others, but honestly Debian is probably the best choice for you, especially considering it is an embedded system. so many custom embedded Linux OSes out there are Debian-based for a reason. and the wealth of knowledge out there amongst debian hackers could fill volumes. plus, Debian has the widest array of pre-built packages (38k+).

    as to getting it to boot up quickly, what you should understand is that you can control much of that yourself, with a little know-how and experimenting. a lot of distros put work into booting up fast as a bragging right, but you can get a fast-booting system yourself with pretty much any Linux distro. The key things you need to look at are:

    1) the kernel itself. is it bloated w/extra drivers and functionality that you do not need?

    2) services and daemons and other software that are part of the start-up sequence. this is the area where you will have the most leverage.

    3) your hardware. the faster the processor, the faster your kernel will boot. and once the kernel turns over control to init and your drives get mounted, then a faster drive (like an SSD) will boot faster than an SD Card or a spinning hard disk.

  6. #6
    Just Joined!
    Join Date
    Mar 2007
    Posts
    36
    Quote Originally Posted by atreyu View Post
    nothing special would be needed, as far as I can see.


    i could recommend others, but honestly Debian is probably the best choice for you, especially considering it is an embedded system. so many custom embedded Linux OSes out there are Debian-based for a reason. and the wealth of knowledge out there amongst debian hackers could fill volumes. plus, Debian has the widest array of pre-built packages (38k+).

    as to getting it to boot up quickly, what you should understand is that you can control much of that yourself, with a little know-how and experimenting. a lot of distros put work into booting up fast as a bragging right, but you can get a fast-booting system yourself with pretty much any Linux distro. The key things you need to look at are:

    1) the kernel itself. is it bloated w/extra drivers and functionality that you do not need?

    2) services and daemons and other software that are part of the start-up sequence. this is the area where you will have the most leverage.

    3) your hardware. the faster the processor, the faster your kernel will boot. and once the kernel turns over control to init and your drives get mounted, then a faster drive (like an SSD) will boot faster than an SD Card or a spinning hard disk.
    Thank you for guidance

Posting Permissions

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