It probably became "common practice" as raising domestic cattle became more common (OK, that's "duh", bear with me). A certain number of births have difficulties, and sometimes you have to milk the mother, or another mother, to supply the baby. Humans have wetnurses. Animals aren't so accepting of other babies, so humans do the milking. That gives you the technical skills to do it.
After that, somebody probably just got thirsty.
Anyways, people milk cows, water buffalo, horses, sheep, reindeer, and goats. I don't know about llamas, camels (though I'd assume so), or pigs. Frankly, I wouldn't want to milk a pig just because pigs are mean SOBs with big biting teeth (as are camels, but I don't think a camel would -eat- you -- a pig would).
It's my understanding that western europeans are the only people to regularly drink large quantities of cow milk -- most people in the world are lactose intolerant, and can't process it.
Cheers
Nell.