ditch (n.)
Old English dic "ditch, dike," a variant of dike (q.v.). Last ditch (1715) refers to the last line of military defenses.
ditch (v.)
late 14c., "surround with a ditch; dig a ditch;" from ditch (n.). Meaning "to throw into a ditch" is from 1816, hence sense of "abandon, discard," first recorded 1899 in American English. Of aircraft, by 1941. Related: Ditched; ditching.