David Porter ( naval officer ) David Porter ( February 1 , 1780 – March 3 , 1843 ) was an officer in the United States Navy in a rank of commodore . Porter commanded a number of US naval ships , including the famous USS " Constitution . He saw service in the War of 1812 , the Second Barbary War of 1815 and in the West Indies . He was later court martialed ; he resigned and then joined and became commander - in - chief of the Mexican Navy . Early life . Born at Boston , Massachusetts , Porter served in the Quasi - War with France first as midshipman on board , participating in the capture of " L ’ Insurgente " February 9 , 1799 ; secondly , as 1st lieutenant of and later in command of " USS Amphitheatre " . During the First Barbary War ( 1801 – 07 ) Porter was 1st lieutenant of , and and was taken prisoner when " Philadelphia " ran aground in Tripoli harbor October 31 , 1803 . After his release on June 3 , 1805 , he remained in the Mediterranean as acting captain of and later captain of " Enterprise " . Marriage and family . Porter married Evalina Anderson , and they had 10 children who survived , including six sons . The older David Porter Sr . met and befriended another naval veteran of the Revolution , George Farragut , from Spanish Minorca . In late spring 1808 , David Porter Sr . suffered sunstroke , and Farragut took him into his home , where his wife Elizabeth cared for him . Already weakened by tuberculosis , he died on June 22 , 1808 . Elizabeth Farragut died of yellow fever the same day . Motherless , the Farragut children were to be placed with friends and relatives . While visiting Farragut and his family a short time later to express thanks for their care of his father and sympathy for their loss , Commodore Porter offered to take eight - year - old James Glasgow Farragut into his own household . Young James readily agreed . In 1809 he moved with Porter to Washington , where he met Secretary of the Navy Paul Hamilton and expressed his wish for a midshipman ' s appointment . Hamilton promised that the appointment would be made as soon as he reached the age of ten ; as it happened , the commission came through on December 17 , 1810 , six months before the boy reached his tenth birthday . When James went to sea soon after with his adoptive father , he changed his name from James to David , and it is as David Glasgow Farragut that he is remembered . The town of Porter and Porter County in Northwest Indiana are named after David Porter . In 1836 the county seat of Porter County , Indiana was originally named Portersville , also named for David Porter . It was changed to Valparaiso in 1837 , named for Porter ' s participation in the naval action near Valparaíso , Chile during the War of 1812 . Naval career . Porter served in the Quasi war as a midshipman on board the USS Constellation under the command of John Rodgers . As lieutenant he served as second in command of the schooner during the action of 1 January 1800 , in which he got shot in his arm . He was in charge of the naval forces at New Orleans 1808 – 10 . War of 1812 . As commander of USS " Essex " in the War of 1812 , Captain Porter achieved fame by capturing the first British warship of the conflict , HMS " Alert " , August 13 , 1812 as well as several merchantmen . In February 1813 he sailed " Essex " around Cape Horn and cruised the Pacific warring on British whalers . Porter ' s first action in the Pacific was the capture of the Peruvian vessel " Nereyda " , and the releases of the captured American whalers on board . Over the next year , Porter would capture 12 whaleships and 360 prisoners . In June 1813 , Porter released his prisoners , on the condition that they not fight against the United States until they were formerly exchanged for American prisoners of war . Porter ' s usual tactic was to raise British colors to allay the British captain ' s suspicions , then once invited on board , he would reveal his true allegiance and purpose . Porter and his fleet spent October – December 1813 resting and regrouping in the Marquesas Islands , which he claimed in the name of the United States and renamed them the Madison Islands , in honor of then - President James Madison . On March 28 , 1814 Porter was forced to surrender to Captain James Hillyar off Valparaíso after an engagement which became known as the Battle of Valparaiso with the frigate MHS " Phoebe " and the sloop HMS " Alert " , when his ship became too disabled to offer any resistance . West Indies . In 1814 he was given command of the USS " Firefly " , the flagship of a five ship squadron destined for the West Indies to disrupt British shipping ; however , a peace treaty with Britain was signed and the mission was canceled . From 1815 to 1822 , he was a member of the Board of Navy Commissioners but gave up this post to command the expedition for suppressing piracy in the West Indies ( 1823 – 25 ) . While in the West Indies suppressing piracy , Porter invaded the town of Fajardo , Puerto Rico ( a Spanish colony ) to avenge the jailing of an officer from his fleet . The American government did not sanction Porter ' s act , and he was court - martial ed upon his return to the U . S . Porter resigned and in 1826 entered the Mexican Navy as its commander - in - chief 1826 – 29 . Later life . He left the Mexican service in 1829 and was appointed United States Minister to the Barbary States . He died on March 3 , 1843 while serving as United States Ambassador to Turkey . He was buried in the cemetery of the Philadelphia Naval Asylum , and then in 1845 reburied in the Woodlands Cemetery in Philadelphia , Pennsylvania . Porter was played by Jeff Chandler in the film " Yankee Buccaneer " ( 1952 ) .