A train fire Wednesday afternoon prompted the need for firefighters and HazMat units in Montgomery.