With the outbreak of the Civil War, Peck, despite his wealth and political connections, enlisted as a private in the 9th Louisiana Infantry on July 7, 1861. After training at
Camp Moore in Louisiana, Peck and his fellow soldiers in the
regiment were sent to
Virginia, arriving too late for any significant participation in the
First Battle of Manassas. Peck was commissioned as
captain and then
lieutenant colonel of the 9th Louisiana during the
Gettysburg campaign, and saw action at the
Second Battle of Winchester in June and the
Battle of Gettysburg in July, where he was involved in the twilight attack on
Cemetery Hill. On October 8, 1863, Peck was promoted to
colonel of the 9th Louisiana to succeed
Leroy A. Stafford. He led the regiment in the battles of the
Wilderness,
Spotsylvania, and
Cold Harbor in May and June 1864 during the
Overland Campaign. Peck often led the brigade as the senior colonel, and his role in the July 1864
Battle of Monocacy drew praise from his division commander,
Maj. Gen. John B. Gordon. He was wounded in the right thigh by a shell fragment at the
Third Battle of Winchester in September. He did not return to the field until December. Peck was promoted to
brigadier general on February 18, 1865. He was paroled in Vicksburg on June 6 of that year. ==Postbellum==