Lockheed P-2 Neptune - the great submarine hunter

Developed near the end of WW2, for the US Navy by Lockheed to replace the Lockheed PV-1 Ventura and PV-2 Harpoon, the Lockheed P-2 Neptune had its first flight on May 17, 1945, and enter service in 1947. 

Up until the mid 1960s, the Neptune was the primary U.S. land-based anti-submarine patrol aircraft. It could launch sonobuoys from a station in the aft portion of the fuselage and monitore them by radio. Some of them had  twin .5 in (12.70 mm) machine guns in the nose, others had AN/ASQ-8 Magnetic Anomaly Detector or  AN/APS-20 surface-search radar enabled detection of surfaced and snorkeling submarines.

It was used until the mid 1970s.

In 1954 under Project Cherry, 5 of the planes were bought by the CIA for their own private fleet of covert ELINT/ferret aircraft.