Police officers stand in front of the school building in Sanski Most, northwest of Bosnia's capital, Sarajevo on Wednesday.
Sarajevo, Bosnia Reuters  — 

Three members of staff at a high school in western?Bosnian were killed on Wednesday when a cleaner opened fire with an automatic rifle before trying to take his own life, police said.

The gunman killed the dean, the secretary and an English teacher who had just retired and gone back to help her replacement at the school in the town of Sanski Most, police said.

No children were killed or injured. The shooting occurred during the summer holidays, but some students were on the premises for repeat exams, cantonal police director Amel Kozlica said.

The gunman, identified by police as school cleaner Mehmed Vukalic, sustained a gunshot wound to the chest, was conscious and was awaiting surgery, physicians from the Banja Luka hospital told N1 television.

Sanski Most, a small town of around 40,000 people, was in shock.

“We are trying to comprehend why this happened,” Mayor Faris Hasanbegovic told a news conference. “There are no words or justification for this.”

Some school employees told N1 television that Vukalic was unhappy with his job as a cleaner and had suffered from PTSD after the?Bosnian war in the 1990s, resulting in absences from work.

Mass shootings are?comparatively rare?in the Western Balkans which is awash with weapons that remained in private hands from the wars.

In July, a war veteran in neighboring Croatia shot five people including his mother in a nursing home and wounded six others.

This story has been updated with additional information.