Before installing Eclipse IDE on Ubuntu or Linux, you must have Java 8+ installed on your computer.
tar -xzvf eclipse-jee-2019-06-R-linux-gtk-x86_64.tar.gz
sudo mv eclipse /opt
sudo gedit /usr/share/applications/eclipse.desktop
It will launch an empty file. Copy and paste the followings into the empty file, as shown below:
[Desktop Entry] Name=Eclipse Type=Application Exec=/opt/eclipse/eclipse Terminal=false Icon=/opt/eclipse/icon.xpm Comment=Integrated Development Environment NoDisplay=false Categories=Development;IDE; Name[en]=eclipse.desktop
sudo desktop-file-install /usr/share/applications/eclipse.desktop
cd /usr/local/bin sudo ln -s /opt/eclipse/eclipse
The installation is complete.
After installation, you can launch Eclipse IDE from Applications menu by searching with the Eclipse keyword. When you open it for the first time, it will ask you to specify workspace, once done, main page will be loaded.