Sweat drips from Aqeel Hassan as he tinkers with a labyrinth of wires that connect 270 homes in Baghdad's sprawling Sadr City. It is a thankless job, but a crucial one amid another scorching heatwave.

His workplace is a humble shack right in front of his home, which comprises a bed, pigeons in a pen to keep him company and more than 200 colour-coded switches, running to a loud, humming diesel generator.

Hassan is the neighbourhood's generator handyman, whose job involves installing and repairing the wires and switches to make sure his generator keeps running smoothly.

Iraqi Aqeel Hassani, who owns a private electric generator, helps to power 270 homes when the faltering national grid breaks down yet again Iraqi Aqeel Hassani, who owns a private electric generator, helps to power 270 homes when the faltering national grid breaks down yet again Photo: AFP / Sabah ARAR

The system supplies power to the homes in the block when the decrepit national grid breaks down, yet again. As summer temperatures sizzle above 50 degrees Celsius (122 degrees Fahrenheit), residents are increasingly reliant on his supply.

"I don't have a start time when I clock in, I'm always on, 24 hours a day," the burly 42-year-old, whose arms are covered in tattoos of Shiite sayings and saints, told AFP.

He says he just fell into the job of maintaining generators after the US invasion in 2003.

There are an estimated 4.5 million privately-owned generators across Iraq, propping up the decrepit and neglected national grid There are an estimated 4.5 million privately-owned generators across Iraq, propping up the decrepit and neglected national grid Photo: AFP / Sabah ARAR

Iraq -- the second largest producer in the OPEC oil cartel -- buys gas and power from neighbouring Iran to supply about a third of its energy sector, dilapidated by decades of conflict, poor maintenance and rampant corruption.

But Iran decided last month to cut power supplies to its western neighbour, saying the Iraqi electricity ministry owes it more than $6 billion in arrears.

That has left the national electricity provider Wataniya unable to keep up with soaring demand from the country's 40 million people.

When the national grid fails, private generator owners spring into action -- keeping fridges and air conditioning running, but also teenagers' computers When the national grid fails, private generator owners spring into action -- keeping fridges and air conditioning running, but also teenagers' computers Photo: AFP / Sabah ARAR

"Our generators are working overtime these days -- around 22 hours a day," Hassan said. Customers pay him to switch on his generator when the national grid fails. Although sometimes he says he provides electricity for free to the poorest.

"When electricity comes from the national grid, the alarm sounds and I go switch off the generator so it can rest."

His five-year-old son Muslim loves it when it is time to power down, and rushes to help his father who lifts him up to reach the highest switches.

Iraqis walk under a labyrinth of cables linking homes to private electric generators in Baghdad's Sadr City Iraqis walk under a labyrinth of cables linking homes to private electric generators in Baghdad's Sadr City Photo: AFP / Sabah ARAR

Sadr City is the capital's most densely populated suburb with over one million low-income households tightly packed next to each other.

Named after the late Shiite scholar Ayatollah Mohamed Sadr, it is clear how revered he still is, with posters, banners and framed pictures of his powerful son Moqtada Sadr adorning every home.

Hassan is his neighbourhood's generator handyman, installing and repairing the wires and switches to ensure the generator runs smoothly Hassan is his neighbourhood's generator handyman, installing and repairing the wires and switches to ensure the generator runs smoothly Photo: AFP / Sabah ARAR

There are 4.5 million privately-owned generators nationwide, estimates Harry Istepanian, a Washington-based independent energy consultant and senior fellow of Iraq Energy Institute.

Each household spends "on average around $100-200 per month on electricity (which) is equivalent to a $6 to $10 billion business for privately-owned generators, but it neither contributes to the country's economy nor pays taxes," he said.

"There is no law that regulates the industry as it is highly connected to the political elites and armed militias. It is part of Iraq's complicated network of illicit businesses and black economy," Istepanian added.

Mortada Ali, 22, is the last in a chain of people profiting off the business. He answers to his boss who owns several generators in the area.

"I have to stay near the switches. I didn't choose this, there's just nothing better around. I wanted to open up a shop, or even join the Iraqi army," he lamented.

"I can't get married because I just can't leave this spot. This is my whole life. My life could get easier if Wataniya powers the grid more, so I can rest," said the softly-spoken young man.

Splitting his time between school and helping his father maintain the family's three generators, Karrar Hamed invites his friends over to hang out.

His crammed air-conditioned room has a flat-screen TV, a smartphone for receiving customer calls to pay for their power and an iPad, his most prized possession.

He is addicted to playing popular videogame PUBG.

"Power comes on for about 12 hours a day intermittently, so I have to be alert for when it goes out," the 17-year-old said.

Istepanian said Iraq's electricity woes and the dependence on this alternative network will likely endure for some time.

"There is no quick fix for the electricity shortages, especially during peak seasons. The government needs to take bold steps in liberalising the sector," he said.

"It would take decades for Iraq to develop an efficient and competitive energy market."

As he responded to another request from a neighbour to switch on his home, Hassan predicted the situation "will never be solved".

"The state is too corrupt."