Just to belatedly chip in my two pennies worth!
There is a post on using an overboard anode connected to the ram .. I'll see if I can find it.
Mike Lockwood said "However, we inserted a stainless steel bolt through the deck hatch above the keel, connected this to the top of the keel with a coiled wire. When not sailing, we connect the deck end of the bolt to an over-the-side anode (an old hull anode usually). We measured a 0.5V potential between the keel and the over-the-side anode. Some battery! Extracting the ram is not the easiest job but is essential. Three pairs of hands make it a little easier. We also keep the keel up when on our mooring."Having a cradle saves time pressure. I have to rely on the yard's boat mover, so their last job of the day is to lift me on the slings until I can just see where the bolt hole will be, and leave me there. I then have to lift the ram, replace the anode and refit the ram before the light goes and the yard returns the next morning to put me in the water! I use the main halyard to ensure the lifting and lowering is under control.
There is an awful lot of detritus around that lower eye bolt. Power washing and scraping allows the eye bolt to go back into its place.
Unscrewing old hydraulic hoses can mean that on reconnecting there can be a slight weep, with consequent loss of fluid. I found this the hard way, and simply refitted using plumbers PFTE tape. I did this after asking about and being told that would be fine. Comments welcome.
I think it was obvious, but secure the lower eye bolt first. Having the ram on a halyard means that wiggling about can be safer. When the eye first appears get a screw driver in there, and try and get it to line up with the bolt.
Cover everything - but obviously not the anode - with Denso tape and grease - see
https://denso-tape.co.uk Ferries use it. It was covering the ring anode with Denso tape that probably caused the corrosion that locked the piston in my ram.
For a story on how to replace the whole ram once it had seized solid in the "up" position ...