I installed the android-x86-8.1-r2.x86_64.rpm package on Ubuntu 18.04 using the following commands as suggested by Release Note 8.1-r2 but it didn't add boot entries to the grub2 menu.
- sudo apt install alien
- sudo alien -ci android-x86-8.1-r2.x86_64.rpm
Question: What are the definitions of the boot entries I need to add to the 40_custom grub file in order to add android-x86-8.1-r2 to my grub2 boot menu?
Based on the answer below I tried adding the following menu entry to the 40_custom grub file. I also tried changing system.img to system.sfs.
menuentry "Android-x86 8.1-r2" --class android-x86 {
insmod part_gpt
search --file --no-floppy --set=root /android-8.1-r2/system.img
linux /android-8.1-r2/kernel root=/dev/ram0 androidboot.hardware=remix_x86_64 androidboot.selinux=permissive CMDLINE
initrd /android-8.1-r2/initrd.img
}
Based on How to Install Android in Dual Boot with Linux I also tried adding the following menu entry to the 40_custom grub file.
menuentry "Android-x86 8.1-r2" {
search --set=root --file /android-8.1-r2/kernel
linux /android-8.1-r2/kernel quiet root=/dev/ram0 androidboot.selinux=permissive
initrd /android-8.1-r2/initrd.img
}
Neither of the two menu entries above work. When I update grub it produces the following output which seems to indicate grub isn't recognizing the menu entry, and my computer continues to boot directly into Ubuntu 18.04.
Sourcing file `/etc/default/grub'
Generating grub configuration file ...
Found linux image: /boot/vmlinuz-4.18.0-25-generic
Found initrd image: /boot/initrd.img-4.18.0-25-generic
Found linux image: /boot/vmlinuz-4.18.0-15-generic
Found initrd image: /boot/initrd.img-4.18.0-15-generic
Found memtest86+ image: /boot/memtest86+.elf
Found memtest86+ image: /boot/memtest86+.bin
done
My computer hard drive has a single Linux ext4 partition, and the contents of /android-8.1-r2 are as follows:
drwxr-xr-x 2 root root
4096 Jul 21 09:40 data
-rw-r--r-- 1 root root
1358699 Jun 13 02:11 initrd.img
-rw-r--r-- 1 root root
7437056 Jun 13 02:11 kernel
-rw-r--r-- 1 root root
1424814 Jun 13 02:11 ramdisk.img
-rw-r--r-- 1 root root 877621248 Jun 13 02:11 system.sfs