3

I've installed Netbeans 8.0 on Ubuntu 12.04. After that I updated the operating system and now the Ubuntu version is 14.04.

Netbeans was installed in the default folder. I did not specify any custom folder for installation.

Netbeans asked to install updates, but was unable to continue the operation, because Netbeans was not running under root permissions.

How can I start Netbeans with root permissions?

What sudo command should be executed in terminal to launch Netbeans as root?

I searched this in Google but did not find a working answer.

2
  • @karel I don't think the question is asking that, but rather what the command is to launch Netbeans. Aug 5, 2018 at 13:25
  • It's both I guess. The OP wants to open NetBeans, which is a graphical app, as root in order to install updates.
    – karel
    Aug 5, 2018 at 13:44

1 Answer 1

3

It's not advised to use sudo against graphical applications, try to run it with gksu:

gksu netbeans

Or if the executable is not systemwide, cd to where it is located and:

gksu ./netbeans
3
  • what path should I navigate to run this command? (Ubuntu is running on x86 PC). There's the path: ~/.netbeans/8.0/bin/nativeexecution/Linux-x86 where I assume Netbeans should start. But nothing happens except of asking administrative password. Ubuntu asks for admin password and does nothing afterwards.
    – user312058
    Sep 28, 2014 at 10:17
  • 1
    I assumed the executable was under your home directory. I just checked and mine is in /usr/bin/netbeans so try "gksu /usr/bin/netbeans" If it doesn't work, locate that file with "locate netbeans". Sep 28, 2014 at 10:23
  • 1
    I ran gksu /usr/local/netbeans-8.0/bin/netbeans and it worked. Thank you.
    – user312058
    Sep 28, 2014 at 10:41