Under the Umayyads, Muslims came into direct contact with Turks in their homeland which lay east of Khurasän and Transoxania. However, after the Turks had submitted to the Islamic state, the Caliphs, in particular the Abbasid Caliphs, began to employ them in various roles such as guards and soldiers. They served alongside the veteran Arabs and Iranians, because the Turks, unlike these others, did not so pride themselves on their nationality that they behaved exclusively. The Turks were valued for their bravery and fidelity. The Caliph Mu'tasim, in fact, increased their number, and his reliance on them was a result of his needs and of certain other circumstances. After the death of Mu'tasim, the Turks rose to positions of considerable importance in all the affairs of state. They had an even greater influence on the running of the Caliphate when they began to interfere in the appointing of the Caliph, which they did for the first time in the case of Mutawakkil. Nevertheless, none of the Abbasid Caliphs from Mutawakkil onwards seemed to acquiesce readily in Turkish control, and indeed they resisted the Turks vigorously. They tried to eliminate them and their power entirely, and to restore the dignity of the Abbasid Caliphate. As the first step in escaping the interference of the Turks, the Caliphs decided to move the state capital. But when the Turks realized the Caliphs' intentions, they began to plot against them and to assassinate them. In the course of this struggle between the Turks and the Caliphate the civil war of 251 H occurred. As a result, government authority weakened, particularly in those outlying regions furthest from its power and influence. Therefore, popular movements and attempts to gain independence emerged in many provinces, such as Hijaz, Armenia, Syria and Iran. In fact, most of these movements were not aimed against the Caliphate itself, but against the Turks who dominated affairs of state. At the same time the power of the (Wazir) minister of state began to diminish, and his remaining in office was closely linked with the desires of the Turks. In addition, the Turks attempted to take over the Vizirate itself. Therefore, some of them, such as Waif and Autamish, occupied this office although they were quite unqualified for it. In consequence, the Vizirate deteriorated and became powerless, just as the Caliphate had done.