Despite being a protege of the Duke, who would soon after become the viceroy of Sicily, his military career was slow and, finally, in 1623, as a captain of the tercio raised by Pedro Henriquez de Acevedo, Count of Fuentes, he went to Flanders, where he spent eleven years, seeing action at the sieges of Breda (1624) and 's-Hertogenbosch (1629), at the Capture of Maastricht (1632) and at Stevenswert (1632).
However, following his bravery at the defeat at Leucate in 1637, action for which he had volunteered, Garay was pardoned by King Felipe IV, who ordered him back to Italy and recommended him for promotion.
[1] Garay arrested several leading local figures in August, causing the viceroy to write to him "begging him not to provoke a complete break with the Catalans because this might entail the loss of the Principality and the ruin of Spain".
[1] On 11 October 1640, Garay wrote to the King that the "licentiousness of the clerics and the religious in the convents of this diocese, all of whom have reached the last stages of sedition for in the confessionals and the pulpits they spend their entire time rousing the people and offering the rebels encouragement and advice, inducing the ignorant to believe that rebellion will win them the kingdom of heaven".
[2] In reward for his services, Philip IV promoted him to maestre de campo general and governor of Arms of Extremadura, commissioning him to assess the state of the fortifications in Navarre and Guipúzcoa.
Although it was late in the year, Garay managed to raise a small, select army and left Lerida in September, passing through the comarca of Pla d'Urgell and attacked Vimbodi and Poblet, Cabra del Camp, Montblanc, Valls, Constantí.
As the commander-in-chief of the French forces, John Gaspar Ferdinand de Marchin, Comte de Granville (who would later serve under Philip IV),[2] had prepared Barcelona for an attack, Garay abandoned that line of attack and headed inland into the Penedés, where he defeated the French cavalry at Villafranca (17 October) and at Montblanc (14 November) on his way back to Lerida, having left Barcelona threatened by the spur at Sitges.