like D says, depends on how the old ones were installed. I removed my factory rail and had to fill those holes. I drilled those old holes out with a countersunk bit to get to fresh wood, then mixed some thinned epoxy andpainted in the holes so it would wick into the clean wood a little bit. Then i filled with marine Tex and sanded flush. Color will not match, but should prevent water intrusion. You can use epoxy mixed with a filler , but epoxy needs to be protected from the sun, so you would need to paint.
this is a couple of holes i filled with an epoxy mixture as u can see it shrinks a litle over time. these were filled about 10 years ago
they aren t pretty, but not worried about water