Muhammad Gasa, a relative of Ahmad ibn Ibrahim al-Ghazi and Nur ibn Mujahid, was elected imam on September 1577.
Hararis hoped that Muhammed, because of his illustrious lineage, he would create a new sense of unity, and inspire them to resist within the walls, if not lead them to victory outside of them.
To their disappointment, the first thing Muhammed did when he came to power was to transfer the capital from Harar to Aussa in the Afar desert.
In 1583 Muhammad was killed while in battle with the Warra Daya Oromos.
His death was followed by a succession crisis in which eight imams succeeded each other in less than five years.