After Harun's death in Khurasan in early 809, Abdallah remained in the province, joining the court of Harun's second heir, al-Ma'mun (r. 813–833), at Marw. In the subsequent civil war between al-Ma'mun and his half-brother, Caliph al-Amin (r. 809–813), he remained largely on the sidelines at Marw. He was one of several military leaders who refused to head al-Ma'mun's government, a post which eventually fell to Fadl ibn Sahl. His relations with al-Ma'mun were strained, but he accompanied him westwards and was with him when he entered Baghdad in 819.