None of our lights worked reliably when we first brought our trailer home. I later figured out that the contacts on the switches were bad. I also quickly figured out the switches were a different size than standard RV store switches.
After taking out the two rivets, and removing the switch cover I found just a simple 12v
switch. I used needle nose pliers to bend the little tabs back on the back of the switch, removed the contact board off the back, cleaned, reapplied dielectric grease, stretched the spring slightly to help create better contact, and reassembled. Took less than a few minutes a switch and fixed all the not working lights. Of course might want to check at the socket and switch wires to confirm you have 12v
at those points first. If not, I think you'd have to drill out rivets to get the light fixture out to check for broken connections, but that would be a lot more work to get inside there.