Setting up Archcraft, a minimal Linux distribution based on Arch Linux, on your system alongside Windows can significantly enhance your workflow, especially if you’re into customization and lightweight systems. Archcraft offers the flexibility of Arch with minimal bloat, making it perfect for users who prefer a lean, highly-configurable environment. This article will walk you through the process of setting up Archcraft with BCDEdit, a Windows command-line tool used for managing the bootloader, to create a dual-boot environment.
Prerequisites
Before diving into the process, ensure you have the following:
- A Windows system installed on your PC.
- A bootable Archcraft ISO (can be created via tools like Rufus or BalenaEtcher).
- At least 20GB of free space on your disk for Archcraft.
- A USB drive with 8GB or more capacity for installation.
- Basic knowledge of working with Windows command-line tools and Linux commands.
Step 1: Prepare Your System
1.1. Backup Your Data
Before setting up a dual-boot system, make sure to back up all your essential files. There is always some level of risk when modifying partitions or boot configurations, and a backup ensures your data stays safe.
1.2. Create Free Space for Archcraft
In order to install Archcraft, you need unallocated space on your hard drive. Here’s how to shrink an existing partition:
- Open Disk Management in Windows (press
Windows + R
and typediskmgmt.msc
). - Right-click on an existing partition with enough free space and select Shrink Volume.
- Allocate at least 20GB (recommended) of unallocated space.
Step 2: Create Archcraft Bootable USB
- Download the latest Archcraft ISO from the official Archcraft website.
- Use a tool like Rufus to create a bootable USB:
- Select your USB drive in Rufus.
- Choose the Archcraft ISO.
- Set the partition scheme to MBR if your system uses BIOS or GPT for UEFI systems.
- Click Start and wait for the process to complete.
Step 3: Boot from the USB and Install Archcraft
- Insert the bootable USB into your PC and restart the system.
- Enter the BIOS/UEFI setup by pressing the appropriate key during boot (usually
F2
,F10
,DEL
, orESC
). - Select the USB drive as the boot device.
Once you’re inside the Archcraft live environment:
3.1. Partition the Disk
- Open a terminal by pressing
Ctrl + Alt + T
. - Use the
fdisk
orcfdisk
tool to create new partitions. For example:- A root partition (
/
) with ext4 (20GB+). - A swap partition (optional, about 2GB if you need it).
- A root partition (
cfdisk /dev/sda
- Write the partition table and exit the tool.
3.2. Mount the Partitions
Mount your newly created partitions using the following commands:
mount /dev/sda1 /mnt # Mount root partition
mkdir /mnt/boot # Create boot directory (if needed)
3.3. Install the Base System
Run the following command to install the essential packages:
pacstrap /mnt base linux linux-firmware
3.4. Generate fstab and Set Up the System
Generate an fstab
file to define how partitions will mount during boot:
genfstab -U /mnt >> /mnt/etc/fstab
Chroot into the new system:
arch-chroot /mnt
Set the timezone, locale, and root password:
ln -sf /usr/share/zoneinfo/Region/City /etc/localtime
hwclock --systohc
echo "LANG=en_US.UTF-8" > /etc/locale.conf
passwd
3.5. Install GRUB Bootloader
Install and configure GRUB:
pacman -S grub
grub-install --target=i386-pc /dev/sda # For BIOS systems
grub-install --target=x86_64-efi --efi-directory=/boot --bootloader-id=GRUB # For UEFI
grub-mkconfig -o /boot/grub/grub.cfg
Exit the chroot environment and reboot:
exit
reboot
Step 4: Boot into Windows and Configure BCDEdit
After installing Archcraft, the GRUB bootloader will likely take precedence. However, if you’d prefer to use BCDEdit to manage the bootloader and add Archcraft to the Windows Boot Manager, follow these steps:
- Boot into Windows.
- Open a Command Prompt as Administrator (search
cmd
, right-click, and select Run as Administrator).
4.1. Add Archcraft to Windows Boot Manager
BCDEdit allows you to configure entries for non-Windows operating systems. Use the following commands to add Archcraft:
- First, find the drive letter where Archcraft is installed. Use:
diskpart
list volume
exit
- Once you’ve identified the partition where GRUB or Archcraft resides, assign a letter (if it doesn’t already have one). For example, assume it is assigned to
D:
. - Create a new boot entry using BCDEdit:
bcdedit /create /d "Archcraft Linux" /application BOOTSECTOR
- The command will return a unique identifier (GUID). Use it in the following steps, replacing
{GUID}
with the actual value.
bcdedit /set {GUID} device partition=D:
bcdedit /set {GUID} path \boot\grub\boot.img
bcdedit /set {GUID} description "Archcraft Linux"
- Now, make sure the boot order prioritizes Windows Boot Manager with the Archcraft entry available:
bcdedit /displayorder {GUID} /addlast
- Verify your changes:
bcdedit /enum
Step 5: Reboot and Test Dual Boot Configuration
- Restart your computer.
- When your PC boots, you should now see the Windows Boot Manager with an option to boot into Archcraft Linux.
- Select Archcraft Linux to ensure everything is working as expected.
Step 6: Troubleshooting Common Issues
If you encounter any problems during the setup, here are some potential solutions:
- Issue: Windows Boot Manager doesn’t show Archcraft.
- Make sure the boot entry was correctly added with BCDEdit. Run
bcdedit /enum
to verify the settings. - Ensure that the GRUB bootloader is correctly installed and accessible from the partition you specified.
- Make sure the boot entry was correctly added with BCDEdit. Run
- Issue: GRUB is not installed or misconfigured.
- Boot back into the Archcraft live USB, chroot into your system, and reinstall GRUB.
- Issue: Windows overwrites the bootloader.
- You can always restore the boot entry using BCDEdit. Additionally, disable Fast Startup in Windows, as it can sometimes interfere with dual-boot setups.
Step 7: Optimize the System (Optional)
- Update Archcraft:
After installation, update your system using:bashsudo pacman -Syu
- Install a Desktop Environment or Window Manager:
If you installed a minimal Archcraft setup, consider installing lightweight environments like Openbox or LXQt:bashsudo pacman -S openbox lxappearance
- Customize GRUB (Optional):
You can modify the GRUB theme or timeout settings by editing the/etc/default/grub
file.
Conclusion
Setting up Archcraft alongside Windows with BCDEdit provides the best of both worlds: the flexibility and customization of Linux with the familiarity of Windows. By following this guide, you should now have a fully functional dual-boot system managed through the Windows Boot Manager.
This setup allows you to switch between operating systems efficiently while retaining full control over your boot process. Whether you’re using Archcraft for programming, customization, or as a daily driver, you now have a powerful system ready to go.
Frequently Asked Questions (FAQs)Â Archcraft with BCDEdit:
1. Can I install Archcraft alongside Windows without affecting my Windows installation?
Yes, you can install Archcraft alongside Windows without affecting your existing installation. However, it’s crucial to back up your data before proceeding and carefully manage disk partitions to avoid accidental data loss.
2. What is BCDEdit, and why do I need it for dual booting?
BCDEdit is a command-line tool in Windows used for managing the Boot Configuration Data (BCD). It allows you to add, modify, and delete boot entries, making it essential for setting up dual-boot configurations. By using BCDEdit, you can integrate Archcraft into the Windows Boot Manager, enabling you to choose which operating system to boot into.
3. What should I do if Archcraft does not appear in the Windows Boot Manager?
If Archcraft does not appear in the Windows Boot Manager, ensure that you have correctly added the boot entry using BCDEdit. You can verify your settings by running bcdedit /enum
in an elevated command prompt. If it still doesn’t work, try reinstalling GRUB from the Archcraft live environment and re-add the entry with BCDEdit.
4. Will updates to Windows affect my Archcraft installation?
Typically, updates to Windows should not affect your Archcraft installation directly. However, major updates or changes to the Windows bootloader may reset the boot configuration, requiring you to reconfigure BCDEdit to restore access to Archcraft. Regularly backing up your boot settings can help mitigate potential issues.
5. Can I remove Archcraft later if I no longer want it?
Yes, you can remove Archcraft from your system. To do this, you will need to delete the Archcraft partitions using Disk Management in Windows and then use BCDEdit to delete the Archcraft boot entry. Running bcdedit /delete {GUID}
(replacing {GUID}
with the actual identifier) will remove the boot entry from the Windows Boot Manager.