Remove as much snow as possible from the top of the ice dam along the roof's edge and, if you can, from a few feet above the ice dam. Use a roof rake, which is specifically designed for this task, or a push broom.
Fill the melt sock or nylon stocking with a suitable de-icer. Some de-icing compounds can corrode or discolor certain roofing materials that they come into contact with. Avoid using traditional rock salt -- sodium chloride -- and instead use a compound labelled as safe for roofs, or a less damaging chemical de-icer such as calcium magnesium acetate.
Place the ice melt socks across the ice dam. Make sure that the sock extends beyond the roof edge to create a clear drainage channel. Concentrate socks in areas near where leaks exist or are most likely to occur. If a ladder is needed to place the socks along the roof edge, make sure the ladder is firmly set on even ground. Use a spotter if possible.
Check on the melt socks every few days and move or refill them as needed to maintain drainage channels across the ice dam.