Upon his graduation from West Point, Garnett was assigned as a second lieutenant in the 4th U.S. Artillery in July 1841. He spent a year on the Northern Frontier during the Canada Border Disturbances, serving in Buffalo and Fort Ontario in New York before being assigned garrison duty at Fort Monroe in his native Virginia. In 1843 Garnett became an assistant tactics instructor at West Point before becoming an army recruiter and then an Aide-de-camp to General John E. Wool. Garnett served in the Mexican–American War under Zachary Taylor and received two brevets for distinguished service, one at the Battle of Monterrey and the other for "Gallant and Meritorious Conduct" in the Battle of Buena Vista.