They called him the Beast.

David Fajgenbaum was the fittest of his friends at the University of Pennsylvania’s medical school, a 6-foot-3 gym addict and former quarterback at Georgetown. His mammoth hands seemed more suited to spiraling footballs than the fine fingerwork a doctor-in-training might need. He had endurance to match, taking multiple hits and returning to the field to play on.

“This guy was a physical specimen,” said his former roommate, Grant Mitchell, who used to walk to work with him. When they would arrive at the hospital for his obstetrics rotation, his friend recalled, “he would basically coerce me into doing pull-ups on the tree outside.”

In July 2010, that all changed. The 25-year-old woke up at night drenched in sweat. His lymph nodes were swollen. He felt stabs of abdominal pain, and odd red bumps began sprouting across his chest. Most bizarre of all, he felt very tired — so tired that he began slipping into empty exam rooms between patients, stealing five-minute naps to get through the day.

“Guys, I think I’m dying,” he recalled telling his friends.

A visit to the emergency room confirmed his fears. A doctor told him that his liver, kidneys and bone marrow were not working properly. Even more troubling, the doctor had no idea why his body was failing. “What do you think is going on?” he remembers the doctor asking him.

Pursuing the answer to that question, it turned out, would become his life’s work. It would transform Dr. Fajgenbaum from a patient on the brink of death five different times, whose illness stumped specialist after specialist, to one of the leading researchers in his field. He has even used himself as his own test subject, and may have discovered a treatment for his rare disease.

His story, which has been circulating inside medicine, is more than one person’s remarkable journey, however. It offers a look into the world of rare diseases, a corner of medicine that continues to frustrate — and flummox — those who seek cures for obscure conditions. About 95 percent of all rare diseases have no approved drug treatments.

Fewer than 8,000 people in the United States are found to have Dr. Fajgenbaum’s condition in any given year. But taken as a whole, rare diseases are not unusual: An estimated 30 million people in the country — or about 10 percent of the population — are living with one of the nearly 7,000 rare diseases that have been identified.

Prompted by financial incentives passed by Congress, the drug industry is hotly pursuing treatments for a throng of rare diseases. That has led to breakthroughs in several conditions, including cystic fibrosis and spinal muscular atrophy. Nevertheless, with a small number of subjects to study and relatively few people to sell new drugs to, many rare diseases are overlooked by doctors and scientists, hampered by a lack of resources and public awareness.

Dr. Fajgenbaum’s condition is one of the many that have been given relatively little attention. Initially, doctors thought he had a common form of cancer. A CT scan — a series of images that give doctors a clearer picture of what is going on inside the body — revealed a body riddled with enlarged lymph nodes, a hallmark of lymphoma. The news struck a particularly cruel blow: Only a few years earlier, while Dr. Fajgenbaum was in college, his mother died of brain cancer.

He declined rapidly as his immune system went haywire. A retinal hemorrhage, a type of ministroke, temporarily blinded his left eye. Fluids leaked out of his blood vessels, a sign that his liver was failing. Over the next two weeks, he gained about 70 pounds of extra fluid and his brain fogged over.

For those who knew him as the Beast, the transformation was jarring.

“Even when he got sicker and sicker and eventually went into the hospital, it was kind of like this, oh, weird, Dave must have some really awful virus — that’s one hell of a flu,” his friend Dr. Mitchell said.

When Dr. Fajgenbaum’s brain started slowing down, Dr. Mitchell said, the severity of the illness sunk in. “I would ask him a simple question, and he would answer in a couple words, like 30 seconds to a minute later,” he said.

Dr. Mitchell and the other medical students scoured textbooks and the internet, searching for clues. The top medical experts at Penn, meanwhile, were not having much more luck. Lymphoma was just one theory. Others thought it might be a severe case of lupus or even mononucleosis. But test after test was inconclusive.

Finally, the doctors tried a huge dose of steroids. Slowly, his body began to fight its way back. His kidneys and liver began functioning again, and the extra fluid receded. Seven weeks after he was admitted, Dr. Fajgenbaum walked out of the hospital. It was September 2010.

“I remember asking the doctor, saying, ‘What was this?’” he said. “And I remember the doctor saying, ‘We don’t know what it was, but let’s just hope it doesn’t come back.’”

It took only one month for symptoms to come rushing back, while he was convalescing at his childhood home in Raleigh, N.C. Doctors there shipped a piece of his lymph node to the Mayo Clinic in Minnesota, where pathologists finally pinpointed his disease. The condition, called Castleman disease, was so rare that doctors at the hospital in Raleigh had no experience with it.

Castleman disease had been known since the 1950s but has remained largely a mystery. A hallmark of the condition is enlarged lymph nodes, and most people with the disease — about two-thirds — have a form that affects just one part of the body and can usually be cured through surgery.

The form ravaging Dr. Fajgenbaum’s body — multicentric Castleman disease — is even more rare and deadly. Only about 1,200 to 1,500 people are discovered to have it every year in the United States. It defied classification, occupying a no man’s land between cancer and immune disease. Doctors weren’t sure of the cause in patients like him: Some believed it was a type of cancer, while others thought it was an inherited genetic disorder, or was triggered by a virus.

