Agustín Gamarra Messia was a military man, president of the Republic. He embodies the figure of the caudillo of the first years of our republican life. He was born in Cuzco on August 27, 1785 . He was the son of Don Francisco Gamarra, a Spanish scribe, and Doña Josefa Petronila Messia, an indigenous woman of modest birth. He began his military career in 1809 as part of the royalist army, later serving in the troops that General José Manuel de Goyeneche led to Upper Peru; he later fought in Guaqui (1811), Salta and Tucumán (1812), Vilcapuquio and Ayohuma (1813). In 1814, when the Angulo brothers and chief Pumacahua rose up in Cuzco, Gamarra offered to subdue the movement, fighting from Oruro under the orders of General Ramírez. He victoriously entered La Paz and Arequipa, being promoted to lieutenant colonel on January 7, 1815, attending the decisive battle of Umachiri on the following March 11. He was a member of the pacification board in charge of judging and punishing those who participated in the rebellion, but due to his condescension towards the guilty, he was excluded from the court. He helped put Cuzco's administration in order until 1816, working as an interim revenue accountant. Promoted to the rank of colonel, he went to Puno with an administrative position, and in 1820 he was appointed chief of the first battalion of the Cuzco regiment.
He decided at that time to embrace the cause of Creole independence, supporting the rebellion of Colonel Centeno in Lima and participating in a conspiracy in Tupiza , which did not materialize because the rebels were betrayed by General Olañeta. In the midst of these circumstances, Gamarra was brought to Lima to serve as Viceroy La Serna's aide-de-camp. His fidelity to the Spanish monarchy lasted little longer, because he appeared before the headquarters of San Martín in Huaura (1821) and joined the emancipating army. He was sent to the central highlands with the mission of forming a regular army based on the montoneras that acted in the region. On April 14, 1821, he had to face the royalist army commanded by Mariano Ricaforte, with negative consequences for Gamarra, who ended up being prosecuted, although he was later exonerated of all guilt. In a second campaign to the central highlands he served under Argentine General Álvarez de Arenales, but was defeated at the Battle of Concepción. Next he went to the patriot detachment commanded by General Pío Tristán, with which he headed for the Ica Valley. Misfortune wanted Gamarra to be defeated at the Macacona meeting (April 7, 1822), after which he was tried and suspended from the military for four months. In the midst of the political turmoil that Peru was going through, Marshal José de la Riva Agüero was appointed President of the Republic , offering Gamarra the Ministry of War, which our character rejected. Instead, he was promoted to brigadier general (April 8, 1823) and left with General Andrés de Santa Cruz for the second Intermedios expedition, which lasted from May to September 1823. Bolívar's arrival being imminent, Gamarra He hastened to express his support. He participated in the glorious battle of Ayacucho (1824), although his intervention was not duly mentioned by Sucre in the report sent to Bolívar , an omission that Gamarra would never forgive. In any case, he received promotion to general of division in January 1825 and was immediately appointed prefect of Cuzco and military chief of the southern departments. That same year he married Doña Francisca Zubiaga in Zurite, who would come to be known by the nickname of "La Mariscala".
In 1827 Gamarra was elected deputy for Lampa . Invested with this dignity, he entered Bolivia militarily to force Sucre and the Colombians to withdraw, ending "northern" influence in the Chuquisaca government. After the Treaty of Piquiza, celebrated on July 6, 1828, Gamarra left Upper Peru (henceforth he was known as Marshal of Piquiza). He then had to intervene in the war with Gran Colombia, being in the front row in the battle of Pórtete de Tarqui (February 27, 1829), where the Colombians declared themselves winners. Gamarra suffered heavy losses and decided to carry out a military coup against President La Mar in the north, banishing him to Costa Rica. he was called for elections in Congress and on August 31, 1829, he was appointed as president of the Republic for a constitutional period of four years , a period in which he faced no less than fourteen revolutions. He failed in the attempt to form the Peru-Bolivian Confederation, had to face the anarchy caused by the liberals and was immersed in a serious economic crisis. In the elections called at the end of his government, General Luis José de Orbegoso was elected, who was not Gamarra's preferred candidate. A civil war immediately broke out, in which the Marshal of Piquiza was defeated in Maquinhuayo, emigrating to Bolivia, in order to seek an agreement with his friend Santa Cruz. When the Peru-Bolivian Confederation was established, however, he changed his flag and went out to seek the support of Ecuador and later that of Chile, in order to organize a great "restoration" expedition. This put an end to the Confederation regime thanks to the victories achieved in the Cover of the Guide (August 21, 1838) and in Yungay (January 20, 1839).
On July 10, 1840 Agustín Gamarra again agreed to the presidency of the Republic . His first concern in government was the pacification of the country, despite the uprising carried out by Manuel Ignacio de Vivanco in the mountains of Ayacucho, Cuzco, Arequipa and Puno. All these foci of subversion were controlled, until leaving the confrontation with Santa Cruz as the only problem. To prevent this caudillo from reestablishing his rule in Bolivia and relying on the support of José Ballivián, Gamarra declared war on Bolivia, losing his life in the battle of Ingavi, on November 18, 1841 . Gamarra was then 56 years old. His wife "La Mariscala" had died previously, during her exile in Valparaíso.