KOS, Greece - Greek police used fire extinguishers and batons against migrants on the island of Kos on Tuesday after violence broke out in a sports stadium where hundreds of people, including young children, were waiting for immigration papers.

The scuffles took place a day after a police officer on the island was suspended for brandishing a knife and slapping a man identified by Greek media as a Pakistani migrant.

Greece, which just pulled back from the brink of financial ruin by clinching a deal with its international lenders, has struggled to cope with a surge in migrants and refugees arriving on its shores this year.

On Tuesday, TV images showed hundreds of migrants jostling with one another as they ran from huge clouds of thick white powder set off from fire extinguishers wielded by police officers who were apparently trying to disperse the crowd.

It was not immediately clear what had sparked the violence. Once calm had returned, police ushered yet more migrants into the stadium, packing the stands, a Reuters witness said. Some migrants set up tents while police stood guard in riot gear.

The migrants arriving on Kos have come by crossing the sea in rubber dinghies from Turkey in a bid to enter the European Union. Many have fled war zones and poverty.

Kos Mayor Yorgos Kyritsis earlier said strained local services, including the police and coast guard, were unable to cope with the influx.

“This situation on the island is out of control,” he told Greek TV. “There is a real danger of uncontrollable situations. Blood will be shed.”

A Greek police official, who spoke on condition of anonymity, said there were plans to deploy riot police squads to the island and for police officers from the neighbouring islands of Rhodes and Syros to be sent in as reinforcements.

Greece and its international lenders reached a multi-billion euro bailout agreement on Tuesday after talking through the night, officials said, after months of acrimonious negotiations.

The agreement, reached after a 23-hour session of talks, must still be adopted by Greece’s parliament and euro zone countries.

The United Nations refugee agency UNHCR said 124,000 had landed on Greek islands this year. Last week it called conditions for migrants on Kos and other islands “shameful”, and said about 3,000 migrants and refugees were waiting to be registered by police.

“While they wait, they have to endure inadequate living conditions and little or no assistance,” UNHCR spokesman William Spindler said in Geneva. “There is a great deal of frustration and rising tensions. We call on the Greek authorities to renew their efforts to provide decent reception conditions to refugees arriving in Greece.”

Between 100 and 500 migrants were landing in Kos every day, a Greek coast guard official told Reuters.