grub-pc fails install on BIOS machine

PROBLEM: Unable to install Parrot Security 4.4 64-bit on a-BIOS based machine from USB (Acer Aspire S3 model MS2346 sold with Windows 7). Installation process terminates with error “The ‘grub-pc’ package failed to install into /target/. Without the GRUB boot loader, the installed system will not boot.”.

DIAGNOSIS: System previous ran Security 4.1 64-bit without issue, but other Linuxes were installed for temporary testing. Both kali-linux-mate-2018.4-amd64.iso and FreeDOS 1.2 FD12FULL.img can be installed and boot successfully. Attempting a FreeDOS “fdisk /mbr 2” on the target device did not change the problem described. Installations were attempted from the boot menu and live installers. Skipping to the Continue menu an attempting to install LILO instead also failed with the error “An installation step failed. You can try to run the failing item again from the menu, or skip it and choose something else. The failing step is: Install the LILO boot loader on a hard disk.”

CURE: Unknown.

Parrot Security 4.4 64-Bit.

Installed by using Etcher to burn ISO to USB drive and then using either text-based installer from boot OR graphical installer from running live mode.

The system was not configured to multiboot.

The UEFI boot issue in this article was NOT found to be revealing:
https://community.parrotsec.org/t/grub-installation-failed/344

Thanks for any advice or suggestions.

you checked for bios updates and changed the bios settings to allow the boot right?

Thanks Nico_Paul. Yes. I verified BIOS settings by booting other OSes.

Thanks,
rcs

did you check for an update for your bios?

Try advanced install which is further down the list, it looks like it ends but it doesnt.

Use etcher for making bootable USB
Grub-pc package auto added

Thanks Amzker. Yes, I am using the latest BIOS release for an Acer Aspire S3-951 is 1.18 released on 30-Apr-2012.

Thanks Nico_Paul. I used the latest etcher release from the Debian and Ubuntu based Package Repository (GNU/Linux x86/x64) that was installed using the instructions at https://github.com/balena-io/etcher#debian-and-ubuntu-based-package-repository-gnulinux-x86x64.

can you try using etcher on windows just to be extra sure its not the writing?
i recommend booting live from usb written with balena etcher, dont use dd. and formatting your desired install disk with gparted not fdisk to clean it and then power down, and boot from the usb again but this time go past gtk install there should be an option that says advanced graphical install and try using that.

you added the balena etcher repo to your parrot USB?

Thanks Nico_Paul. I added the balena etcher repo to another system running Linux Mint. I only used FreeDOS and fdisk to try and wipe the master boot record, which was not effective. I have tried gparted wipes of the whole disk with manual or guided+whole disk configurations by the installer as well as just using partitions I created myself in gparted that I used manually from the installer. I will try using etcher on a Windows system instead as you suggest along with the gparted and graphical installs as suggested and advise.

yes, and between every format to clean or ext4/fat etc and install there should be a reboot so that each action is its own function and not dependent on anything else the installer needs or wants to invoke. how many OS on the system and how much space/ number of disks? which is the primary and first OS?

Thanks Nico_Paul. Sorry for the delayed response as it took some time to do everything suggested.

There is only one OS on the system using a single disk with 238.47 Gbytes according to gParted. The primary, first, and only OS is Parrot Security 4.4 64-bit.

balenaEtcher 1.4.9 x64 and x86 for Windows could not be downloaded on Windows using Firefox 64.0 32-bit but Chrome 71.0.3578.98 64-bit was successful. Although Virus Total gave the x64 and x86 versions a clean bill of health, metadefender.opswat.com reported that Filseclab found Adware.Domage.Neobar.BF.qpiw in a DLL. Accordingly I did not use any of them.

Many alternative USB writers are also reported as being virus-laden, many worse than balenaEtcher (Virus Total and Metadefender both reporting trojans, etc.). Others “clean” writers simply did not work, such as Microsoft’s Windows USB/DVD Download Tool which did not consider Parrot-security-4.4_amd64.iso a valid ISO. I finally used Rufus for Windows 10/8/7/XP release 3.4 (RufusPortable_3.4.paf.exe) from https://www.downloadrufus.com/ in FAT32 mode with a 4096 byte cluster size. Rufus under Windows is quite slow compared to balenaEtcher on Linux Mint.

