He entered the United States Navy, 2 May 1815, as a midshipman, from Maryland. Commissioned a lieutenant in 1825, he commanded the USS Relief, and made a five-years' cruise with the United States Exploring Expedition. In 1841 he was promoted commander and helped to successfully carry out an expedition to prevent the invasion of Mexican territory by the filibuster William Walker.
After being commissioned captain, in 1855, he engaged in destroying the slave trade. His father was Bernard Dornin, the publisher.