Is it possible to install Linux Kernel on a bare machine?
Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Is it possible to install Linux Kernel on a bare machine?
Hi,
Actually, I just bought a new laptop which has DOS support only.
Now I can install any Windows distribution or any other Linux distributions using DVDs or live CDs.
What, I just want to know that without installing any other Linux distribution, is it possible to install the Linux kernel onto my Laptop.
Means Is it possible to just download the latest Vanila-Kernel from http://www.kernel.org/ and install the same using some bootloader.
Yes, but it would be useless. Linux is less than DOS. You will not have the real command prompt, only the basic kernel one, used for debugging purposes. You wont be able to do anything useful at all. You also need to compile it first. It is like having an engine without a car, don't expect to drive anywhere with it. Just like an engine, it will start* , "do something", but alone, it won't be enough. But it is nice to try, just for fun. It is very educational.
*(given there is gas inside the engine and ignition power, just like the computer have to be plugged and you need to press the power button)
Can you just let me know, How to start this engine alone :-)
I mean to say, where to compile the Kernel source code, because we are not having any other ditros so we don't have the libraries required for compilation of kernel source code.
Again, if compilation is possible(I am assuming that you will provide me some suggestion like compiling the kernel using some other computer or something), then what would be the next steps like how configure the kernel for the specific architecture and all that.
To better understand how to create a minimal bare bones Linux system you may want to have a look at Linux from Scratch: http://www.linuxfromscratch.org/lfs/
Can you just let me know, How to start this engine alone :-)
I mean to say, where to compile the Kernel source code, because we are not having any other ditros so we don't have the libraries required for compilation of kernel source code.
Again, if compilation is possible(I am assuming that you will provide me some suggestion like compiling the kernel using some other computer or something), then what would be the next steps like how configure the kernel for the specific architecture and all that.
The best way is to compile it in another Linux distributions. There is very little libraries dependencies as the kernel can not use libraries, as such, it does not require any. The only ones are used by the compiler itself. You could compile it in Mac OSX with xcode command line utilities installed or in Windows with much, much more preliminary setup, but it is harder than seflhosting it (compile Linux in Linux). I am not stating it is impossible, but it is impractical. Just download a distribution and win it in a VM if you don't want to install it. The compilation does not have to take place on the same computer.
Then, just install a bootloader capable of running Linux and point it to the executable. There is no other step required just to have Linux to start. Again, it wont do anything. It will just print some text then an error ().
You can create a kernel that will self-load from the MBR of a PC. You may be able to find one already built for you. You can use a live CD to provide the dd command to write the kernel image file to your hard disk. As others have said, it will do approximately four-fifths of the square-root of diddly-squat. I feel certain that this is the very ablsolute minimum Linux possible.
EDIT: The OP asked about installing with a bootloader. In most common usage, a bootloader is used to boot a kernel into memory from storage somewhere. A kernel is 'installed' by storing it in that place from where the booloader fetches it. If the question intended some other context, then the OP should clarify.
I think the Linux from Scratch is the way you are asking about.
You could even get something like zipslack and run it on a umsdos filesystem.
I assume you have either a new laptop with freedos or a very old laptop with some version of DOS. If this is an old system you may not get linux to run.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.