KHARTOUM/JUBA Sultan Kwaje's problems started when his country disappeared from under him.
He was born in the southern part of Sudan but has lived in the north for more than three decades. When South Sudan broke away as an independent country from Sudan in July, Kwaje was left on the northern side of the border, a foreigner.
The Sudanese government, he said, fired him from his job in the civil service.
Tens of thousands of South Sudanese in the north lost their jobs after the split. About 500,000 are now technically illegal because they lack official residency papers.
"I just want to leave," said Kwaje who lives in Wad al-Bashir camp, one of several slums on the outskirts of Sudan's capital Khartoum. "I am still owed all my severance rights but I just want to leave now. Life is bad. We don't have jobs, no food, don't get medical treatment."
As border fighting between Sudan and South Sudan has threatened to turn into all-out war over the past three weeks, much of the attention has focused on the countries' unresolved disputes over oil revenues.
But the crisis has also shone a light on the plight of the of hundreds of thousands of people who found themselves on the wrong side of the border at independence and are now treated as foreigners.
In Juba, the capital of South Sudan, thousands of Sudanese citizens also face a new government that has declared them expatriates, though it has not yet imposed any new rules for residency papers.
Plans for two deals that would grant each other's citizens residency and free movement stalled when Khartoum called off a summit in protest at border fighting.
Sudan's government initially gave southerners until April 8 to get the right papers or leave. But South Sudan has struggled to set up a functioning embassy in Khartoum to issue passports or identity cards.
"I am still waiting for my travel permit from the embassy," said Moussa Majok, another South Sudanese living in the camp.
"I went there to register but I still haven't got the papers," he said, drawing nods from others. "They don't care about us," he said, referring to the southern government.
About 400,000 South Sudanese, who initially came to the north fleeing poverty and conflict, have returned home since October 2010. Many more are packing up to make the long journey south in Wad al-Bashir camp, where thousands live in makeshift homes made of wood, mud bricks or corrugated iron.
Bags, bed frames, chairs and other furniture were piled high next to a green mosque on a large square last week, waiting to be loaded onto trucks.
Worries over religious tensions are also fuelling the exodus.
Most South Sudanese are Christian or follow traditional beliefs, while Sudan is mostly Muslim. Last weekend, hundreds of Muslims stormed a Khartoum church complex used by South Sudanese, ransacking buildings and burning bibles.
Even when they get the required travel papers, southerners are stuck because fighting has blocked most roads near the border, according to the International Organisation for Migration (IOM), which helps people return home.
The barge route down the Nile is also blocked. Sudan halted river traffic in March, accusing Juba of using boats to transport weapons to rebels in the north.
Both governments also suspended direct flights between the two countries. Tickets via Kenya or Ethiopia cost up to four times what Sudanese carriers charged last year.
In sign of Khartoum playing hardball, authorities ordered 12,000 southerners waiting for months at Kosti port for barges to leave the camp area within one week, state news agency SUNA said late on Sunday.
"May 5th is the last day for southerners to stay in Kosti port. Authorities have taken measures to expel them to another place," SUNA quoted the local state governor as saying. He said the southerners in the area were posing a security and environmental threat.
SUDANESE STAYING IN JUBA
In a bustling market in Juba last week, Sudanese traders swapped stories in front of stalls selling mobile phones and sun-baked vegetables.
So far, northerners living in the south say they have not faced the same level of official or social ostracism as southerners in Khartoum. Many northerners in Juba want to stay put.
But beneath the buzz in the market, there was an undercurrent of apprehension.
"We are scared that one of these days they'll ask us for identification papers," said 23-year-old Zulfid, sitting behind a glass window selling Chinese-made mobile phones.
Zulfid, went to school in Khartoum but struggled to set up a business in the Sudanese capital. "The government confiscates your goods. There's bribery."
He had an easier time in the South.
"In Juba, taxes are less, the dollar is cheaper. Life and business is much better than in the North," he said,
Saeed Zakariya, a bubbly 25-year-old who sells mobile phone accessories in Juba, got a hint of the legal challenges that may lie ahead if Sudanese President Omar al-Bashir and South Sudanese President Salva Kiir fail to find a solution to the citizenship issue.
"I tried to book a ticket to fly to Malakal (another city) in South Sudan), but my papers were not accepted," Zakariya said. He gave up and stayed in the southern capital.
All the traders that Reuters spoke to said they had faced no mistreatment or ill-will from South Sudanese.
"We are not afraid of being made to go back to the north. Their difference is political, not on the ground. Not a single person has asked me where I'm from," said Mohamed Suleiman, who came to Juba in 2009 when he could not find a job in his Sudanese hometown in Sennar state.
Yaber, a 54-year-old man living in Juba since 1979, agreed.
"We are very happy. We're the same people, the same family," he said. His son, Diyaaeldine was born in the south and the family has no intention of leaving.
Smoking a cigarette in a stall filled with rows of rubber slippers, Yaber, who refused to give his full name, said he was not worried about his future in Juba.
"We share the same life, there is respect," Yaber said.
(Writing by Ulf Laessing and Yara Bayoumy; Editing by Simon Robinson and Andrew Heavens)