Former Mountjoy Prison governor John Lonergan has apologised to the family of Gary Douch, who was killed in the jail eight years ago.
A report published yesterday found that the Irish Prison Service missed key warnings about the killer.
Speaking on RTÉ's Morning Ireland, Mr Lonergan said: "The prison service was inadequately resourced to provide the sort of support that a prisoner like Stephen Egan required.
"Inpatient facilities for people like him were, and still are, inadequate."
The investigation found that Egan was not medically assessed on arrival at Mountjoy.
Mr Lonergan said: "He should have been medically examined but the knowledge was there. People knew that he had a very serious psychiatric difficulty."
He said Egan ended up in a holding cell with five other people because of overcrowding.
"It was like trying to fit ten litres of water into a five-litre container, it doesn't work. Mountjoy was grossly overcrowded during that period of time," he said.
Mr Lonergan said he had previously refused to admit Egan, but he was admitted on a weekend when he was on annual leave.
He said Mr Douch's death should never have happened.
Mr Lonergan said he is angry about that because he and others had warned the government about overcrowding at Mountjoy Prison on many occasions.