Check where the wires come down from the mast into the cabin. There will be a removable panel fitted inside the main cabin at the base of the mast. Inside that area all of the cables have a join which will allow the mast to be taken down if required for maintenance/mast safety reasons, and hence the need for the cable joins. Photograph every cable join with your mobile phone camera before you start taking anything apart, no exceptions !!
Determine which wires lead to the mast head light, you will have one negative wire and two positives, that’s one positive for the tricolour, and one positive for the anchor light plus the common negative. Firstly before any wires are undone check that you have 12 volts between each of the positive wires and the common earth, most likely you will have. Next is to disconnect one of the positive wires, and with your avometer set to read resistance check that you have a circuit through each of the positive wires individually and back through the common negative wire, though not necessarily both circuits at the same time unless both are switched on. Here it is quite likely that there is no circuit, indicating either a faulty bulb (very common) or a poor circuit due to corrosion on the ends of the original wires (unfortunately also very common), or a combination of faulty bulb and corrosion.. Bavaria in their wisdom used to use ordinary copper wire for all circuits onboard, and this corrodes very easily in a salty atmosphere. Much better to use tinned copper wire.
You can try cleaning the ends of the wires at that junction point below the base of the mast in the hope that it’s just corrosion, otherwise it’s a trip to the top of the mast to check the bulb. If you’ve not done that before, then get someone to help you who has done it, and check, check and re-check that the halyard you or your friend will use to hoist them up the mast is in good and safe condition for the job, plus one more as a safety line. Good luck.