Train users have been spared pain on Wednesday's commute with the drivers' union and Metro striking a late night agreement preventing major service disruptions.

Melbourne's train network faced potential meltdown when the Rail, Tram and Bus Union planned industrial action that would take more than half of Metro's train fleet out of operation due to safety fears.

The union took the severe course of industrial action over two safety-related faults with Metro's Comeng and Siemens type trains, which together account for about 126 of Metro's 200-odd strong fleet.

The action would have crippled the city's metropolitan rail network, which carries 232 million passengers a year.

Metro filed an application with the Fair Work Commission late Tuesday evening seeking to stop the action, calling it "unprotected" and "unlawful".