Mold and mildew are some of the main threats to wood beams. Mold and mildew break down the fibers in the structure, causing the beams to become weak and eventually collapse as they rot. Cleaning the mold off as soon as you discover it is the best way to prevent future problems. This may take a bit of work but will be worth it in the long run.
Mix a combination of bleach and water in a bucket. Use about 1 cup of bleach and a gallon of water for painted or sealed wood beams. Use a 3-to-1 ratio of water to bleach for unpainted surfaces.
Dip a sponge in the cleaning solution and squeeze out some of the water. Rub the sponge on the mold and mildew area to kill it. This might take a few applications.
Use a clean sponge and plain water to rinse the area, then dry as much as possible with a clean rag. If moisture is an issue, set up a fan to dry the beam.
Use a superfine sandpaper to sand off the mold and mildew if cleaning doesn't work. Use long strokes so the sanding will even out. If the mildew runs deep, the beam might have to be replaced.