Rebuilt 340 knocking sound

The cylinders with open valves suffer from hot/cold humidity weather "breathing".
Moored marine engines particularly prone to that kind of corrosion .
Need to be "pickled", spray storage oil in the cylinders while running and shut off. Tough on a diesel as they run on about any oil or hydrocarbon. Best to start and run until warm every 2 to 4 weeks.