iMac external hard drive boot up

Questions I needed to solve in order to resolve: why is the computer running slowly? I will need a new computer eventually, but these steps allowed me to use things I already owned and got me back to using a functional computer.

What is happening?

Turning on the computer, the boot up takes a long time. After logging in, the screen is black but the cursor is visible.

Notes from the Apple Store visit

Problem Description/Diagnosis

Issue:
Client states device is running slow

Steps to Reproduce:
Verified issue

Device took more than 5 minutes to boot to user

Ran Mac resource inspector

HDD failing

Ran first aid on hard drive

Cosmetic Condition:
No signs of external physical damage

Proposed Resolution:
Offering client hard disk drive replacement

Out of warranty

Aware that this is a vintage model and parts arenโ€™t readily available and may affect other repair if needed

Holding this part for up to 5 days

Will test out and see if a restore can help bring life to the iMac for a little longer, if issue still persists client will come back for repair

What alternatives exist for a failing HDD?

From Apple: replace the HDD with the same part from the same year. $118 part, &79 labor, $198 total.

From Rossman Repair: 1. $450 full service parts and labor. 2. BYO SDD, recommended Samsung 870 or 860 evo and $225 labor to install.

From iFixit: $130 parts and instructions

https://www.ifixit.com/Store/Mac/iMac-Intel-27-Inch-Late-2012-2019-SSD-Upgrade-Bundle/IF174-029?o=22

https://www.ifixit.com/Guide/iMac+Intel+27-Inch+EMC+2546+Hard+Drive+Replacement/15796

Are there other options to get a working computer without physically removing the screen?

Getting macOS on an external drive, and plugging that external drive into the iMac, and booting from the external drive will use the working parts of the computer e.g. screen, RAM, GPU, keyboard, mouse, and replace the failing part of the computer i.e. the hard drive.

What kind of external drive can hold macOS?

I found I already owned a Western Digital HDD external hard drive, and a Samsung external flash drive. The WD drive was formatted for use with a Windows computer, and had a WD Unlocker application that required a password to unlock.

How can the WD Unlocker be removed?

Another application, WD Security, is required to be downloaded in order to remove the WD Unlocker application. Download WD Security, enter the password for WD Unlocker, remove the requirement of WD Unlocker, uninstall WD Security.

https://support.wdc.com/downloads.aspx?p=158

https://superuser.com/questions/969026/remove-wd-unlocker-partition-from-wd-my-book

How can the external drive be reformatted from Windows to Mac?

Use the Mac application Disk Utility, click Erase, and Format: Mac OS Extended (Journaled)

https://www.youtube.com/watch?v=hcWsCYz9Q4I

How can I get macOS on the external drive?

Check which version of macOS the computer is compatible with, and download that version from the App Store

macOS Monterey is compatible with these computers

https://support.apple.com/en-us/HT212551

How to get old versions of macOS

https://support.apple.com/en-us/HT211683

Use Safari to download macOS on your Mac (same link)

https://support.apple.com/en-us/HT211683

For me, this was Catalina

macappstores://apps.apple.com/us/app/macos-catalina/id1466841314?mt=12

Once the macOS is installed on the external hard drive how do I install it?

This is an overview using macOS Mojave but covers this step starting at around 3:30

https://youtu.be/kdzK5lgqLjM?t=210

How do I choose which drive the computer should boot from by default each time I turn the computer on?

Change your startup disk for every startup

https://support.apple.com/guide/mac-help/change-your-mac-startup-disk-mchlp1034/mac