He stressed that it was an act that needed to be condemned.
Mr Mahama made the observation when he joined Muslims at the Independence Square in Accra to mark this year's Eid-Ul- Adha festival.
He however cautioned that the isolated case of human right abuse should not be used as a general measure to mar the reputation of the highly disciplined Ghana Armed Forces.
“We all know we have a much disciplined military. They have received awards on peacekeeping and the isolated incidence should not be used to characterise Ghana's army,” he said.
Mr Mahama gave the assurance that perpetrators of the conflict would be brought to justice whilst those who smuggled ammunitions to the area would be apprehended.
Speaking on the insecurity situation in Bawku and surrounding areas, Mr Mahama called on Muslims in the area to use the festival to reflect on how they could co-exist in peace and security.
He expressed worry that the town, which was once noted for its economic activity in the North, is now unable to contribute towards national development owing to the conflict.
“Bawku is strategically located in the North-Eastern corner of the country, which once served as a commercial centre. However because of the insecurity, teachers, nurses, doctors and others are leaving the place,” he said.
Mr Mahama called on the Muslim community to take drastic steps to improve the literacy level among them.
He said education was one of the effective tools the country could use to reduce poverty and attain its socio-economic development agenda.
Mr Mahama noted that most developed countries attained higher economic status because they prioritised education.
He expressed dissatisfaction that Ghana was still struggling with “some 70 per cent literacy rate, with the Muslim communities and especially the Northern part of the country recording as low as 50 per cent”.
“Illiteracy is what is preventing us from achieving the quality of life we want,” he said.
He advised the Muslim youths to carry on the merrymaking activities in a more disciplined and relaxed manner to promote peace and security.
Mr Mahama lauded the peaceful co-existence among the various religious groups and stressed that it should not be taken for granted.
Mr Mahama said religion must unite the people and not separate them.
In a sermon, Chief Imam Sheikh Osman Nuhu Shaributu, said Eid-Ul-Adha was a day of sacrifice for Muslims and urged the worshippers to submit to the will of their creator, Allah.
He called on adherents to sacrifice for the poor and needy in order to please Allah.
Sheikh Shaributu said there was the need to empower the youth in moral uprightness to discourage them from engaging in the cyber crime, popularly known as 'Sakawa.'
He called on the worshippers to live with each other in peace and security in order for the country to attain its socio-economic agenda.
Eid al-Adha is the second of the two Eid festivals celebrated by Muslims across the world and usually takes place a day after the pilgrims conducting the annual pilgrimage to Mecca in Saudi Arabia, descend from Mount Arafat.