The 32-year-old spent three months travelling through Kenya, Tanzania, Malawi, Mozambique before finally reaching South Africa, where he says he now has asylum status.
His journey involved being crammed in a fishing boat - where he saw people suffocate to death - locked into a container, held in custody and climbing through electric fences.
Hundreds of migrants from the Horn of Africa die every year trying to reach South Africa.
Abdullah, an English teacher in private school, survived his journey. He had already been separated from his wife and three children before he left Somalia, but hopes he can now trace them and perhaps bring them to South Africa too.
He spoke to Louise Redvers in Johannesburg about his ordeal:
Fleeing with friends
When you are running away from difficulties, you don't think, the only thing you try to focus on is what's ahead.
I left Somalia about three months ago. I can't remember the exact date, when it was.
I was born in the Qardho region [northern Somalia] but I left there because there was intense fighting between the so-called al-Shabab and the government.
They each accuse you of supporting the other, so it's either that you die or you support either of them. I couldn't withstand the way of life there and when I saw a few friends of mine fleeing I just went with them.
We were hopping from one city to the other and we found ourselves in a refugee camp in northern Kenya, at Dadaab.
In the refugee camp life was difficult, you could get no help and no-one enrols you because all the focus is on the elderly and the weak.
If they see you're a bit strong, you have to fend for yourself doing awkward jobs like if you can find a donkey, you go and get firewood from the bush and sell it just to survive.
It was more like Somalia there because even though there was peace, if you can't get a life, what is there?
I talked with a few friends there who had relatives abroad and we thought: "Why don't we try and find a better place?" So after a month, I left with those friends.
We went to Nairobi by truck, and in Nairobi I worked for like a week or so, then fortunately I saw a friend of mine, we were classmates about six years back, and he had come from South Africa.
He suggested I tried some other places because life in Kenya is also becoming difficult.
So I went to Mombasa and there I saw guys who were trafficking people and they took us in a boat from Mombasa to Dar es Salaam.
I can't exactly describe the boat. It's because I am not a fisherman, but it was a big boat and we were a mixture of Somalis, Ethiopians and Eritreans.
I cannot really describe the conditions. It was unbearable.
There were 70 people packed in a boat that is supposed to transport about 45.
It was like one was sitting here, the other is sitting on your shoulder, the other is on your lap, so to breathe was very difficult and it was very cold in the night.
But if you tried even to say a word, they would kick your nose. They said they would either call the police or you keep quiet.
Some people passed away on the boat from suffocation. They were just dumped in the sea. That was one of the most frightening things.
I was not thinking if I was suffocating - I don't know how I survived, only by a miracle I think.
I paid the boat people about 10,000 Kenyan shillings, which is about $120 (£75) - it was the last money I had.
We arrived in Dar es Salaam after three days. I don't know where exactly. They took us to a house where they locked us, for about another four days.
One guy I was with managed to get some help from a relative and I asked him to take me with him where he was going and he said he would.
I remember it was the middle of the night and they packed us into a truck, a container, we were about 120 people and I think it was a 40ft container. That was even worse than the boat.
We didn't know where we were going. We didn't have any documentation and we couldn't say anything. When you travel this way you have no rights, no say, so you have to just follow the people guiding you.
When we crossed into Malawi the police found us and we were arrested and held for something like 20 days.
Then we were released. I think one of the guides managed to pay something, you don't know who your guides really are or what their relationship is with the border police.
After we were released, I tried to see if I could find any Somalis where we were in Lilongwe. Whenever you are in trouble, that is what you do, look for a relative or someone who knows your family.
We found an Ethiopian who directed us to a Somali guy. By then we were just three people as we'd split up from the group. The Somali guy kept us for three days and then he gave us some money to go to Mozambique.
We spent about 10 days in Mozambique, mostly hiding from the police, and then this other guy came for us and said he would take us to South Africa.
I don't know where the place was but I remember it was like a farm or a zoo and there were wild animals there - we could hear their noises.
I remember there were long wires in rows that we had to jump over. We had a local person guiding us.
Once we had crossed the border, we didn't know where we were but we went to find some Somalis. Then one guy who was driving to Johannesburg to buy stock for his business brought us here.
It was a Sunday when we arrived here in Mayfar. I phoned a friend of mine who is in Cape Town and he sent me some money that kept me for a week.
A refugee's life
I was told to go to Home Affairs and after about two weeks I managed to get refugee status. I know I was lucky to get this as others did not.
Now I am looking for work. I think if I try hard, I can make myself a good future. I don't know if I will bring my wife and children here. I am trying to trace them at the moment. Let me cross the bridge when I reach it.
It's not right that we make these journeys in this way, but circumstances will force you to do what you have to. Sometimes whatever life brings you, you have to look for a solution, a way out.
I don't owe anyone any money. Most of the people were doing it out of good will, out of their heart.
It is our nature as Somalis, when we are outside Somalia, we are always helpful and if we see a Somali suffering we won't just leave them.
I don't recommend anyone to take the journey I did but if you have no other choice, try your luck. That's the only message that I can give them.
I am very happy to be here. I don't know what tomorrow brings but today I am happy.