“Alarms Went off in the Spacecraft.” How IBM Computer Whizzes Saved Apollo 11

Homer Ahr never stepped foot on the Moon.

But Ahr (pronounced “are”) along with thousands of his International Business Machines colleagues and on-the-ground partners in NASA, made their mark on history another way. They were the unsung computer whizzes responsible, on July 20, 1969, for helping Apollo 11’s astronauts touch down on the lunar surface—and return home to Earth, alive. Without these government contracted engineers, technicians, analysts, and coders, that miracle of a manned moonshot surely would have failed.

NASA “bet everything on us and we bet everything on them,” says John Kelly, now executive vice president of IBM’s research division, who remembers watching a televised broadcast of the lunar landing as a teenager. “If something had gone wrong, if those computers had failed, it would not have been a happy day.”

In fact, something did go wrong. But not wrong enough to ruin one of the greatest achievements in human history.

Fortune spoke to Ahr, a former IBM mathematician and software programmer who worked at NASA’s Johnson Space Center in Houston during the Apollo 11 mission, about his experience. (From a perch near his self-described “mancave” in Texas, he introduces himself over the phone as Homer, “like a homerun.”) Ahr, now 73-years-old and retired, described for Fortune an unsettling incident that almost derailed that momentous occasion.

The first steps

Ahr joined IBM in 1968 at age 21, a year before the Apollo 11 flight. A precocious engineer and recent college graduate, he had turned down a lucrative gig writing software for one of Texas’s biggest construction companies to work for NASA. A job with Big Blue met his criteria: Do something challenging; do something for the country; and do it in Texas.

Ahr made his first mark in December of that year writing code for the Apollo 8 flight, the first crewed mission to orbit the Moon and return. His instructions helped the spacecraft maneuver. “I was probably the youngest person on the console—maybe the youngest person in FSD [flight systems division] Houston,” Ahr says.

Seven months and four missions later, NASA was ready for its moonshot—and so was Ahr. He was responsible for inputting commands into IBM’s computers that ultimately would be transmitted to the Apollo 11 spacecraft to be executed by the astronauts on board.

“Kennedy’s vision was to land a man on the Moon—and bring him home safely. That latter part gets forgotten by a lot of people,” Ahr says. “But I guarantee you the people writing software for Mission Control Center and the people in Mission Control Center lived every day of our lives knowing just how important that was.”

Big Blue moon

NASA tapped IBM’s federal business, based in Owego, N.Y., to build and run the command-and-control machines and calculators needed to collect rocket telemetry, determine flight paths, and redirect trajectories for the space program’s Mercury, Gemini, and Saturn series of missions. By 1966, IBM had installed its now-famous System/360 Model 75 computers, the super-popular mainframe that kicked off and defined the company’s golden era.

“These new computers are three times more powerful than the Gemini installation”—which used IBM 7094 II computers, a predecessor—“and more than 50 times the power of the computing system which supported the Mercury program,” a contemporary document from IBM’s archives says.

While the technology was cutting edge for the time, the systems were far less capable than the technology we’re familiar with today. An Apple iPhone, for instance, is millions of times more powerful than than the guidance computers installed on the Apollo mission’s command and lunar modules.

But as the Apollo 11 mission neared the moment of truth, beginning its descent toward the lunar surface, crisis struck. “Audible alarms went off in the spacecraft,” Ahr recalls. “It was very chaotic. It was going off in your ears.”

Ahr first heard the sirens through his hands-free headset. Soon, alarms and flashing lights began to go off inside Mission Control Center. Something had gone wrong.

It wasn’t immediately clear what tripped the buzzers. But Ahr’s team had rehearsed similar scenarios—a lot. The group had run simulations 12 times a day, three times a week, for three months, summing to more than 400 test runs total, he says. The trials, many of which involved intentionally suboptimal circumstances, like what to do in the event that a thruster malfunctioned, ended in abortion as much as 90% of the time, Ahr estimates.

“We knew what it felt like for the air to be sucked out of building 30 because an abort had been called when it shouldn’t have,” Ahr says, referring to the instant onset of depression that befell workers inside the facility where IBM’s so-called real-time computer complex, the mechanical brains of the mission, was housed, when a test-run went awry. “Boy, you don’t want to do that.”

But practice is no match for game day. “It’s always more chaotic or emphatic or disconcerting when it happens during a real mission,” Ahr adds.

Go for moon landing

Even in the midst of all this then-new technology, humans had the final say.

Jack Garman, a NASA computer specialist and avionics expert trained on IBM’s computers, had been asked by Gene Kranz, the mission’s chief flight director, to write down all possible error conditions to prepare for any contingency. Garman, who died in 2016, studied a table he had written down which described all the failure modes and what to do about them as the alarms blared. Looking over the alerts, he determined that the mission should proceed.

“It took 10-to-15 seconds the first time [the alarm] occurred for him to say ‘Keep going,’” Ahr remembers. “Then it happened again and again and again.” Each time an alarm triggered, as the Apollo mission’s lunar module descended faster toward the Moon’s surface, Garman told his superiors to continue the mission.

Eventually, people got a grip on what had happened: Onboard computers were overloaded. Due to some error, the machines were trying to process more data than they could handle. Because the computers couldn’t accomplish all the tasks asked of them, they sounded off. (Discover Magazine has a good technical explanation.)

“From a trajectory standpoint there was no other call but to keep going,” Ahr says. “It was a good descent. It would have been a travesty if we had aborted.”

One giant leap

As he recollects the events that transpired fifty years ago, Ahr has to stifle an upwelling of emotion. He compares his response to the reactions veterans might have when looking back on the invasion of Normandy during World War II. While watching a commemoration of the D-Day landing last month, a thought struck him. “I started getting teary-eyed and choked up the same way I do when I talk about landings, splashdowns, or descents,” he says.

“I got to thinking that July 20th was our D-Day,” Ahr continues, audibly moved. “It was the day we liberated mankind from just walking on the Earth. We walked on another celestial body. We liberated man from the bounds of the Earth—for good.”

Today’s scientists hope to carry the torch further. The Apollo 11 mission “was an incredible accomplishment,” says IBM Research’s Kelly. “The risks that the country took, that NASA took, that IBM took—these astronauts strapped themselves onto a rocket to go a quarter million miles to a cold piece of rock—is just amazing.”

Kelly praises the gamble of a public-private partnership that IBM and NASA forged. “We as companies and countries need to do more of that. Not just the incremental—we need to do some real soul-searching,” he says. “Are we taking enough risks? Are we going for the Moon? Are we going to try to really cure cancer? Are we really going to try to understand what’s going on with the environment? And do we have the guts and wherewithal to do it?”

“Humans can do almost anything,” Kelly adds, “if they put their minds to it.”

More must-read stories from Fortune:

—The fall and rise of VR: The struggle to make virtual reality get real

The Internet as we know it needs ‘a complete replacement’

Nintendo has a bold plan for competing with streaming

—Why an EU investigation into Amazon could change the way the e-tailer works

—Listen to our new audio briefing, Fortune 500 Daily

Catch up with Data Sheet, Fortune‘s daily digest on the business of tech.

Subscribe to Well Adjusted, our newsletter full of simple strategies to work smarter and live better, from the Fortune Well team. Sign up today.

Read More

Artificial IntelligenceCryptocurrencyMetaverseCybersecurityTech Forward