My PC has been crashing a lot of times recently, it suddenly stops responding and after a few seconds, it asks me to force quit some apps. At first, I thought it was a problem with VSCode since it always happens when I'm editing something on it, but it recently has happened with other apps like Spotify or my browser.
When I used the top
command, I noticed there is this Java process that is consuming more than half of my RAM and I think this could be the reason for the crashes I've been experiencing. The thing is, that I don't know how to get rid of it.

I tried killing the process with the kill
command hundreds of times, but it keeps appearing there whenever I use the top command. I tried these commands and also manually removed anything related to jdk, openjdk, etc. using the apt-get remove
command.
I restarted the computer, and the process is still there. I don't know what else I can do.
pstree
says the full command path is /usr/share/elasticsearch/jdk/bin/java
, but the elasticsearch folder doesn't even exist in there. I looked with the apt list --installed
and did not find any elasticsearch in there. The pstree command only shows this:
