the Almoravid leader Yahya ibn Ibrahim went on a hajj. On his way back he met Malikite preachers in Kairouan, and invited them to his land. Malikite disciple Abd Allah ibn Yasin accepted the invitation. Traveling to Morocco, he established a military monastery or ribat where he trained a highly motivated and disciplined fighting force. In 1054 and 1055, employing these specially trained forces, Almoravid leader Yahya ibn Umar defeated the Kingdom of Ghana and the Zenata Berber. After Yahya ibn Umar died, his brother Abu Bakr ibn Umar pursued an Almoravid expansion. Forced to resolve a Sanhaja civil war, he left control of the Moroccan conquests to his brother, Yusuf ibn Tashfin. Yusuf continued to conquer territory; and following Abu Bakr's death in 1087, he became the Almoravid leader. After their loss of Cordoba, the Hammudids had occupied Algeciras and Ceuta. In the mid-11th century, the Hammudids lost control of their Iberian possessions, but retained a small taifa kingdom based in Ceuta. In 1083, Yusuf ibn Tashufin conquered Ceuta. In the same year, al-Mutamid, king of the Taifa of Seville, traveled to Morocco to appeal to Yusuf for help against King Alfonso VI of Castile. Earlier, in 1079, the king of Badajoz, al-Mutawakkil, had appealed to Yusuf for help against Alfonso. After the fall of Toledo to Alfonso VI in 1085, al-Mutamid appealed again to Yusuf. This time, financed by the taifa kings of Iberia, Yusuf crossed to al-Andalus and took direct personal control of Algeciras in 1086. Modern history The Kabylians were independent of outside control during the period of Ottoman Empire rule in North Africa. They lived primarily in three states or confederations: the Kingdom of Ait Abbas, Kingdom of Kuku, and the principality of Aït Jubar. The Kingdom of Ait Abbas was a Berber state of North Africa, controlling Lesser Kabylie and its surroundings from the sixteenth century to the nineteenth century. It is referred to in the Spanish historiography as ; sometimes more commonly referred to by its ruling family, the Mokrani, in Berber ( ). Its capital was the Kalâa of Ait Abbas, an impregnable citadel in the Biban mountain range. The most serious native revolt against colonial power in French Algeria since the time of Abd al-Qadir broke out in 1871 in the Kabylie and spread through much of Algeria. By April 1871, 250 tribes had risen, or nearly a third of Algeria's