This seeming contradiction — with some of Prince’s associates saying they were aware of his long struggle with pain medication, but others saying they had no idea until the very end — ultimately frustrated investigators.

“There is no doubt that the actions of individuals closely associated with Prince will be questioned, criticized and judged in the days and weeks to come,” the Carver County attorney, Mark Metz, said in his announcement that there would be no charges. Mr. Metz noted that “because Prince was an intensely private person, he was certainly assisted and enabled by others to obtain” the pills he came to rely on.

But the investigators could not make a case against anyone for supplying the fatal drugs. “Suspicions and innuendo are categorically insufficient to support any criminal charges,” Mr. Metz said.

Despite an often blurry picture of the singer’s relationship to drugs, Prince’s associates appeared to agree that his pain stemmed from what he loved most: performing. After decades of onstage acrobatics, often in heels, Prince was known to suffer from hip pain and was said to have undergone surgery. The musician also complained sometimes of numbness in his arms and hands, possibly from banging relentlessly on the piano.

In an interview with police about a year after Prince’s death, Theo London, his tour manager and chief of staff between 2011 and 2015, recalled the singer once asking for a painkiller and becoming angry when Mr. London brought him a Tylenol, explaining that he needed something stronger.

Manuela Testolini, Prince’s wife from 2001 to 2007, told police that Prince often used narcotic pain pills during that period to manage his bodily aches. Sheila E. said that Prince had always wanted to hide how much pain he was in. Years ago, she told police, people working for the singer would obtain prescriptions for him in their own names to protect his privacy.