Zengid dynasty
Al-Mustarshid achieved more independence while the sultan Mahmud II of Great Seljuq was engaged in war in the East. The Banu Mazyad (Mazyadid State) general, Dubays ibn Sadaqa (emir of Al-Hilla), plundered Bosra and attacked Baghdad together with a young brother of the sultan, Ghiyath ad-Din Mas'ud. Dubays was crushed by a Seljuq army under Zengi, founder of the Zengid dynasty. Mahmud's death was followed by a civil war between his son Dawud, his nephew Mas'ud and the atabeg Toghrul II. Zengi was recalled to the East, stimulated by the Caliph and Dubays, where he was beaten. The Caliph then laid siege to Mosul for three months without success, resisted by Mas'ud and Zengi. It was nonetheless a milestone in the caliphate's military revival.