 After Congress, Perry served as associate judge of the sixth judicial district of Maryland from 1851 to 1861 and again from 1864 to 1871.He was also a delegate to the State constitutional convention in 1867.He died in Cumberland at the age of 64, and is interred in Rose Hill Cemetery.