He was chiefly pre-occupied with repulsing the last Norman attacks (966, 971), and with the struggle against the Zirids and the Fatimids in northern Morocco.
Even on the coast the Zirids were not unchallenged - Tunis was lost to the Banu Hurasan (1063–1128).
After the loss of Kairouan (1057) the rule of the Zirids was limited to a coastal strip with Mahdia as the capital, while several Bedouin Emirates formed inland.