modifying the original Linux kernel, say 2.6.34, to make it running as OS
Linux - KernelThis forum is for all discussion relating to the Linux kernel.
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.
View Poll Results: Your favourite distro is.......
I have downloaded the grub and the vanila linux kernel.
Now I should :
- run any Live (ubuntu 9.04) OS.
- install grub on it.(./configure)
- and then if i give it (to the grub) my kernel's path (residing in the pendrive : /dev/sda1)
then will it work ? may give some error ?
please guide me..
What functional platform are you using right now? You're going to have to build the kernel. Do that first. Format the pendrive with a boot directory. Put the kernel in the pendrive boot directory. If you are already running a functional Linux OS, you should be able to install grub on the pen drive without building grub from sources. Use grub-install. Use the grub config file on your existing Linux host as a model for how to configure it on the pendrive.
I wanna install grub/grub2 on my empty hard disk drive.
For that I boot my machine from ubuntu 10.04 Live OS
and tried to install it but failed.
So what to do now ?
Also I think some toolset , if I want to boot the vanilla Linux kernel (please suggest me the link for that) ,
So after I've installed the grub and required tool-set , (the one suggested by you, if any) then, all that I've to do is to just extract the kernel and boot it from that device or more procedure ?
Okay, we're going around in circles, here. Have you built a kernel, yet? Have you done even ONE THING I've suggested? If you have, please explain, showing error messages or other useful information how it failed. If you really want help, you have to start helping us. Phrases like 'tried to install it but failed' give no one enough information to be helpful. When someone asks you a question, it usually means the answer will lead to some helpful information. Please answer them.
--- rod.
okay you are 100% correct. That's mistake in the way I post.
I don't know how to get the name like /dev/sda or /dev/sda1 for my pendrive labeled "LOCALDISK".
so i tried as a root user
mount -t /media/LOCALDISK # just to be safe
grub-setup /dev/sda
grub-install /dev/sda
should i try ?
# grub-install --root-directory=/boot /dev/sda
root@aarsh-desktop:/# grub-install --root-directory=/boot /dev/sda
[and the ouput of the above command was...]
Installation finished. No error reported.
This is the contents of the device map /boot/boot/grub/device.map.
Check if this is correct or not. If any of the lines is incorrect,
fix it and re-run the script `grub-install'.
(fd0) /dev/fd0
(hd0) /dev/sda
(hd1) /dev/sdg
Additionally,
I put the Linux kernel (.tar.gz) into my pen drive. And choose extract here from right click menu.
and then deleted the compressed .tar.gz Linux.
So that's it I've done so far..
And it resulted into an instable system,
just showing me grub menu each time I boot, no matter the pen-drive is plugged or not.
so i wanna send you a snap shot of that, so how can i do that ?
Little or none of what you describe makes much sense. I will try to rephrase your objective, so I understand where you are and where you're going. You want to boot a new, possibly modified, kernel (without filesystem) from a pendrive, using a host that is presently running a Ubuntu distribution. If this is correct, you will have to do the following:
1. download a kernel source tarball, and unpack it somewhere in your host filesystem, where you (as a normal user) have write permissions. Some subdirectory below your $HOME would be ideal.
2. Configure & build the compressed kernel image.
3. Install grub on the pendrive.
4. Copy the kernel image to the pendrive boot directory
5. Modify the grub configuration to point to the kernel image.
6. Set up the host to boot from a USB device, and reboot.
Have you done steps 1 & 2, yet? What was the result of building the kernel?
If you have installed grub on /dev/sda, that is almost certainly not what you want. Except for a very unusual intallation, /dev/sda is your primary hard disk. The pendrive is likely to be /dev/sdb, /dev/sdc, or some higher device name, depending on what spinning media is already installed.
The Linux kernel tar.gz sounds more like it is the source tarball. This will do nothing for you in booting. You need to unpack it and build a kernel image from it. There are many online tutorials to explain this process, and they're easy to find. Don't try to build the kernel from the sources unpacked on a pen drive; it will take an eternity.
Frankly, from what you have described so far, I'm not certain you are pursuing any useful goal; you may be under some misunderstanding about what the elements of a Linux system are, and what they do. I think I tried to express that earlier in this thread.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.