You run java commands but you get the error "/usr/bin/java no such file or directory." What should you do?
Possible Solution #1
Possible Solution #2
You may have deleted a linked file. To find the destination file, run this:
sudo find / -name java -type f
Based on the results, run a variation of this command draft (but substitute "/path/to/file/from/above/java" with the full path of the file found in the above command):
Then run this command (but substitute according to the results of the original "sudo find" command):
sudo ln -s /path/to/file/from/above/java /usr/bin/java