Spliced rope.....
.... with the 'loop' doubled around the piling.If this is a permanent knot, then the 'stangler knot' (similiar to a clove hitch) would do. If this is for an exposed location, then also consider 'worming, parceling and serving' for chafe protection.