In 194/809-10 Tahir joined the general Harthama b. A'yan in operations against Rafi' b. al-Laith, a grandson of the last Umayyad governor of Khurasan Nasr b. Sayyar. Rafi' had in 190/806 raised up a serious and protracted rebellion against caliphal authority, attracting support from the Iranian populations of Transoxiana and Khwarazm as well as from the Turks of the surrounding steppes. By 194/810 the fragile peace between the two 'Abbasid brothers al-Amin and al-Ma'mun, the chief legatees of their father Harun al-Rashid's power, was already crumbling. In the complex succession arrangements made by Harun in 182/798 and confirmed at Mecca in 186/802, it had been laid down that al-Ma'mun, governor of all the Persian lands east of Hamadan, should follow al-Amin in the caliphate, with a third brother, al-Qasim al-Mu'tamin, governor of al-Jazira and the fortresses along the Byzantine frontier, as next in line. Urged on by his vizier al-Fadl b. al-Rabi' and by 'Ali b. 'Isa b. Mahan, former governor of Khurasan, al-Amin in 194/810 declared the succession rights of al-Ma'mun and al-Qasim to be null and void, and he proclaimed his infant son Musa as heir, with the honorific al-Ndtiq bi'l-Haqq. Al-Ma'mun retaliated by dropping his brother's name from the khutba or Friday sermon in his territories and from the coins minted by him there, and by cutting the band network of communications between Khurasan and Iraq. In 195/810-11 Tahir became commander of the army posted by al-Ma'mun at Ray to confront al-Amln's forces at Hamadan. In the subsequent battle, 'Ali b. 'Isa b. Mahan was defeated and killed; and one of the explanations given for Tahir's nickname of Dhul Yaminian "the man with two right hands" or "the ambidexter" is that in this battle he cut a man in two with his left hand. The historians praise Tahir's skilful generalship in deploying his troops, whom he urged to "attack with the fury of the Kharijites" and also his use of spies. Al-Ma'miin's subsequent victory is generally regarded as a triumph of the Persian east over Arab Iraq. His cause was certainly helped by local memories of 'Ali b. 'Isa b. Mahan's tyrannical rule in Khurasan, and by Tahir's denunciations at Ray of the opposing army as being a rabble of predatory Bedouins and mountain brigands; al-Ma'mun's maternal descent from Marajil al-Badghisiyya, one of Harun's Persian concubines, and his known Persian sympathies, must also have helped. Tahir pressed on after his victory at Ray and overran the whole of Jibal, inflicting further blows on al-Amin's armies and advancing through Ahvaz to the capital itself. When Baghdad at last fell to Harthama and Tahir, Tahir's Persian soldiers slew the captive al-Amln (198/813); certain sources say that al-Ma'mun later came to hold Tahir responsible for his brother's murder.