Muhammad b. Shaddad b. Qurtaq about the year 340/951-2, in the time of the detention of the Sallarid al-Marzuban, gained control of Dvin, probably invited by the Muslims of the town as a protector. Ibrahim b. al-Marzuban, who tried to preserve his father's interests, incited a Christian vassal to attack Muhammad, but the latter defeated him. Ibrahim then sent an army of Dailamites and Kurds which expelled the Shaddadid. Soon he was recalled, however, by the people of Dvin, who were dissatisfied with the Dailamite garrison, and foiled an attempt of the Bagratid king Ashot III of Ani to conquer the town. In 343/954-5 he was driven out by a Dailamite army sent by al-Marzuban, who had regained the rule in Azarbaijan. Muhammad and his clan found shelter in Vaspurakan. He vainly sought Byzantine support to recover Dvin and died in 344/95 5-6.
The eldest of Muhammad's three sons, al-Lashkari Abu'l-Hasan £AK, became chief of the clan and entered the service of the Armenian Grigor, ruler of Pharisos, and received from him Shothkh and Berd-Shamiram as fiefs. The youngest brother, al-Fadl (Fadlun), at first served Naja al-Saifi, governor of Diyarbakr for the Hamdanid Saif al-Daula. When Naja was killed in 354/965, he returned to his brothers, but as he did not want to serve the Christians he soon left with the intention of joining the Sallarid Ibrahim in Azarbaljan. As he reached Ganja, Ibrahim's governor of the town, 'All al-Tazi, invited him to stay and guard it against hostile neighbours. He soon had occasion to prove his usefulness in warding off an attack of the Siyavurdiyya (Sevordi), Armenidzed Hungarians living west of Shamkur.
When he again made up his mind to leave for Azarbaljan the notables of Ganja persuaded him to stay and invite his brother al-Lashkarl to come to Ganja. Al-Lashkari at first refused to join al-Fadl, but the latter induced him by a ruse to come and then was able to persuade him to stay. The people of Ganja co-operated with them arresting the governor and opening the gates for them. Al-Lashkari in 360/971 took possession of Ganja and killed the governor. The Sallarid Ibrahim in 361/971-2 laid siege to Ganja but failed to take it and withdrew after concluding a peace which must have practically recognized the independence of the Shaddadid. Al-Lashkari took possession of the region, expelling the Dailamites, and gradually expanded his territories as far as Shamkur to the northwest and Bardac a to the east. He died in 368/978-9.