What to do when advisor does not want to work together?
Since you want to go forward, rather than quit, you have only a few options. One is to find a way to get everyone, including yourself, calmed down and focused on the future. The other is to find a different advisor locally or at another university. 

I don't think it is unusual to work on a problem for a while and have it end up with nothing. I've done that and so have many others. However, your advisor should have been more aware of the situation if the work had previously been done. But your literature search should also have turned up a hint of that, at least. 

Maybe someone at your university can set up a "soothing the waters" meeting in which you all come to an understanding of the way forward for you. Focus on the future, not the past. If there is blame about the past, then it is likely shared. It is also normal for people to be upset, and your advisor may be acting badly because s/he is embarrassed about misleading you. 

You probably need to have that meeting even if you want to move to another university so as to make it possible to get good recommendations. Nothing good will come from acting out of anger or in the presence of the anger of others.