Millions of people were left in the dark in Havana and the country’s provinces.