Grounding grid in substation is vital for preserving the safety and reliability of power system, protecting the operator and electrical equipment. The material of grounding grid usually is flat steel in our country, and the grounding grid buried deeply in the ground, making it susceptible to corrosion and failure. Based on fault diagnosis theory and electrical network theory, the writer establishes a grounding grid fault diagnosis equation, and solves this equation by Optimization Algorithm. Finally the writer gets the proportion of each branch of the change in resistance.