northern Syria, and parts of western Iran. He established an effective administration, but the incessant campaigning, and the need to keep the soldiery satisfied, meant that it was almost totally geared towards providing the funds necessary to maintain the army. Nevertheless, al-Mu'tadid managed to accumulate a considerable surplus in his ten-year reign. At the same time the bureaucracy grew in power, it also saw a growth in factionalism, with two rival "clans" emerging, the Banu'l-Furat and the Banu'l-Jarrah. The two groups represented primarily different factions in a struggle for office and power, but there are indications of "ideological" differences as well: many of the Banu'l-Jarrah families hailed from converted Nestorian families and employed Christians in the bureaucracy, in addition to maintaining closer ties with the military, while the Banu'l-Furat tried to impose firm civilian control of the army and (not quite openly) favoured Shi'ism. Al-Mu'tadid took care to prepare Ali, his oldest son and heir-apparent, for the succession by appointing him as a provincial governor: first in Rayy, Qazvin, Qum and Hamadan, when these provinces were seized from the semi-autonomous Dulafid dynasty in , and in 899 over the Jazira and the frontier areas, when Al-Mu'tadid deposed the last local autonomous governor, Muhammad ibn Ahmad al-Shaybani. The future al-Muktafi took up residence at Raqqa. The religious scholar Ibn Abi al-Dunya, who enjoyed al-Mu'tadid's confidence, was appointed as Ali's tutor. Caliphate When al-Mu'tadid died on 5 April 902, al-Muktafi succeeded him unopposed. His father's vizier, al-Qasim ibn Ubayd Allah, ordered the oath of allegiance to be taken in his name, and took the precaution of locking up all Abbasid princes until al-Muktafi arrived in Baghdad from Raqqa (20 April). Character and government The new caliph was 25 years old. The historian al-Tabari, who lived during his reign, describes him as of "medium size, handsome, of a delicate complexion, with [a full head of] beautiful hair and a luxurious beard". Al-Muktafi inherited his father's love of buildings. He completed al-Mu'tadid's third palace project, the Taj ('Crown') Palace, in Baghdad, for which he reused bricks from the palace of the Sasanian rulers in Ctesiphon. Among its numerous buildings was a semicircular tower, known as the 'Cupola of the Ass' (). The caliph could ride to its top mounted on a donkey, and from there gaze on the surrounding countryside. On the site of his father's palace prisons, he also added a Friday mosque