"Having problems with multi-booting operating systems"
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.
"Having problems with multi-booting operating systems"
I have windows 7 ultimate 32-bit installed and backtrack 5 r3 32-bit dual booted on the same hard disk.Now, I want to install android x86 on the same HDD.I have tried installing it while dual booting win 7 and backtrack but after the installation of android x86, backtrack gets removed from the grub boot list.I really want to boot those 3 operating systems in my HDD.
Thanks for help.
Where is your grub installation (i.e. the actual grub.cfg in use)? On the Backtrack partition or the Android partition?
It could have happened that the grub was overwritten and the new one points to a grub.cfg (where the grub menu list is found) on the Android partition.
If it is on the Android partition, you can boot into Android and update grub from there (assuming you have grub in Android).
On the other hand, if the grub is on the Backtrack partition, then try to boot into the Backtrack manually and then update grub from inside there.
I think what you have to enter at the grub command line is:
Code:
> insmod ext2
> set root='(hdX,Y)'
> linux /boot/vmlinuz-${VERSION} root=UUID=${UUID_OF_PARTITION_OF_BACKTRACK} ro text
> initrd /boot/initrd.img-${VERSION}
You should replace hdX by the hard disk you're using (e.g. hd0), and replace Y by the partition number of the Backtrack.
Replace ${VERSION} just after the vmlinuz by your kernel version and ${UUID_OF_...} by the uuid of the partition of the Backtrack.
Finally replace ${VERSION} of the initrd by the version you have in the /boot directory there.
You can have all these information by looking at the /boot directory. The uuid can be obtained by looking into a /dev/disk/by-uuid directory if you have it in Android or from a Live CD.
Where is your grub installation (i.e. the actual grub.cfg in use)? On the Backtrack partition or the Android partition?
It could have happened that the grub was overwritten and the new one points to a grub.cfg (where the grub menu list is found) on the Android partition.
If it is on the Android partition, you can boot into Android and update grub from there (assuming you have grub in Android).
On the other hand, if the grub is on the Backtrack partition, then try to boot into the Backtrack manually and then update grub from inside there.
I think what you have to enter at the grub command line is:
Code:
> insmod ext2
> set root='(hdX,Y)'
> linux /boot/vmlinuz-${VERSION} root=UUID=${UUID_OF_PARTITION_OF_BACKTRACK} ro text
> initrd /boot/initrd.img-${VERSION}
You should replace hdX by the hard disk you're using (e.g. hd0), and replace Y by the partition number of the Backtrack.
Replace ${VERSION} just after the vmlinuz by your kernel version and ${UUID_OF_...} by the uuid of the partition of the Backtrack.
Finally replace ${VERSION} of the initrd by the version you have in the /boot directory there.
You can have all these information by looking at the /boot directory. The uuid can be obtained by looking into a /dev/disk/by-uuid directory if you have it in Android or from a Live CD.
Thanks for the reply.
I'm really sorry but I wasn't able to understand much from your reply (as I am a newbie).
How can be we manually boot backtrack?
During the installation of android x86 it was said to install/update grub. I entered "yes" so, by the "overwritten of grub" did you mean this?
I wasn't able to understand the code so, would you please explain it for me in simple English.
Yes, you are confirming what I said. You probably overwrote the existing grub.
When the grub screen appears below the menu there is usually a set of instructions saying:
Press Enter to boot selected OS, 'e' to edit commands before booting and 'c' for a command-line.
Now, you must understand that everything you do is a command, even if you simply click on something, a command gets run in the background. For grub, it is the same. If you simply press enter on a menu option, in the background the grub software will run a specific command corresponding to your choice to boot a particular system.
Now, if you press 'e' instead of pressing Enter, you will actually see that command in full. If you press 'c' you will be directed to a command line where you can enter the command manually, and I agree you have to have some experience to use that command line.
So, you understand that you can boot the Backtrack manually from the command line if you know exactly where it is found, on which hard disk and which partition. The commands I gave previously can potentially do that if you replace the correct values corresponding to your machine.
If the commands do not work, try to use a live CD, mount the Backtrack partition and look at the /boot/grub/grub.cfg file. It is where grub keeps its configurations, and the specific command to boot the Backtrack is found there.
Continue to read around and build some background. There is a solution to every problem on Linux.
So, as far as I know I have to replace "Y" by the no. of partitions of android x86 if I want to manually boot android.
The main problem is that android x86 doesn't create a HDD partition like BT or other OS but, it resides in the windows or BT partition. In my case it is residing in the windows partition of my HDD.
Based on that I would guess you didn't read the android installation how-to which is at the link below and specifically states:
Quote:
Note the installer only creates boot items for Android-x86. If you hope to boot other operating systems, you need to add the item to /grub/menu.lst manually.
Which means you will need to boot the Android and go to the /boot/grub/menu.lst file and put entries in it manually to boot windows and/or Backtrack. Or you can chroot into Backtrack and re-install Grub2 and update-grub.
Is it possible that nothing was overwritten, but just maybe the boot option didn't show up. You can press add boot option, and without having to type anything go the file names and press the file with the name of the OS your mssing. Then it should list more files (the files should look like example.something) and click on those files, and it should then automatically insert itself.. Then give the boot option a name (I don't think the name matters). However I'm not sure what file it would be though for your OS, just try em all..
Last edited by bluesclues227; 04-21-2016 at 03:34 AM.
in the directory /dev/disk/by-uuid you will have a long listing format and you will see which uuid is linked to which partition. You simply have to copy the uuid linking to the Backtrack partition.
Make sure the Y from above is replaced by the Backtrack partition's number, and that all the vmlinuz versions are as on the Backtrack partition.
If it does not work, mount the Backtrack partition and browse through the boot directory there and get all the necessary correct information.
When you boot Android, navigate to the /boot/grub directory. Do you have a grub.cfg file there? According to the Android site I linked above, it still uses Grub Legacy and if that is the case, there will be no grub.cfg file and all the suggestions above for modifying the grub.cfg file for Grub2 won't help. You can simply put a chainload entry in the menu.lst file of Android pointing to whichever partition holds backtrack then boot it. There is an example entry on the page. If you want to use the Backtrack bootloader, you can then install Grub2 while booted to it and then update grub. I'm not sure how the update-grub will find Android if it's on the same partition as windows but I've not used Android.
I typed everything on the command line of grub but after pressing enter after the last bit of code
nothing happens.
I have checked everything and it's all correct.
Now, what should I do?
Yes, you guessed it right. Grub will not see the android like that.
I am not sure about the next step, but I will assume that as you can boot into Backtrack manually, you will certainly be able to boot into the Android manually if you know the necessary commands.
But, this time, let us try to add the entry manually to the /boot/grub/grub.cfg file so that you have it as an option when grub boots at startup.
To be clear: all the commands you typed manually to boot the Backtrack can be added to the grub.cfg so that you have the option in the menu, e.g.
Code:
menuentry "Backtrack" {
insmod ext2
set root='(hdX,Y)'
linux /boot/vmlinuz-${VERSION} root=UUID=${UUID_OF_PARTITION_OF_BACKTRACK} ro text
initrd /boot/initrd.img-${VERSION}
}
And you would have that option in your grub menu. NOTE: here you don't have to type the "boot" at the end.
So, similarly, you could add the Android x86 manually to the grub.cfg in Backtrack, assuming that it is the Backtrack's grub which is installed in MBR.
You add something like this:
Code:
menuentry "Android-x86" {
set root=(hdX,Y)
linux /android-${VERSION}/kernel quiet root=/dev/ram0 androidboot_hardware=YOUR_HARDWARE acpi_sleep=s3_bios,s3_mode SRC=/android-${VERSION} DATA= vga=788
initrd /android-${VERSION}/initrd.img
}
Again, there are lots of things you have to replace. A clever way to know how the entry should be is to have a peek at the grub configuration file of the Android x86 on the NTFS partition. Try to read it and I'm sure you will figure it out by yourself.
All the best.
Last edited by aragorn2101; 04-23-2016 at 04:55 AM.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.