The pressure of Austria and Russia on the northern Ottoman frontiers since the beginning of the 18th century had encouraged insubordination among local governors in the largely decentralised Arab provinces of Ottoman Syria. In 1768, while the Russian Empire was suppressing a Polish uprising near the Ottoman border, a Cossack regiment chased some of the rebels across the border and reportedly carried out a massacre in the town of Balta. The Sultan eventually responded by declaring war on Russia. He demanded military assistance from Ali Bey, a Mamluk, who was the most powerful official in Ottoman Egypt at the time. Ali closely observed the course of the war, sending the required 3,000 soldiers to the aid of the Sublime Porte in 1769. Early in the following year, however, he declared Egypt's independence, chiefly in response to the war with Russia. Later he struck an alliance with Zahir al-Umar, a wealthy Arab ruler in northern Palestine. Ali and Zahir shared common ground in their opposition to Islamic fundamentalism, the Sultan's isolationist policies towards Europe and the imposition of Ottoman dignitaries to their courts.