Germany was forced to agree to bail out Greece for the second time in a year under strong pressure from the International Monetary Fund following the resignation last month of its head, Dominique Strauss-Kahn, the Guardian has learned.

Under its acting chief, the American John Lipsky, the IMF has taken a more hardline stance. The fund warned the Germans in recent weeks that it would withhold urgently needed funds and trigger a Greek sovereign default unless Berlin stopped delaying and pledged firmly that it would come to Greece's rescue.

Senior officials and diplomats in Brussels confirmed that the IMF threat to pull the plug on its funding, in stark contrast to the more emollient line of Strauss-Kahn, had been defused because of a German climbdown.

As political turmoil continued in Greece on Thursday, with the prime minister, George Papandreou, scrambling to form a fresh government, the stage was being set for a political struggle between Europe's powerbrokers over the fine print of the proposed new €100bn-plus rescue of Greece.

Berlin is deeply at odds with France and with the key EU institutions – the European Central Bank (ECB), the European commission, the presidency of the EU, and the head of the eurozone, Jean-Claude Juncker, prime minister of Luxembourg – over the terms of a deal.

While conceding the need for the fresh bailout, Berlin is insisting that the banks and other private creditors holding Greek debt take losses as part of the rescue plan, which is expected to amount to €125bn (£110bn), or about €90bn if the Germans succeed in forcing losses on holders of Greek bonds.

Although international stock markets enjoyed a calmer day on Thursday, Juncker believes that imposing losses on investors could trigger a European version of the Lehman Brothers bank collapse – a so-called "credit event". Juncker said: "It's a really ugly situation. The [German] idea is dangerous. It could provoke the gravest risk, that all three rating agencies declare a credit event and then there are big contagion risks for other countries."

Nout Wellink, a member of the ECB's governing council, warned that the EU bailout fund would have to double to €1.5tn if Greece does fail to pay its debts and spreads financial turmoil to other countries. French president Nicolas Sarkozy goes to Berlin on Friday for a summit with German chancellor Angela Merkel, with the aim of stitching up a compromise.

Under Greece's first €110bn bailout, shared by the EU and the IMF, a fifth tranche of €12bn is to be disbursed next month. Publicly, the IMF had been threatening to withhold its share of the money unless Greece's funding gap for 2012 is closed. But Olli Rehn, the European commissioner for monetary affairs, said on Thursday that the EU and the IMF had agreed to throw Greece the €12bn lifeline by next month to forestall a default.

Privately, sources said that Lipsky challenged the Germans on the fringes of a G8 summit in France almost three weeks ago, and demanded that Berlin guarantee Greece's borrowing requirements and put a figure on the pledge. The IMF ultimatum came a week after Strauss-Kahn, a former French presidential contender, resigned as IMF chief following his New York arrest on charges he denies of attempted rape and sexual assault of a hotel chambermaid.

Berlin blinked, according to participants in the negotiations, and 10 days after the IMF challenge, the Merkel government admitted for the first time that Greece would need a new bailout. But it stoked further controversy by demanding that Greece's private creditors take losses on their loans.

Before a series of crucial EU meetings starting this weekend, Berlin looks increasingly isolated in its demands, spelling trouble for Merkel at home, where the rescue of spendthrift eurozone countries is deeply unpopular. Merkel's junior coalition partner, the liberal Free Democrats, on Thursday reiterated the need for the banks to take some of the pain in the Greek crisis.

The rescue scenario is also hostage to developments in Greece, with European leaders anxiously eyeing the political turmoil in Athens and questioning whether Papandreou would be able to deliver on his side of the bargain: savage spending cuts and tax increases aimed at raising €28bn, combined with a €50bn privatisation programme.

"We expect the Greek parliament to endorse the economic reform programme as agreed by the end of June," said Rehn. "We will not let the euro area face any kind of catastrophe."

The turmoil sent the euro tumbling to a record low versus the safe-haven Swiss franc, and intensified pressure on the region's other lower-rated states, highlighted by weakening demand at a Spanish bond auction.

Senior officials in Brussels worried that time was running out. Papandreou's attempt to form a government, win a vote of confidence and then drive the austerity package through parliament could take longer than scheduled, jeopardising the planning in European capitals.