Untitled

mail@pastecode.io avatarunknown
plain_text
a month ago
1.1 kB
1
Indexable
Never
# 20230822

echo "This script was made to be run under the Arch Linux live system environment."


# BOOT MODE
boot_mode=$(cat /sys/firmware/efi/fw_platform_sizef)
echo "Checking the boot mode of the system..."

# Verify the boot mode
if [ "$boot_mode" == 64 ]; then
    echo "Exit status is 64. System is booted in UEFI mode and has a 64-bit x64 UEFI."
elif [ "$boot_mode" == 32 ]; then
    echo "Exit status is 32. System is booted in UEFI mode and has a 32-bit IA32 UEFI; while this is supported (in Arch Linux), it will limit the boot loader choice to GRUB."
else
    echo "Exit status is something different. The file may not exist, meaning that the system may be booted in BIOS (or CSM) mode."
fi


# INTERNET
echo "Checking internet connectivity..."

ip link

# Check if internet works out of the box (DHCP)
echo "Pinging archlinux.org"
ping archlinux.org -c 3

echo "Pinging google.com"
ping google.com -c 3

echo "If the previous domains are out of range, it means you're currently disconnected from the internet and you must connect to continue with the installation. (netinstall)"