The oldest techniques were drying and salting foods. Herbs and fish were dried. We still dry foods today, for dried spices and meat jerky, which provides a quick, protein-rich snack.
Salt was gathered from the earth, whether by evaporation of sea water or from another source, and spread on foods to draw out moisture. If a crock, jar, or waterproof basket were handy, then the food was soaked in a brine solution. This promoted fermentation and the development of healthy probiotic cultures.
Cheeses are often salted or brined after the whey is drained and curds pressed together, to retard spoilage and add flavor.
Fermentation takes a little while, and the food is not ready for consumption until the fermentation action stops. This can take as little as a week to as long as 4 months. Once the fermentation is completed, the food can be placed in jars and processed to store for many months - to many years.
In the historic old west, a large barrel was used to make pickles, and the cucumbers were weighted down with large stones. The barrel was covered with a cloth to keep out debris. This open barrel was often in the middle of the store and anyone was welcome to drink the solution (it's high in electrolytes) or grab a pickle.
Source: Gary Soup