In this paper,the welding repair method of oil filter of marine mainframes made of gray cast iron is studied. Through the analysis of gray cast iron and duplex stainless steel materials and their weldability,the technology of transition layer welding of heterogeneous metal is used to repair the fuel filter of the mainframes. Welding lengthens the nozzle on the broken side of the filter to ensure sufficient space for welding. It also formulated a reasonable welding process,conducted a simple welding test on metals of the same material as the fuel filter to verify the feasibility of the process,and then performed repair work on the main fuel filter,and adopted a series of measures to control the welding cracks of gray cast iron. The defects of the main engine fuel filter were eliminated,and the corresponding inspection was carried out after welding,so that the main engine fuel filter was repaired success-fully,and the system operated well,ensuring the transformation cycle of the XX ship.