Install NetBeans IDE on Debian 11

|
Last Updated:
|
|

In this tutorial, we will cover how to install NetBeans IDE on Debian 11. NetBeans IDE is a free and open source extensible Java IDE (Integrated Development Environment) that enable software developers to quickly and easily develop Java desktop, Java EE, and web applications, as well as HTML5 applications with HTML, JavaScript, and CSS. The IDE also provides a great set of tools for PHP, Ruby and C/C++ developers.

Install NetBeans IDE on Debian 11

Install Java Development Kit on Debian 11

In order to run NetBeans IDE, you need to have installed Java Development Kit version 8 or above. In this guide, we use Java 11, which is the default available version on Debian 11 main repos.

apt update
apt install default-jdk

To verify the version of the installed Java development kit, run the command below;

java -version
openjdk version "11.0.14" 2022-01-18
OpenJDK Runtime Environment (build 11.0.14+9-post-Debian-1deb11u1)
OpenJDK 64-Bit Server VM (build 11.0.14+9-post-Debian-1deb11u1, mixed mode, sharing)

Installing NetBeans IDE on Debian

There are different methods in which you can install NetBeans IDE on Debian. These include;

Install NetBeans on Debian using NetBeans installer script

NetBeans provides a script that makes it installation easier. Navigate to Apache NetBeans downloads page and grab the installer script for Linux. You can simply run the command below to download it (for version 12.6).

apt install wget -y
wget https://dlcdn.apache.org/netbeans/netbeans-installers/12.6/Apache-NetBeans-12.6-bin-linux-x64.sh

Once download, run the installation script as non root user with sudo rights it as follows;

sudo sh Apache-NetBeans-12.6-bin-linux-x64.sh

The script will launch the NetBeans installation wizard. Note that you need to be non-root user with sudo to run the script, otherwise you may get such an error;

No X11 DISPLAY variable was set, but this program performed an operation which requires it.
Exception: java.awt.HeadlessException thrown from the UncaughtExceptionHandler in thread "main"

When the installer runs;

  • If you want, you can customize your installation, otherwise, click Next to proceed.
Install NetBeans IDE on Debian 11
  • Accept the EULA and proceed.
  • Choose the installation path for your NetBeans application. Otherwise, click next to accept the default.
Install NetBeans IDE on Debian 11
  • Check the installation summary and install NetBeans on Debian 11.
Install NetBeans IDE on Debian 11
  • Once the installation is done, click Finish to close the installation wizard.
  • NetBeans IDE should now be installed on your Debian 11 system.

Install NetBeans from Snap on Debian 11

If you need to get the latest version of NetBeans installed and running on Debian 11, you can install it from snaps using the snap package manager.

On Debian 11, Snapd is not installed by default, hence run the command below to install it.

sudo apt install snapd -y

Once that is done, you need to install the core snap in order to get the latest snapd.

But before you can install core snap, Log out of your system and re-login or simply reboot;

Once you re-login to your system, then install core snap.

sudo snap install core
snap version

Check the available version of NetBeans provided by the Snap repos;

snap info netbeans

name:      netbeans
summary:   Apache NetBeans IDE
publisher: Apache NetBeans✓
store-url: https://snapcraft.io/netbeans
contact:   https://lists.apache.org/[email protected]
license:   Apache-2.0
description: |
  Apache NetBeans IDE lets you quickly and easily develop Java desktop, Java
  EE, and  web applications, as well as HTML5 applications with HTML,
  JavaScript, and CSS. The IDE also provides a great set of tools for PHP and
  C/C++ developers.
  It is free and open source and has a large community of users and
  developers
  around the world.
  
  It requires Java 8 or later Java Development Kit installed.
  
  Disclaimer:
  This is a convenience binary of Apache NetBeans IDE, this is not an
  official release.
snap-id: JyXqEgtoFceo2Ppmyr1XrbqOoRIkNRrS
channels:
  latest/stable:    12.6   2021-12-06 (52) 527MB classic
  latest/candidate: ↑                            
  latest/beta:      ↑                            
  latest/edge:      13-rc2 2022-01-28 (55) 459MB classic

Well, as you can see, it got the latest version of NetBeans which you can then install using snap package manager;

sudo snap install netbeans --classic

Running NetBeans on Debian 11

In all the methods, once the installation is done, NetBeans should now be available among your system applications.

netbeans ide debian 11

You can just launch and start using it.

netbeans ide ubuntu 22.04

Read more on NetBeans IDE Knowledge base.

Uninstall NetBeans IDE on Debian

If you ever want to remove or uninstall NetBeans IDE on Debian systems installed using this method, navigate to the NetBeans install directory and execute the uninstall script.

cd /usr/local/netbeans-12.6

Similarly, run the uninstall script as non root user with sudo provileges;

sudo ./uninstall.sh

If you installed using SNAP, then remove using the command below;

sudo snap remove netbeans

And that brings us to the end of our simple tutorial on how to install NetBeans IDE on Debian 11.

Other Tutorials

Install NetBeans IDE on Ubuntu 22.04

Install Mantis Bug Tracker on Ubuntu 20.04

Install Bugzilla Bug Tracker on Debian 10

SUPPORT US VIA A VIRTUAL CUP OF COFFEE

We're passionate about sharing our knowledge and experiences with you through our blog. If you appreciate our efforts, consider buying us a virtual coffee. Your support keeps us motivated and enables us to continually improve, ensuring that we can provide you with the best content possible. Thank you for being a coffee-fueled champion of our work!

Photo of author
gen_too
Co-founder of Kifarunix.com, Linux Tips and Tutorials. Linux/Unix admin and author at Kifarunix.com.

Leave a Comment