BRUSSELS - The EU’s president urged leaders gathering for an emergency summit Wednesday to stop fighting over a refugee quota deal and take urgent action to secure the bloc’s borders in the face of “millions” of migrants.

After European Union ministers forced through a deal to relocate 120,000 refugees in the teeth of opposition from eastern states, Hungary’s hardline prime minister angrily denounced Germany’s “moral imperialism”.

Slovakia meanwhile said it would dispute the quota deal in court, underscoring the deep divisions that have emerged in Europe over its biggest migration crisis since World War II.

Donald Tusk, head of the European Council, called for an end to “the cycle of mutual recriminations and misunderstandings” fuelling the split between the EU’s richer west and poorer former communist east.

“The most urgent question we should ask ourselves tonight is how to regain control of our external borders,” Tusk, a former Polish prime minister, told reporters.

“The conflicts in the Middle East, especially in Syria and Iraq, will not end anytime soon,” he said. “This means today we’re talking about millions of potential refugees trying to reach Europe, not thousands.” Greece, still reeling from its debt crisis, was expected to come under particular pressure to accept EU help to strengthen its borders as a frontline state besieged by thousands of refugees flooding in by sea from Turkey.

Tusk will also press EU leaders to offer more aid to affected countries outside the bloc including the western Balkans and Syria’s neighbours Turkey, Jordan and Lebanon, as well as to the UN World Food Programme (WFP).

Ahead of the meeting, the European Commission, the executive arm of the 28-nation bloc, proposed an extra 1.7 billion euros ($1.9 billion) in funds.

The 120,000 refugee relocations are just a faction of the 500,000 migrants who have come to Europe’s shores so far this year and the estimated four million camped on Syria’s borders.

In a rare move on the eve of the summit, EU interior ministers did not wait for unanimous agreement but passed the relocation plan by majority vote in the teeth of opposition from Hungary, the Czech Republic, Romania and Slovakia.

The eastern states argued that the EU has no right to override national sovereignty and make them accept people from overwhelmed frontline states such as Greece and Italy.

“The most important thing is that there should be no moral imperialism,” Hungary’s hardline leader Viktor Orban said during a visit to the southern German state of Bavaria when asked what he expected from German Chancellor Angela Merkel.

Orban has proposed a three-billion-euro fund for dealing with the crisis but it was not clear whether the leaders would discuss that.

Slovakian Prime Minister Robert Fico, whose country will have to take 800 migrants under the relocation plan, said he was prepared to break the EU’s rules rather than accept the “diktat” from Brussels. “Slovakia is not going to respect mandatory quotas. We are filing a lawsuit with the (EU’s) Luxembourg court,” Fico said, quoted by the website of Slovakia’s leading SME daily.

The scale of the challenge was evident in Croatia, where nearly 9,000 migrants entered on Tuesday alone, a record daily number since they started to arrive a week ago after Hungary closed its borders.

Over the last week, more than 44,000 refugees have entered Croatia from non-EU Serbia.

But EU Migration Commissioner Dimitris Avramopoulos rejected any suggestion that the rare failure to reach a unanimous agreement on the relocation plan did more harm than good.

“On the contrary, it is a victory for the EU and for all member states,” Avramopoulos said on Wednesday.

However Brussels flexed its muscles by issuing formal warnings to 19 EU states including Germany and France for breaching the bloc’s established rules on the treatment of asylum seekers.

“It is about time that member states stepped up to the plate and did what they need to do,” European Commission Vice President Frans Timmermans said.

US President Barack Obama had on Tuesday pressed European nations to take their “fair share” of refugees, despite accusations that Washington has done little to address the crisis.

With millions of Syrians forced into camps across the Middle East, tens of thousands crossing Europe on foot and hundreds washing up dead on beaches, America has promised to take in only 10,000 refugees next year.

That figure is dwarfed by million asylum seekers that Germany is expecting to welcome by the end of this year.