In 1671, he was sent as visitador (inspector) to Nuevo Reino de Granada in what is now Colombia because of the inaction of Diego de Villalba y Toledo, president of the Audiencia. He replaced Villabla in that position on June 2, 1671. At the same time he served as interim governor and captain general of Nuevo Reino de Granada. On February 8, 1672, Pope Clement X, appointed him Archbishop of La Plata o Charcas.[2] On June 14, 1677, Pope Innocent XI appointed him Archbishop of Lima.[2] On July 7, 1678, he was appointed viceroy of Peru serving until November 20, 1681. As viceroy, he improved the fortifications of the port of Callao to defend against attacks by Dutch filibusters. He repressed rebellions of the clergy, who were opposed to the nomination of prelates from Spain—the Franciscans in Cuzco and the Dominicans in Quito.[citation needed]
On the death of the Peruvian astronomer Doctor Francisco Ruiz Lozano, Viceroy Liñán y Cisneros (with the approval of the Crown) gave mathematics a permanent position in the University of San Marcos. Mathematics was attached to the chair of cosmography. Doctor Juan Ramón Koening, a Belgian by birth, was named to the chair.[2]
As a reward for his services, the Spanish Crown granted Liñán y Cisneros the title of conde de la Puebla de los Valles. He wrote Ofensa y defensa de la libertad eclesiástica (Offense and Defence of Ecclesiastical Liberty). He died in Lima in 1708.[citation needed]