Duke Energy has pleaded guilty in federal court to environmental crimes and has agreed to pay $102 million in fines and restitution over years of illegal pollution leaking from coal-ash dumps at five North Carolina power plants.

The company's plea to nine misdemeanor counts involving violations of the Clean Water Act was part of a negotiated settlement with federal prosecutors.

Prosecutors say the nation's largest electricity company engaged in unlawful dumping at coal-fired power plants in Eden, Moncure, Asheville, Goldsboro and Mt. Holly.

The investigation into Duke began last February after a pipe collapsed under a coal ash dump at the Eden plant, coating 70 miles of the Dan River in gray sludge. However, prosecutors said that Duke's illegal dumping had been going back for years, to at least 2010.