One thing was clear: The disease was deadly. Only about 65 percent of people with the condition live for five years after it is diagnosed, studies have shown.

Over the next few years, Dr. Fajgenbaum alternated between extended periods of relative health and frightening relapses. His condition stumped even leading experts in the disease, people like Dr. Frits van Rhee of Little Rock, Ark., who has treated the largest number of patients — about 100 — with Castleman.

The tools that Dr. van Rhee and others had were blunt and harmful in their own right. More than once, Dr. Fajgenbaum underwent a devastating, 21-day course of chemotherapy that annihilated his immune system in an effort to knock his disease into remission.

Dr. Fajgenbaum was also granted emergency access to siltuximab, a drug that Johnson & Johnson was developing for people with his form of multicentric Castleman disease, which would be approved in 2014. That year, in 2011, Dr. van Rhee secured a rare exception to try it on Dr. Fajgenbaum.

But the drug, like other previous treatments, did not work.

Dr. Fajgenbaum was undaunted. With the zeal he once devoted to bench-pressing a personal best — 375 pounds, reached six months before he first fell ill — he dove into the scientific research on Castleman disease and began to familiarize himself with the world’s top experts.

On Sundays, his roommate tried to coax Dr. Fajgenbaum out of his bedroom, with its white board covered in notes, organizational plans tacked to the wall. He rarely succeeded. “I’m on the couch watching TV, and Dave is just cranking away on Castleman,” Dr. Mitchell recalled.

The more Dr. Fajgenbaum learned, he said, the more he realized how much the field that studied Castleman was in disarray. Researchers focusing on the disease used different terminology to describe the condition, making it difficult to compare published work. Leading experts weren’t in regular communication, and studies were being done over again, even though previous ones had failed.

“It became just abundantly clear that just because you have smart people thinking about a problem doesn’t mean that it’s coordinated at all,” he said.

One of the people he called was Dr. Thomas Uldrick, a clinical researcher at the National Cancer Institute who had studied multicentric Castleman disease. The two struck up a correspondence. “Clearly he was a very bright medical student, and he was scared of dying from this disease,” Dr. Uldrick recalled.

He also began collaborating with Dr. van Rhee, who knew that Dr. Fajgenbaum was a different kind of patient after he arrived armed with charts, graphs, timelines and slide presentations. “There are patients who keep meticulous records,” Dr. van Rhee said with a chuckle, “but he was definitely in the top 1 percent.”

In spring 2013 Dr. Fajgenbaum earned his medical degree, and a few months later he entered the Wharton School at Penn, reasoning that, to solve the tangled mystery of Castleman disease, business smarts would serve him well.

But in December of that year he got sick again, with his blood platelets dropping so low that he barely avoided a fatal brain bleed.

This time, though, he was able to use his relapse to further his search for a cure.

For months, Dr. Fajgenbaum had been collecting weekly blood samples that served as snapshots of his immune system, tabulating the results in a spreadsheet and adding them to a detailed slide presentation that he had been preparing since he received the diagnosis. And when it was clear the disease had returned, he persuaded his doctors to remove a piece of a lymph node, test it and save it for future research.

After a round of chemotherapy, he improved enough to be discharged and started looking into what secrets the tests might reveal. It turned out that five months before he started noticing symptoms in December, his T cells — one of the key weapons in the body’s immune arsenal — had starting activating, preparing for a fight even though there was no apparent threat. Then, about three months before his relapse, he noticed that he had started producing more VEGF, a protein that instructs the body to make more blood vessels, and is another sign of an immune system gearing up.

These two hints gave him an idea: Maybe the problem was with one of the body’s communication lines, the one that triggered production of VEGF and also told the T cells to begin activating. If Dr. Fajgenbaum could get his body to shut down that communication line — known as the mTOR pathway — he might be able to stop his immune system from overreacting and prevent a relapse.

The discovery was exhilarating. “I felt like I was part of steering the ship,” Dr. Fajgenbaum said. “This time I was part of this team.”

With this major clue in hand, he and his doctors turned to potential treatments, existing drugs that were known to shut down the mTOR pathway. The one that seemed the best option was practically hiding in plain sight. Sirolimus, also known as Rapamune, was commonly given to kidney transplant patients to prevent their bodies from rejecting the organ. The drug had been on the market for years and was known to have few serious side effects.

“I wouldn’t think I ever could have prescribed this to another patient, or told a patient to try it, because we just didn’t have very much data,” Dr. Fajgenbaum said. “But at this stage, I’d had four episodes, and I’d failed everything the doctors had ever given me.”

