A member of the Mus'abid family, Muhammad was the brother of Ishaq ibn Ibrahim, the long-running chief of security ("shurtah") of Baghdad, and first cousin to Abdallah ibn Tahir, the Tahirid governor of Khurasan. He participated in the caliph al-Mu'tasim's Amorium campaign of 838, during which he commanded the troops following the vanguard, and was shortly after responsible for putting to death Ujayf ibn Anbasah, who had participated in a failed conspiracy to assassinate the caliph. In the following year he led the caliphal troops that participated alongside Abdallah ibn Tahir's campaign against the rebel prince Mazyar in Tabaristan, and he fought a successful battle against Mazyar's lieutenant al-Durri, who he captured and executed.