Sunoco Inc. may have found the rescuer for its sprawling South Philadelphia refinery.

The Philadelphia company announced Monday that it has entered into exclusive talks with the Carlyle Group, a large private-equity manager with legendary political connections, to run the plant as a joint venture. The refinery, the largest on the East Coast, is Sunoco's last operating fuel-manufacturing plant.

Sunoco, which has promised to shut down the 335,000-barrel-per-day refinery this summer if it is unable to find a buyer, would contribute the refinery assets in exchange for a nonoperating minority interest in the joint venture. It would have no ongoing capital obligations for the refinery.

The Carlyle Group, which is based in Washington and has $147 billion of assets under management worldwide, would contribute cash to the joint venture, hold the majority interest, and oversee day-to-day refinery operations.

No other financial terms were disclosed. The companies emphasized that a deal was not guaranteed.

Sunoco, which had promised to shut down operations July 1, extended the deadline by a month. "If a suitable transaction with Carlyle cannot be completed," the company said in a news release, Sunoco "would proceed with idling the main processing units at the refinery in August 2012."

Carlyle, second only to the Blackstone Group among private-equity managers, has a wide range of real estate and industrial ventures. Former President George H.W. Bush, former British Prime Minister Sir John Major, and former Secretary of State James A. Baker III have served as advisers.

"We are working actively with Sunoco and other stakeholders to explore ways to keep this vital facility operating," Rodney S. Cohen, Carlyle's managing director, said in a statement.

"The facility has been operating at a significant loss for some time, and we are exploring every avenue to create a viable plan," Cohen said. "It is a heavy lift, and we are not sure a solution is possible, but we are doing the work."

News of the potential deal buoyed the spirits of labor leaders and elected officials, who have been scrambling for months to save the Philadelphia refinery, as well as Sunoco's Marcus Hook refinery and ConocoPhillips' refinery in Trainer. All announced plans last year to be sold or shut down because refining-sector overcapacity had depressed profit margins.

The Marcus Hook refinery is idled and unlikely to reopen as a refinery. ConocoPhillips is said to be in talks with Delta Air Lines to sell its Trainer plant, which is also idled.

Together, the three facilities represent half the refining capacity in the Northeastern United States. On Thursday, U.S. Sen. Robert Casey (D., Pa.) will chair a hearing in Washington with the Congressional Joint Economic Committee on the economic impact of the refinery shutdowns.

Carlyle's investments include a broad range of energy projects, from renewable-energy ventures to drilling projects, pipelines, and refineries.

"We believe having a strong partner like Carlyle with a track record of leading successful business turnarounds is necessary to preserve the facility's future," Brian P. MacDonald, Sunoco's chief executive, said in a statement.

In recent months, there had been much speculation over prospective buyers of the Sunoco refinery.

Some analysts had reported that a leading bidder was Preferred Unlimited Inc., a private Radnor company run by Michael O'Neill. John A. Catsimatidis, chairman and chief executive of United Refining Energy Corp., had also expressed interest.

"We think this option to do a joint venture is the best option to keep the refinery open and save those jobs," said Thomas P. Golembeski, Sunoco's spokesman. The Philadelphia refinery employs about 850 people on 1,400 acres on both banks of the Schuylkill.

Jim Savage, president of United Steelworkers Union Local 10-1, which represents Philadelphia employees, said he met in December with Carlyle Group representatives.

"They asked a ton of questions and seemed like smart people," said Savage. But he heard later that they had withdrawn from the competition.

Savage said he was told Carlyle reentered discussions after Sunoco's MacDonald proposed the joint venture.

"I'm concerned when private equity gets involved -- they don't always have the best motives," said Savage. "But Carlyle has a history of making things work."

Carlyle joined with Riverstone Holdings in 2005 to take Swiss refiner Petroplus private. It brought in legendary refinery executive Thomas O'Malley, who had presided over successful sales of two other refineries, Premcor and Tosco. Petroplus went public in 2006 for $2.4 billion, a 500 percent gain for Carlyle's investors.

After O'Malley departed, Petroplus filed for bankruptcy this year, a victim of the downturn in refining. O'Malley went on to found PBF Energy Partners, which owns refineries in Paulsboro and in Delaware City, Del.