Answer: He attacks Iago just because he is so miserable.
Explanation: The second time he attacks Othello is after Othello has killed Desdemona and it is exposed that he killed her from believing Iago's lies. Then he stabs at Iago and wounds him, but doesn't kill him.