In choosing to become his own test subject, Dr. Fajgenbaum was following a long line of medical researchers who have experimented on themselves. At the turn of the 20th century, government researchers studying yellow fever in Cuba allowed themselves to be bitten by mosquitoes who harbored the disease; one researcher caught the fever and died. In 1929, Dr. Werner Forssman inserted a catheter into the vein of his arm and guided it to his heart to prove that the procedure worked (he shared in a Nobel Prize for his work in 1956). As recently as 2005, Dr. Barry Marshall won the Nobel after drinking a broth infected with bacteria to prove that it caused ulcers.

This activist approach, Dr. Uldrick said, did not sit well with everyone. “There was some tension between the various doctors about who was driving the boat,” he said.

But the idea that Dr. Fajgenbaum needed to try something new was unanimous: Chemotherapy had worked three times, but the powerful drugs take a heavy toll and can themselves cause cancer if given too often.

Dr. Fajgenbaum eventually prevailed. In January 2014, he stopped taking his old cancer drugs and started on sirolimus. Six months passed, then a year. The weekly blood tests showed that his immune system was returning to normal.

Dr. Fajgenbaum, his health improving, returned to the other challenges that were hampering progress in the field of Castleman disease. He started the Castleman Disease Collaborative Network, a nonprofit whose mission was to prioritize and coordinate research into the disease, which operates out of the Perelman School of Medicine at Penn. Dr. Fajgenbaum, an assistant professor of medicine at the school, and his collaborators assembled an advisory panel of the world’s experts in the disease and set an agenda for answering the most pressing questions.

First on the list is figuring out the cause: Is the disease genetic, a form of cancer or caused by a virus?

As always, the work is intensely personal. Last summer, he drove to Allentown, Pa., to collect a blood sample from a patient with Castleman disease. He placed the vials in his vest pocket, explaining that he needed to keep the blood warm so the tests he had planned would work properly.

“You remind me of a mother hen,” the patient said with a laugh.

That gave him an idea: Dr. Fajgenbaum sat on the vials as he drove two hours back to Philadelphia, the car heater cranked up to ensure they were warm. It was a sweaty ride back, but worth it. “These samples are precious,” he said.

In medical research, discoveries come slowly and take twists and turns that no one saw coming. Seasoned researchers have learned to rein in their optimism and to know that true breakthroughs can take years, if not decades, to realize. Not Dr. Fajgenbaum.

“I almost wish that every disease had a David to be a part of the charge,” said Dr. Mary Jo Lechowicz, a professor at the Emory University School of Medicine, who has studied Castleman disease and serves on the network’s advisory board.

Dr. Fajgenbaum’s single-minded mission to take on his own disease is also typical of the rare-disease world, said Max Bronstein, the chief advocacy and science policy officer at the EveryLife Foundation for Rare Diseases in Novato, Calif.

“A lot of mom-and-pop patient organizations emerge to take on these huge challenges in rare diseases,” he said. “I don’t think there’s one correct model for each disease; there’s been so many different approaches.”

Last month, Dr. Fajgenbaum marked his three-year anniversary since starting on sirolimus, a period more than twice as long as any of his other remissions. “I feel 100 percent,” he said.

These days, Dr. Fajgenbaum, now 31, walks through the hallways of Penn’s medical center, his frame again projecting the easy confidence of the athlete he once was. But he jokes that he would have to pull out photos of his days as a quarterback to explain to people why his friends still call him the Beast.

Now, he said, every time he tries to exercise, his mind wanders back to an email he needs to write or a call he needs to make. “It’s not because I don’t have the energy to do it; it’s because all of my energy is going toward this disease,” he said.

Not everyone is convinced that sirolimus is what has been keeping him healthy. Dr. van Rhee noted that while the results in Dr. Fajgenbaum are promising, his is just one case and treatments need to be proven in many more people. “I think the finding is very interesting,” he said, “but we need to see whether a similar mechanism is active in other patients.”

But Dr. Fajgenbaum said he grew more confident every day that it is the drug that is helping. He has begun sharing his experience with more doctors and researchers, is conducting laboratory tests to see if the drug is likely to work in other patients and has started writing an article about his experience for a medical journal. Soon, he hopes, doctors will begin prescribing the drug to other patients.

Dr. Fajgenbaum is optimistic about the drug’s chances but is aware medical science is unpredictable. “Who knows; maybe it will work for only a small percentage,” he said. “So we’ve still got a lot of work ahead of us.”

He now oversees the network’s research from his office in the Hospital of the University of Pennsylvania, five floors above the emergency room where he first learned his body was falling apart. It is also the same building where he spent weeks in the I.C.U., so sick that he said his final goodbyes to friends and family.

At first, when he learned his office would be in the same building, he felt anxious, unsure if he wanted the constant reminder of the ordeal he had endured. A few months ago, Dr. Fajgenbaum was called to the I.C.U. to meet a patient who had just found out he had Castleman disease. He spoke to the patient about enrolling him in a new study, and as he looked out the window, realized the view looked familiar.

On his way out, he bumped into a nurse who remembered him. She noted that he had stayed in the same room as a patient.

Ultimately, he said, he is glad for the proximity. “I didn’t think that I would ever get to leave the hospital, and now here I am, fighting back,” he said. “It’s the ultimate motivator.”