On 28 May 1789, he was appointed as the grand vizier (highest rank of the empire other than that of the sultan). But he was sick in bed when he received the sultan's letter of appointment. So he was nicknamed "Cenaze" (corpse). On 22 September he personally led the army against the Austrian-Russian alliance in the Battle of Rymnik (called "Boze" by the Turks). But he was defeated. After this defeat he was dismissed on 2 December 1789.