Surface-mounted railing posts are fastened with lag screws down through the post base and into the deck framing below. Typically, a large screw with a length of 4"-6" and a shank diameter of 5/16" or similar is use, which prevents flex and pullout.
We recommend adding vertical blocking secured to adjacent members with screws or nails, to give the post a full 4-1/2" width of framing. This width (only slightly narrower than a post base) gives enough foundation to secure the lag screws to. Lag screws may need to be angled slightly to land in the body of the blocking, pre-drilling is sometimes helpful.
We don't recommend laying post blocking flat, since that would require two or three layers of blocking to provide enough material to completely embed the screw threads.
