When the
Philippine–American War broke out, he was in the
Philippines and was assigned by Gen.
Antonio Luna as lieutenant general in
Manila. On February 23, 1899, Llanera and his troops were with Luna's forces when the latter staged a
counterattack in Caloocan to prevent the Americans from invading further north. The counterattack, however, was only partly successful because the Kawit battalion refused to move. Llanera was later caught by the Americans during the same year. He was deported to
Guam on January 16, 1901, with
Artemio Ricarte and 30 more military officers of the Revolution considered
Irreconcilables by the Americans. He returned to the
Philippines in February 1903 in response to the demand of the people of the
United States. ==Death and legacy==