GeneralThis forum is for non-technical general discussion which can include both Linux and non-Linux topics. Have fun!
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.
LILO stands for "Linux Loader" and that's a good description of what it is. It can only boot Linux. Well, that's not quite true; lilo comes with a chainloader which it can also boot, and which can then boot early versions of Windows, but nobody uses those now. Lilo can't boot a modern NTFS-based Windows and I doubt if it could boot Android either.
GRUB stands for "Grand Unified Bootloader" and again, it's a good description. Grub can boot just about anything. That's why everybody uses it now. Personally I hate grub because it's so complicated. I use lilo whenever I can; it's just as good as grub on a pure Linux system and much easier to understand. But grub wins hands down on a mixed (multiboot) system.
It's not true that nobody uses lilo. Crux uses it and Slackware was using it too when I last looked.
[GO TO the final paragraph where the real question is if you like.]
I tried Didier's link to no avail. Then I went on reading the grub info file. And this is what I've done, having been rewarded by success.
(a) I installed Android 4.4.2 in partition 7. Mount it on /media.
(b) I created a small partition[, partition 8. Mount it on /mnt/boot.
(c) > mkdir /mnt/boot/android-4.4-r2
> cp /media/android-4.4-r2/* /mnt/boot/android-4.4-r2
> cp -r /media/grub /mnt/boot
(d) Crear /mnt/boot/grub/grub.cfg con vim con el siguiente contenido:
default=0
timeout=6
menuentry "Android KitKat" {
set root='(hd0, 7)'
linux /android-4.4-r2/kernel quiet root=/dev/ram0
androidboot.hardware=android_x86 SRC=/android-4.4-r2
initrd /android-4.4-r2/initrd.img
}
hd0 is sda, hd1 is sdb and so on. 7 is the 7th partition.
(e) > grub-install --boot-directory=/mnt/boot /dev/sda
(f) Reboot
(g) End of procedure.
You can choose to let the OS installer to create a grub.cfg to
see how it looks. It's pretty much like that listed above,
but it had (hd0, 6) instead of (hd0, 7) [????]
I wanted to make it simple, so I did not installed slackware.
Now, I guess the grub.cfg file for Slackware 14.1 won't be much different but, just in case, I would like somebody to guide me in the process if you don't mind. The lilo.conf I use is (essentially):
Code:
boot = /dev/sda
image = /boot/vmlinuz
initrd = /boot/initrd.gz
root = /dev/sda5
label = 14-32
read-only # Partitions should be mounted read-only for checking
The Grub entry in your initial post is in the format used by Grub Legacy while the entry in your last post is in Grub2 Format. They are not interchangeable. Your comment about "(hd0,6) instead of (hd0,7) is one difference between Grub Legacy and Grub2. Grub Legacy counts drives and partitions from zero while Grub2 counts drives from zero and partitions from one. So in Grub Legacy, sda7 is equal to (hd0,6) and in Grub to it is equal to (hd0,7).
I'm not sure what your question is, but if you want to boot Slackware on sda5 from the Grub2 in Android, the entry below should chainload to Slackware. Not enough info to give a direct boot entry.
Lilo can't boot a modern NTFS-based Windows and I doubt if it could boot Android either.
I installed the 32bit version (non-UEFI) of windows 10 several weeks ago and put the entry below in lilo.conf on Slackware which chainloaded to boot windows 10.
Two things, then: can't Android be booted by LILO? Consider 4.4.2 is a deprecated version, I mean, perhaps it not being so modern, it can. One, and the other: in case it can't, I gave the exact entry I have in lilo.conf to boot Slackware. Anything else you need (I'd like to boot Slackware directly from the initial bootloader)?
However, after the CPU begins running the kernel, it says "Detecting Android ......." and fills the screen with periods and never ends. I must be doing something wrong.
I downloaded and isntalled Android and tried to boot with an entry similar to this post and got the same result you did. I reinstalled it and installed Grub Legacy on Android and ran lilo again from Slackware. I got a message in the lilo output indicating the boot sector had a problem (didn't write it down so don't remember it exactly). The basics of it was that Grub was not installed correctly. Since Android by default uses Grub Legacy, I reinstalled Grub Legacy from another Linux system and then put the entry below in lilo.conf, re-ran lilo and booted it sucessfully from the Slackware Lilo boot menu. The problem I had was that Android did not install Grub correctly.
Code:
other = /dev/sdb10
label = android
The entry above is basically a chainload entry and a bootloader needs to be in the correct place on the partition for it to work. I would expect your entry or something similar to work and don't really know why it didn't.
The entry above is basically a chainload entry and a bootloader needs to be in the correct place on the partition for it to work.
I remember that DOS had, in the first sector of each partition, a set of data belonging to the partition, the Bios Parameter Table, and executable code. This, then, would be a bootloader? And when you put boot=/dev/sdaN in lilo.conf, that would put the lilo bootloader in the first sector of partition N?
I installed Android in partition 7 and told it to install the Grub bootloader. I suppose it put it in the first disk sector. Anyways it wrote a menu.lst. Then I booted in linux, and mounted /dev/sda7 on /mnt/boot, with menu.lst renamed to grub.cfg and issued the following command:
Code:
root@server:~# grub-install --boot-directory=/mnt/boot /dev/sda7
/usr/sbin/grub-bios-setup: warning: File system `ext2' doesn't support embedding.
/usr/sbin/grub-bios-setup: warning: Embedding is not possible. GRUB can only be installed in this setup by using blocklists. However, blocklists are UNRELIABLE and their use is discouraged..
/usr/sbin/grub-bios-setup: error: will not proceed with blocklists.
root@server:~#
Then I repeated the procedure but telling Android to format in ext3. I thought I had an ext3 fs now but to my surprise I found I still had ext2. Well, this I should ask in an Android forum, but my proceeding, puting /dev/sda7 instead of /dev/sda in the grub-install command line was right, isn't it?
The image line in Lilo should tell the Lilo bootloader on your Slackware partition where to look (which partition) for the kernel on the android partition.
I'm not sure why you changed the name of the menu.lst file to grub.cfg? menu.lst or grub.conf are the default names for the Grub Legacy boot menu file, what you see on-screen when you boot. grub.cfg does the same for Grub2.
If you installed Grub in Android, did you try booting with the lilo entry I suggested above, the 'other' entry? If Grub installed to your android partition, it should chainload from Lilo.
In order for the command above to be successful, you would first need to create a boot directory in Android which it does not do in a default install. Mounting android at /mnt/boot you would then need the path to be: /mnt/boot/android-4.4-r2/boot
Are you now trying to install Grub2 to the Android partition and forgetting about booting it from Lilo?
The Grub2 entries I have on various distributions all have the 'insmod ext2' entry even though the filesystems are ext4 so I wouldn't worry about it.
Android installs Grub Legacy by default and you are trying to install Grub2 so you need to decide which to use, either should work but Grub Legacy is simpler to install. Good luck with it.
Well, a friend of mine, who does not know anything about computers, has Android 4.4.2 on it's tablet. I wanted to install that OS in my notebook to get familiar with it and be able to help my friend. So, anotther OS won't do.
I wanted to install that OS in my notebook to get familiar with it and be able to help my friend. So, anotther OS won't do.
If you are referring to the suggestion above to use 'Syslinux', it is another bootloader and not an operating system. Syslinux is used on most CD/DVD and installation media to boot them.
If you have the default Grub Legacy installed to the boot sector of the android partition, the 'other' entry I posted above should work. At least it worked on my system.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.