Pigs were one of the few farm animals medieval people raised primarily for their meat. They would eat essentially any animal (at least after it got too old), but sheep were raised for wool and sheepskin (parchment), cattle for milk and leather and pulling the plow, goats for milk and wool, horses for transportation, and so on. Pigskin could be used for various projects, but the real value of pigs was found in pork roasts, ham, bacon, and sausage.
Pigs are not friendly creatures. Don't let the cute cartoon version fool you. There's a reason you never see a pig in a petting zoo. They are close relatives of wild boars, and although they were (more or less) domesticated thousands of years ago, they have never been as thoroughly domesticated as sheep or, say, dogs, most of whom have left their wolf ancestors far, far behind.
The great advantage of pigs is that they can essentially feed themselves. They, like humans, are omnivorous, eating both meat and vegetable matter. In the ancient Mediterranean, they were probably the most commonly eaten meat, because they were relatively easy to raise to full eating-size. The Jews, and after them the Muslims, rejected pork as a religious marker, which distinguished them from everybody else.
(You'll sometimes see it suggested that the Jews kept away from pork to avoid trichinosis, but this seems very unlikely—they didn't know about it specifically, it's avoidable if pork is cooked thoroughly, other animals can also have parasites, and the rest of the ancient world flourished just fine eating pork.)
Medieval people might raise a piglet out in back of the house, even in the cities. The oldest son of King Louis VI of France was killed when he and some friends were having horse races through the streets of Paris (one assumes beer was involved), and what was described as a porcus diabolicus got loose from its pen and tangled with the prince's horse, throwing him to his death.
But most pigs were allowed to be self-sufficient for most of the year (for one thing, pigs stink), at most herded into new grazing areas periodically. October in the oak woods was an especially good time, because acorns (called mast) were one of pigs' favorite foods.
In November, once the pigs were fattened up, they were rounded up and slaughtered. Pig harvest was great. Everyone ate their fill of fresh pork for a few days, probably the most meat they'd eat at one time all year, and the rest was smoked, salted, and made into ham and bacon and sausage. It was much more heavily smoked and salted than modern products, because it had to last for many months without refrigeration.
© C. Dale Brittain 2020
For more on farm animals and other aspects of life in the Middle Ages, see the ebook, Positively Medieval, available from Amazon and other on-line bookstores. Also available in paperback.