The results of the 2016 campaign were humiliating for the party. The P.R.I. lost elections in 7 states, including some where they had held power for more than 70 years, and Mr. Beltrones was forced to step down as party president. Then came the investigations under the new governor, Mr. Corral, whose efforts have put the entire party on alert.

This is hardly the first time Mr. Beltrones has been against the ropes. In various phases of his career, he has faced political exile, only to reinvent himself and work his way back into the halls of power.

In 1997, when he was the governor of the state of Sonora, Mr. Beltrones was accused by some American officials of having links to drug traffickers. The claims were serious enough that the American ambassador at the time considered revoking his Mr. Beltrones’s visa to the United States.

Most people thought Mr. Beltrones was done after that. He left his governorship and did not have another major political position for years. But by 2003, he was back, having found his way into the center of the action as a crucial intermediary between the P.R.I. and the administration of Vicente Fox, the first non-P.R.I. president in 70 years.

A new era for Mr. Beltrones followed. He became known as a politician capable of maintaining power even when his party was in the opposition, able to broker deals with his rivals and retain his own influence, lawmakers recall.

As other politicians of his generation fell by the wayside, Mr. Beltrones evolved. Through charm, guile and a shrewd ability to read the winds of change, he galvanized his reputation as Mexico’s timeless politician, the ultimate power broker even when his party was out of power.

Perhaps his most powerful moment came when he allied himself with another former president, Felipe Calderón of the rival National Action Party, whose election was so contested that one opposition party blocked his entry into Congress to keep him from being sworn in as president.