As his father, Mustafa aimed at greater independence, and when Mahmud II's Ottoman military reform efforts threatened to deprive him of his hereditary rights and privileges, he became hostile to the sultan and maintained friendly relations with Serbian Prince Miloš Obrenović, the discontented Bosniaks and Muhammad Ali of Egypt. Thus, he was passive in the early stage of the Russo-Turkish War (1828–29), only in May 1829 he appeared with his Albanians on the Danube (Vidin, Rahovo), then continued to Sofia and Philippopolis, without taking active part in the fighting.