Thousands of Indian troops spent hours battling a huge fire emanating from a highly polluted lake, causing panic among thousands of people in the southern city of Bangalore, the army have said.

Nearly 5,000 soldiers swung into action yesterday after the fire threatened a military area with huge clouds of smoke billowing from the lake filled with sewage, chemical effluents and construction debris and choked with water hyacinth, an army statement said.

The army said the efforts prevented the fire from engulfing civilian areas of Banagalore, one of India's key information technology hubs.

Fire engines and water bowsers from nearby civilian areas also assisted in controlling the fire. A huge smoke was still rising from the area on Saturday morning with firefighters trying to douse it completely.

In 2015, a toxic froth spilled over to some of Bangalore's streets due to extreme levels of pollution in the Bellandur Lake. Tests found extremely high amounts of phosphorous and other inorganic chemical compounds in the lake.

Authorities have been trying to repair a barrier that was supposed to keep sewage from flowing into the lake, depleting its oxygen.

Another Bangalore lake caught fire in May last year when garbage was set ablaze on its bed.