To delete Linux partitions from an iMac (2017 27") running macOS, open Disk Utility, select the physical internal drive from the sidebar rather than a specific volume, click the "Partition" button, and remove the Linux entries by selecting them and clicking the minus sign. This action merges the freed space back into your main macOS APFS container, ensuring your storage is fully utilized without leaving unallocated gaps or corrupting the boot sector.
Preparing Your System for Partition Modification
Before attempting to modify disk structures, it is critical to ensure that no data resides on the Linux Mint partitions you intend to remove. Since these partitions are separate from your macOS environment, they do not interfere with your current operating system's files, but any personal documents stored within the Linux file system will be permanently erased during this process. If you have important data in Linux, back it up to an external drive or cloud storage before proceeding.
Additionally, ensure that your iMac is connected to a power source if it were a laptop, though as a desktop iMac, this is less of a concern. However, verify that no other processes are actively writing to the disk. While macOS generally locks its own system volumes, third-party tools or mounted network drives could potentially cause conflicts. It is also advisable to run a quick diagnostic check using the built-in First Aid feature in Disk Utility on your main macOS volume to confirm there are no existing file system errors that might complicate the partitioning process.
Accessing Disk Utility and Selecting the Correct Drive
The most common mistake users make when managing dual-boot setups is selecting the wrong level in the Disk Utility hierarchy. You must work at the physical device level, not the logical volume level. To begin, open the
Applications folder, then navigate to
Utilities, and launch
Disk Utility.app. Alternatively, you can use Spotlight search by pressing
Command + Space and typing "Disk Utility."
Once Disk Utility opens, look at the left-hand sidebar. By default, it may only show volumes. To see the underlying physical hardware, go to the menu bar and select
View, then choose
Show All Devices. This expands the tree structure. Locate your internal drive, which is typically named something like "APPLE SSD SM0256G" or similar, depending on your storage capacity. Click on this top-level physical drive name, not the "Macintosh HD" volume beneath it. This distinction is vital because partitioning changes affect the physical layout of the disk, not just the logical containers.
Removing Linux Partitions via the Partition Interface
With the physical drive selected, click the
Partition button located in the toolbar at the top of the window. This will display a pie chart representing the current disk layout. You should see several slices: your macOS APFS container, possibly a recovery partition, and the Linux Mint partitions (often labeled as ext4, swap, or EFI).
To delete the Linux partitions, click on one of the Linux slices in the diagram to highlight it. Then, click the
- (minus) button below the diagram. Repeat this for each Linux partition you wish to remove. As you remove them, the gray area representing free space will grow. Ensure that only your macOS partition remains alongside any necessary system partitions like the Recovery HD. Do not delete the Recovery partition or the EFI system partition unless you are completely wiping the machine for resale, as macOS relies on these for booting and diagnostics.
After removing the unwanted partitions, you will notice that the remaining macOS slice may not automatically expand to fill the entire disk. To fix this, click on the macOS slice (usually labeled "Macintosh HD" or part of the APFS group) and drag its edge to fill the available space, or simply ensure the layout looks contiguous. Once satisfied with the arrangement, click
Apply. Disk Utility will warn you about data loss; since you are deleting Linux partitions, this warning is expected. Confirm the action, and wait for the process to complete. This may take several minutes depending on the speed of your SSD.
For more information on managing disk issues, you might find our guide on
Troubleshooting Time Machine Partition Issues helpful, as partition changes can sometimes impact backup configurations.
Verifying the Cleanup and Restoring Normal Functionality
Once Disk Utility reports that the operation is complete, close the application. Your iMac now has a single large macOS partition. Restart the computer to ensure the firmware recognizes the new layout. Upon reboot, you should no longer see the GRUB bootloader menu asking you to choose between macOS and Linux. The Mac should boot directly into macOS.
If you had previously disabled FileVault encryption or used other security features that interacted with multiple partitions, verify that your encryption status is intact by going to
System Preferences >
Security & Privacy >
FileVault. Additionally, check your available storage by clicking the Apple menu >
About This Mac >
Storage. The total available space should now reflect the sum of your previous macOS allocation plus the space formerly occupied by Linux Mint.
If you encounter any boot issues, such as the Mac failing to start, it is likely due to corrupted EFI variables. In rare cases, resetting the NVRAM/PRAM by holding
Option + Command + P + R during startup can resolve post-partition boot glitches. However, for standard dual-boot removals, this step is rarely necessary.
Finally, consider updating your Time Machine backups. Since the disk structure has changed, your next full backup will be larger as it rescan the newly unified volume. Ensure your backup destination has sufficient space. For tips on optimizing storage management, reading about
Formatting Drives for Compatibility can provide broader context on how macOS handles different filesystem types, even though NTFS is not native to Mac.
Frequently Asked Questions
Will deleting Linux partitions erase my macOS data?
No, deleting Linux partitions does not affect your macOS files or applications. The process only removes the sections of the hard drive dedicated to Linux Mint. As long as you select the correct physical drive and only remove the Linux slices in Disk Utility, your Macintosh HD remains untouched and secure.
What if I accidentally delete the Recovery HD partition?
If you delete the Recovery HD, you can restore it later by restarting your Mac while holding
Command + Option + R to internet recover the latest compatible macOS version. This will reinstall the recovery partition along with the operating system. Always double-check the partition labels before clicking apply to avoid accidental deletion of system-critical slices.
Can I merge the freed space without using Disk Utility?
While command-line tools like
diskutil can resize APFS containers, using Disk Utility is the safest and most visual method for most users. The terminal equivalent would involve identifying the disk identifier and using
diskutil apfs resizeContainer, but this requires precise knowledge of your disk IDs and carries a higher risk of error if misused.
Why doesn't my storage show the full capacity after deletion?
APFS containers often require manual adjustment after partition changes. If the free space appears as "unallocated" in the About This Mac section, return to Disk Utility, select the physical drive, and ensure the macOS slice is expanded to fill the available gray space in the partition diagram before applying changes.
Do I need to wipe the Linux partitions before deleting them?
Wiping is not strictly necessary before deletion because the act of deleting the partition table entries makes the data inaccessible anyway. However, if you plan to sell the iMac, you should perform a secure erase of the entire drive using Disk Utility's Security Options to prevent data recovery of both Linux and macOS remnants.