San Francisco, CA
No one knows! Well, two people know, but they're extremely dead at this point, since the original German brewer and his son-in-law were the ones who bought an SF brewery in 1896 and renamed it Anchor. The brewery says, "no one knows why [the founders] chose the name Anchor, except, perhaps, for its indirect but powerful allusion to the booming Port of San Francisco." If we were lawyers, we'd object with something like, "Pure speculation!" to those claims and just leave it at "boats."
The explanation for the Maryland-based brewery's name is about as loopy as you'd expect from a beermaker associated with Hunter S. Thompson's deranged cohort, Ralph Steadman. As the brewery tells it, one of Flying Dog's founders, George Stranahan, just finished a dangerous hike in Pakistan when they were having a celebratory drink back at the hotel. It was there that they say was a "full-on oil painting of a dog. A beautiful oil painting, big, nice. And the dog was like... well, he had left the ground." Stranahan says the two words fit together for him. Good enough for us, George.