Troubleshooting Kali Linux Installation: Failed to Attach Disk
Abstract: Resolve Kali Linux installation failure by switching virtual disk controllers to SATA or IDE and verifying ISO integrity.
2026-08-10
Created: 2026-08-10 by
UserComp.com Editors
The "Failed to attach disk" error during Kali Linux installation typically stems from incorrect virtual disk controller settings in your hypervisor or improper ISO mounting. Resolving this requires verifying that the virtual machine is configured with a compatible storage controller, such as SATA or IDE, rather than SCSI or NVMe which may lack necessary drivers at boot time. Additionally, ensuring the ISO file is fully downloaded and correctly attached as a read-only optical drive often bypasses the attachment failure.
Verify Virtual Machine Storage Configuration
The most common cause for the inability to attach a disk during the initial stages of operating system installation is a mismatch between the virtual hardware controller and the boot media. Hypervisors like VMware Workstation, VirtualBox, or Hyper-V allow you to define how storage devices are presented to the guest OS. If the installer cannot see the CD/DVD drive, it will fail to proceed with partitioning or file copying tasks.
Check your virtual machine settings before starting the installation process. Navigate to the hardware configuration section and locate the Storage or CD/DVD Drive settings. Ensure that the connection type is set to SATA or IDE. While modern operating systems support various controllers, older versions of Kali Linux or specific minimal ISO images may not include drivers for newer interfaces like VirtIO or NVMe during the early boot phase. Switching to SATA is generally the safest default for compatibility across different hypervisor platforms.
If you are using VirtualBox, go to Settings > Storage. Under the Controller: IDE or Controller: SATA, click the empty optical drive icon. On the right side, select "Choose a disk file" and browse to your kali-linux-iso file. Make sure the checkbox for "Live CD/DVD" or "Pass-through" is unchecked unless you are using a physical disc. The ISO must be explicitly attached to the virtual optical drive slot.
For VMware users, edit the VM settings and select the CD/DVD drive. Choose "Use ISO image file" and point to your Kali Linux download. Verify that the device status is checked to ensure it is connected at power-on. Sometimes, the "Connect at power on" option is disabled by default, preventing the installer from detecting the media when the system boots.
Validate ISO Integrity and Download Completeness
A corrupted or incomplete ISO file can manifest as an attachment error because the hypervisor fails to mount the image properly. Before troubleshooting virtual hardware, confirm that the ISO file itself is valid. Check the file size against the official checksums provided on the Kali Linux website. A truncated download will result in an unreadable disc structure, causing the installer to abort.
If you suspect the file is corrupt, delete the existing ISO and re-download it from the official source. Use a download manager if available to prevent interruptions. After downloading, verify the SHA256 hash if possible. This step ensures that the binary data is intact and matches the expected release. An invalid ISO will not only cause attachment failures but also lead to kernel panics or package verification errors later in the installation.
Ensure that the ISO is not currently in use by another application. Lock files or background processes accessing the image can prevent the hypervisor from attaching it exclusively to the virtual machine. Close any file explorers or backup software that might have the ISO open.
Address Sudo Password and Permission Issues
The summary mentions a workaround for incorrect sudo password issues, which often occur after the initial disk attachment phase. Once the installer loads, it may prompt for user credentials. If you encounter permission denied errors, ensure you are entering the correct default credentials. For standard Kali Linux installations, the default username is root and there is no password by default, or you set one during setup.
If you are installing via a graphical interface, double-check that Caps Lock is off. Some virtual machines do not pass keyboard state correctly, leading to failed authentication attempts. If the installation proceeds but fails to create partitions due to permission errors, try running the installer with elevated privileges manually. However, this is rare for standard GUI installers.
In cases where the system booted but you cannot gain root access, check the /etc/shadow file permissions. Incorrect permissions here can block sudo operations. Resetting the password via single-user mode is a more advanced recovery step. Ensure that the virtual machine's network adapter is set to NAT or Bridged if online repository updates are required post-installation.
Frequently Asked Questions
Why does Kali Linux say "No Bootable Device" after attaching the disk?
This usually means the ISO was not set as the primary boot order. Enter your BIOS/UEFI settings in the hypervisor and move the CD/DVD drive to the top of the boot priority list. Save changes and restart the virtual machine to trigger the installer from the optical drive.
Can I use an NVMe controller for Kali Linux installation?
While newer versions of Kali support NVMe, it is risky for fresh installations due to potential driver mismatches. Stick to SATA or IDE controllers for the installation phase to guarantee stability. You can switch to NVMe for the hard disk after the OS is installed and updated.
What should I do if the ISO file is recognized but installation hangs?
This indicates a corrupt ISO or insufficient RAM allocation. Allocate at least 4GB of RAM to the virtual machine. Re-verify the ISO checksum and redownload if necessary. Also, ensure hardware virtualization (VT-x/AMD-V) is enabled in your host computer's BIOS.
How do I fix "Permission Denied" when trying to write to the disk?
Ensure you are running the installer as root. In the terminal, use sudo -i to gain a root shell. If using a GUI installer, verify that you entered the correct password. Default Kali installs often require setting a root password during the first boot sequence.
Is it safe to ignore the "Failed to attach disk" warning and continue?
No, the installation cannot proceed without access to the source media. Ignoring this error will leave the system uninstalled. You must resolve the attachment issue by correcting the virtual hardware settings or replacing the ISO file before attempting to start the installation again.