At Iraq's Rabia border crossing with Syria, a giant billboard of Syrian President Bashar al-Assad waves jauntily to arriving passengers. It's a contrast to the grim expressions on those coming from Syria and going back in.
This crossing in Ninevah, a majority Sunni province, borders Syria's Kurdish region, which until recently has been immune from much of the violence. Syria, eager to keep up the pretence that all is well, doesn't allow potential refugees to cross the border. Most of them are smuggled across at night knowing they will be arrested and delivered to a refugee camp in Kurdish territory.
Army and border commanders say security has improved dramatically from a few years ago when this part of the country was an al-Qaeda stronghold. The Iraqi government would like to keep it that way.
Hundreds of kilometres away in Western al-Anbar, the Iraqi government closed one of its three main border crossings after Syrian opposition fighters seized control from Syrian security forces. Not content with locking the gates, Iraqi soldiers sealed the border at al-Qaim with concrete blast barriers. The government deployed the 7th Army Division from the vast al-Assad desert base to reinforce the border, along with two Baghdad Army brigades and helicopters.
The Iraqi government has been in a delicate position with its powerful Syrian neighbour – working to retain diplomatic relations and refusing to join the call for sanctions or armed intervention. The fighting though – and attacks on some of the hundreds of thousands of Iraqis who fled there during their own civil war - has made that increasingly difficult.
While the UNHCR – the main refugee agency - called on the Iraqi government to reopen the border to Syrian refugees, the government spokesman indicated Friday that it wouldn't.
"We are sorry for not receiving Syrian refugees. We are not like Jordan and Turkey - their border regions can provide services. We had hoped to help our Syrian refugee brothers," Ali Dabbagh told state-run Iraqiya TV. He said Iraqi security concerns and the location of the borders in the remote desert prevented them from helping.
Instead, Iraq has focused on evacuating some of the estimated 300,000 Iraqis living in Syria – itself an admission that security in Syria had become untenable.
Government planes have flown out almost 1,000 refugees from Damascus. Thousands of others have struggled to find their way on buses out of the country – some running a gauntlet of shootings and shelling along the way.
On one bus, so crowded that desperate passengers were standing in the aisles, Sana Jabar explained why she had left her home in the Sayida Zaineb neighbourhood in Damscus – overrun by armed gangs.
"They came and told us 'you Iraqis must evacuate your houses – your government is asking for you', so we were forced to leave."
Seven years ago she left Sadr City in Baghdad after her husband was wounded in a bomb attack. Displaced for the second time, she was hoping she could find a home again in an Iraq still struggling with its own fragile security.