Garibaldi was also made head of the Uruguayan navy. During this siege Uruguay had two parallel governments:  The Argentinian blockade of Montevideo was ineffective as Rosas generally tried not to interfere with international shipping on the River Plate but, in 1845, when access to Paraguay was blocked, Great Britain and France allied against Rosas, seized his fleet and began a blockade of Buenos Aires, while Brazil joined in the war against Argentina. Rosas reached peace deals with Great Britain and France in 1849 and 1850 respectively. The French agreed to withdraw their legion if Rosas evacuated Argentinian troops from Uruguay. Oribe still maintained a loose siege of the capital. In 1851, the Argentinian provincial strongman Justo José de Urquiza turned against Rosas and signed a pact with the exiled Unitarios, the Uruguayan Colorados and Brazil against him. Urquiza crossed into Uruguay, defeated Oribe and lifted the siege of Montevideo. He then overthrew Rosas at the Battle of Caseros on 3 February 1852. With Rosas's defeat and exile, the "Guerra Grande" finally came to an end. Slavery was officially abolished in 1852. A ruling triumvirate consisting of Rivera, Lavalleja and Venancio Flores was established, but Lavalleja died in 1853, Rivera in 1854 and Flores was overthrown in 1855. The government of Montevideo rewarded Brazil's financial and military support by signing five treaties in 1851 that provided for perpetual alliance between the two countries. Montevideo confirmed Brazil's right to intervene in Uruguay's internal affairs. Uruguay also renounced its territorial claims north of the Río Cuareim, thereby reducing its area to about 176,000 square kilometers, and recognised Brazil's exclusive right of navigation in the Laguna Merin and the Rio Yaguaron, the natural border between the countries. In accordance with the 1851 treaties, Brazil intervened militarily in Uruguay as often as it deemed necessary. In 1865, the Treaty of the Triple Alliance was signed by the Emperor of Brazil, the President of Argentina, and the Colorado general Venancio Flores, the Uruguayan head of government whom they had both helped to gain power. The Triple Alliance was created to wage a war against the Paraguayan leader Francisco Solano López. The resulting Paraguayan War ended with the invasion of Paraguay and its defeat by the armies of the three countries. Montevideo, which was used as a supply station by the Brazilian navy, experienced a period of prosperity and relative calm during this war.