When you start pulling out old walls and you see staining or just general decay, don't just assume you can slap up some fiberglass and be done. The biggest mistake people make is trying to solve the insulation problem before they've solved the moisture problem. If the wall is wet, none of the insulation matters.
First, you need a proper inspection of the framing. Look at the headers and the vertical studs for signs of serious rot from past leaks. If the wood is soft, you might need to replace sections before you even think about filling the cavities. You want a solid skeleton to put the insulation into. After the structure is solid, focus heavily on air sealing. Seal every gap and penetration around pipes and wires. That prevents thermal bridging and stops humidity from getting trapped inside the wall cavity. Then, you install your insulation, ensuring it fits snugly without leaving gaps. Finally, remember the vapor barrier. You have to place that correctly based on your climate. It's not just about keeping heat in; it's about managing where moisture goes. Get that setup right and you'll be in good shape.