First I booted from USB into Live mode and used gParted to erase all partitions from the single hard disk, executed Edit > Apply All Operations, then shut down.

Second I booted from USB into Live mode and created the following partitions in gParted:

ext4 /boot 1 Gbyte flags boot
ext4 / 32 Gbyte
linux-swap 4 Gbyte
ext4 /home 201.47 Gbyte

then executed Edit > Apply All Operations, then shut down.

Third I booted from USB again, and from the boot menu scrolled to the penultimate option Install near the bottom of the menu, but the options within were only {Standard Installer, Install with GTK GUI, Install with speech synthesis}. The final menu option was Advanced options, which only included Load system to RAM. So I booted into the Live mode and executed Menu > System Tools > Install Parrot. For Partition Disks I chose Manual and configured it as follows:

#1 use as: ext4; format the partition: yes, format it; mount point /boot; bootable flag: on;
#2 use as: ext4; format the partition: yes, format it; mount point /; bootable flag: off;
#3 use as: swap area; bootable flag: off;
#4 use as: ext4; format the partition: yes, format it; mount point /home; bootable flag: off;

then Finished Partitioning and write changes to disk, etc. After waiting for the entire system to install, the process finished with an error Grub installation failed. The ‘grub-pc’ package failed to install into /target/, etc. again. I did Go Back and then Abort the Installation.

Fourth I booted from a different USB created with a Linux x64 balenaEtcher 1.4.9 installed from their Debian repo with kali-linux-mate-2018.4-amd64.iso on it. In the boot menu I chose the Install option because Kail’s Graphical Install does not recognize the trackpad as a mouse on the Acer S3. I used the existing partitions created above with the same options. Kali had no issues installing the grub boot loader to the master boot record of /dev/sda, after which I shut down.

Fifth I booted from /dev/sda into the Kali root console boot as root and entered the startx command, which successfully brought up the Kali GUI environment (such that it is).

so with rufus it wont write correctly for the boot (grub-pc) partition. ive never heard of that malware alert brand but i know one thing and thats that (well a few things) we host a copy of balena etcher under our dopwnloads which are insanely secure. if you cant trust the download from us then yuouve got bigger problems, secondly, virus signatures are a joke so dont put too much stock, its def a false reading. the installer should not want to do ext4 but btrfs instead without swap partition. thats ok. do it. u guarantee if you do exactly that you will have a safe secure easy to install system.

Thanks Nico_Paul. Yes, I agree that virus signatures can often be a joke. A release hosted by Parrot would be great, but the only obvious one was an old 1.1.2 release from 2017 at https://cdimage.parrotsec.org/parrot/misc/etcher/. Unless you recommend this old release I will use the balenaEtcher-Setup-1.4.9-x64.exe from the balena site using the primary Parrot link (https://www.parrotsec.org/docs/getting-started/create-boot-device/#etcher) instead of the Linux one I installed earlier on a Linux Mint system. The next time I scrub with gParted I will use installer defaults for the filesystem types as you suggest, then report here on the results. I used filesystem defaults before I came to the support forum but had used the Debian etcher and had not tried the Windows etcher at that point. I appreciate your continued advice!

no problem! i think either of the etchers will be fine for you, you dont need to worry about usiong an old one unless it affected how it wrote and ive never heard of a single problem with their writing at least with windows exe so give that a go, what are you setting the format to in gparted to clean it?

Thanks Nico_Paul. Previously I have scrubed several different ways with no apparent difference. Do you have any suggestions?

I have no idea I’ve never heard of someone not succeeding when writing with etcher after disabling safeboot and using live gparted to format to clean and it not install. Did you try googling your laptop and debian install you could disable uefi a d see if that helps but I doubt it.

Can you post screenshots of the disk in gparted?

I ran into the same problem, but my solution was to NOT boot into the Live mode. When I started the install from the startup screen all went just fine. Both in text mode and the graphical environment.
Could be worth trying. Good luck!

2 Likes