Barrel aging is really a fun thing to do because it brings flavors and aromas to beer that are simply unachievable using other methods. New barrels can be used to introduce vanilla and toasted notes to beer. Oak spirals and chips can be used for similar flavors, but barrels do more than add oak flavor. As beer ages in oak it slowly oxidizes due to the ingress of oxygen through the porous structure of the staves. This is one of the reasons that microaerophilic organisms such as Brettanomyces species, Lactobacillus species, and Pediococcus species grow relatively well in barrels. It is also the reason why brewers and vintners are concerned about using used barrels if the idea is not to make funky beer or funky wine, which really has failed to become as popular as funky beer. OK, funky wine is totally unacceptable, but I digress.
Whether starting out with new or used barrels, there are a few things you can do to help ensure a positive barrel aging experience. With a new barrel you can tackle two concerns at once by filling the barrel with nearly boiling water to sterilize the surface of the barrel and hydrate the wood and help the barrel seal before use. Since wood is a good insulator the water will stay hot for several hours. I typically leave new barrels filled with water for 6 hours or so and then empty the barrel by syphoning the water to the floor. Allowing the water to cool to about 140 °F (60 °C) makes this process a little less steamy. After the barrel is empty you can go ahead and rack your beer into the barrel.
If you have a used barrel the chances of having microorganisms inside of the barrel are much more likely than starting with a new barrel. It is common to clean barrels by rinsing with cold water, then warm water and finally hot water after use to remove the different types of soils that are deposited in the barrel during use. It is not uncommon to use a mild cleaner, such as sodium carbonate, after the barrel has been thoroughly flushed with water. After cleaning and drying, elemental sulfur sticks can be burned and sealed in the barrel to create a sulfur dioxide fog that suppresses the growth of organisms. This process needs to be repeated about once every four weeks to preserve the integrity of the barrel. Using other types of sanitizers, including Star San, is not common with the use of barrels.
When it comes to barrel aging, the duration of aging depends on several factors. If you use a barrel that previously contained another product and your intent is to flavor your beer with this product you may find that little time is required. I have barrel aged stout in 8-gallon (30-L) whiskey barrels for four weeks and ended up with some really stellar products. I have also aged beer in new oak barrels for a few months and have extracted more vanilla flavors than I really wanted. On the other extreme I have aged beer in barrels with Brettanomyces and have had to wait more than a year to achieve the results I wanted.
One interesting side note about using bourbon and Scotch barrels is the subject of bacteria. It seems that these barrels would not be vectors for contaminants. Mitch Steele, Head Brewer of Stone Brewing Co., noted that they have actually found this assumption to be false and that used bourbon and scotch barrels can harbor bacteria. The likely reason for this is that these barrels are emptied somewhere, certainly not very near San Diego, stored, shipped and then used. During this time the interior surface of the barrel is exposed to air. Since the charred surface of whiskey barrels is porous, it is a good environment for bacteria to colonize.
When putting beer in a barrel you should consider drilling a small hole in the lower portion of one of the heads and plugging the hole with a stainless steel nail. The nail can be removed to pull a sample. This will help minimize damage to your beer from sampling with a thief. This is especially true if the beer has a Brettanomyces pellicle that helps protect the surface from oxygen and subsequent colonization by Acetobacter, which converts ethanol into acetic acid (vinegar). The other thing I strongly recommend is to be patient. If you sample the barrel and do not taste what you desire, wait at least a month for sampling again. Excessive sampling simply reduces the batch size.