As a nine-year-old boy, Ibrahim Mahmoud fled his hometown of Haifa on the back of a truck during the 1948 war that attended the creation of Israel. Now, as a hunched old man, he is once again encamped far from home, having fled the Islamic State takeover of the Iraqi city of Mosul.

His life of exile is framed by wars that redrew borders and scattered centuries-old communities, and his trauma is shared by millions across the Middle East, who have packed their belongings and bundled up their families to seek safety far from their homelands, joining the largest wave of refugees since World War II.

His odyssey began in 1948, when he was among the estimated 700,000 Palestinians who fled their homes or were driven out in Israel's War of Independence. In the years that followed, hundreds of thousands of Jews from ancient communities across the Middle East emigrated to Israel, often after suffering persecution.

"We fled our homes in Palestine in 1948 to Jordan on the back of a truck," Mahmoud said. His family then flew to Basra, a sweltering city at the southern tip of Iraq, on the Persian Gulf.

"When we came to Basra, my father started to sell falafel. It was new here so business was going well," he said. But the family struggled to adapt to their new surroundings, far from the temperate Levant.

"Life in Basra was difficult. It was dusty and the water wasn't clean where we lived," he said. Unable to find anywhere else to live, Ibrahim and his family took refuge in an abandoned synagogue with other Palestinian families, living there for 30 years, he said.

Up to 70,000 Palestinians lived in Iraq before the 2003 U.S.-led invasion, according to numbers provided by the U.N. refugee agency. Saddam Hussein's government proclaimed solidarity with the Palestinians, who were allowed to work and even hold government jobs but were never granted citizenship.

After the U.S.-led invasion, however, many Iraqis viewed the Palestinians as complicit with the former regime, and the refugees fled from discrimination and growing unrest. Official figures do not exist, but the U.N. refugee agency estimates that just 3,000 Palestinians remain in the country today.

In the mid-1970s, Mahmoud, his wife and five children moved to Mosul after he was told by an old man who had fought in the 1948 war that he would feel more at home in the northern city.

"He told me there was a place in Iraq just like Palestine. There's grass everywhere and rivers. And they have oranges there," he said.

The city was just as the man had described, but Mahmoud struggled to make ends meet, in part because of the crippling international sanctions imposed on Iraq in the 1990s. His children were forced to work instead of attending school. "We had to make sure there was bread on the table, so that's all we could give them," he said.

They remained in Mosul during the chaos that engulfed Iraq after 2003, when the city saw heavy fighting between U.S. troops and insurgents and frequent bombings.

As the fighting slowly died down and U.S. troops withdrew from Iraq in 2011, Mahmoud might have thought his lifelong flight from war was finally over, that while he may never see Haifa again he could at least live in peace.

But then a hot summer's night in June 2014 was shattered by the grimly familiar thud of explosions and rattle of gunfire, as the Islamic State group swept into Mosul, Iraq's second largest city. Within weeks the extremist group would add vast swaths of northern and western Iraq to its territory in neighboring Syria, establishing a self-styled caliphate governed by a chilling interpretation of Islamic law.

Mahmoud and his family, which by then included 11 children, remained until August of that year, before once again packing their belongings and bidding farewell to a place they had called home.

"I saw people being beheaded in the streets. What kind of life is that?" Mahmoud said.

Now he and his family live in the Baharka refugee camp in Iraq's northern Kurdish region, where some 4,000 people huddle in tents pitched along muddy roads. The winter rains send water into the tents, and Mahmoud, who is in his late 70s, says he struggles to walk through the mud.

His 35-year-old son Thamer, who works as a barber in the camp, was born and raised in Iraq but has always felt like an outsider.

"As far as I can remember I have been living in Iraq. But I don't feel I'm in my homeland, because my ID says I'm a refugee," he said.

Ibrahim still gets a government pension for working on Iraq's railways his whole life, but hasn't been able to collect it in five months because his refugee card has expired. In the tide of refugees he is caught in an eddy of statelessness: He must go to Baghdad to renew the card, but Kurdish authorities won't let him travel without an ID.

"A man needs to participate in society, needs to have an identity in order to have honor,'" Ibrahim said.

So nearly seven decades after he climbed aboard a truck that would carry him into a life of exile, Mahmoud wants to pick up and leave one more time, hoping he can find a lasting home for his children.

"My homeland? Any place would be better than here. I want to go abroad so I can give my children an education or a profession they can live from," he said. "Tomorrow I won't be here. I'm an old man."

___

Associated Press writer Salar Salim contributed to this report from Baharka Refugee Camp, Iraq.

___

Follow Bram Janssen on Twitter at www.twitter.com/bramjanssen