The European Union (EU) wants to change the rules governing Europe's passport-free travel area so countries can conduct identification checks at borders within the zone for another two years, officials said Thursday.

Systematic ID checks on every traveller are banned in the 26-nation passport-free travel zone known as the Schengen area. Austria, Denmark, Germany, Sweden and non-EU country Norway received permission to introduce them in 2016.

The countries say the checks adopted after more than 1 million migrants entered Europe the previous year are needed for security reasons.

EU Migration Commissioner Dimitris Avramopoulos said after talks with EU interior ministers Thursday that the EU's executive arm would soon come up with a package of proposed measures aimed at strengthening the Schengen area's security.

Avramopoulos said the recent extremist attacks in Spain the suspects had been in France and Belgium in the days before exposed weaknesses in the passport-free zone and shows that “the Schengen borders code may not be sufficiently adapted to address the evolving security challenges.”

It was a remarkable about face by Avramopoulos. Hours before meeting the ministers, he called for the ID checks to come to an end.

French Interior Minister Gerard Collomb said the aim would be “to make the Schengen code more flexible, of course not to call into question free movement, but to allow our borders to be protected from terrorism.”

“The idea that we are developing is to be able to continue for a bit longer, and we have indicated a period of two years,” Collomb said.

The European Commission let Austria, Denmark, Germany, Sweden and Norway extend the measures for two six-month periods since May 2016. Under current rules, they are due to expire on November 11 without the possibility of renewal.

German Chancellor Angela Merkel is eager to have the police checks continue, and there's no sign of Berlin backing off as the country prepares for an election on September 24. Austria, which also holds elections next month, wants them kept in place too.

Before Thursday's meeting, Avramopoulos had said it was time to go back to the earlier system that only allowed for random checks on travellers.

“I believe it is the moment to go back to the normal function of Schengen,” he said. “During the last two years, we have been working in crisis mode. Now it's the moment to step out of the crisis.”

Avramopoulos said the EU's migrant deal with Turkey had strengthened Europe's external border, with migrant flows from the country to the Greek islands down by 81 percent last month, compared with August 2016.

Slovak Interior Minister Robert Kalinak said his country no longer feels the effects of the migrant wave. He suggested that the appeal to prolong controls is largely political, especially with elections due in Germany and Austria soon.

“I think it is more a political question than the real necessity of these border controls. We will see after the elections, I think the situation will be pretty different,” he said.