Netbeans 8.1 no Ubuntu 17.04

2

Eu tentei instalar o Netbeans clicando no link apt aqui: link

o pacote instalado é "netbeans"

ergo: sudo apt install netbeans

o programa executa a tela inicial por alguns segundos e depois trava.

Alguma dica?

t@tsu:~/src/edk2$ netbeans 
Jun 08, 2017 8:57:06 PM org.netbeans.ProxyURLStreamHandlerFactory register
SEVERE: No way to find original stream handler for jar protocol
java.lang.reflect.InaccessibleObjectException: Unable to make field transient java.net.URLStreamHandler java.net.URL.handler accessible: module java.base does not "opens java.net" to unnamed module @6d8a00e3
    at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:337)
    at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:281)
    at java.base/java.lang.reflect.Field.checkCanSetAccessible(Field.java:175)
    at java.base/java.lang.reflect.Field.setAccessible(Field.java:169)
    at org.netbeans.ProxyURLStreamHandlerFactory.register(Unknown Source)
    at org.netbeans.JarClassLoader.<clinit>(Unknown Source)
    at org.netbeans.MainImpl.execute(Unknown Source)
    at org.netbeans.MainImpl.main(Unknown Source)
    at org.netbeans.Main.main(Unknown Source)

Jun 08, 2017 8:57:06 PM org.openide.util.lookup.implspi.ActiveQueue reportError
WARNING: Cannot hack ReferenceQueue to fix bug #206621!
java.lang.reflect.InaccessibleObjectException: Unable to make field private java.lang.ref.ReferenceQueue$Lock java.lang.ref.ReferenceQueue.lock accessible: module java.base does not "opens java.lang.ref" to unnamed module @6d8a00e3
    at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:337)
    at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:281)
    at java.base/java.lang.reflect.Field.checkCanSetAccessible(Field.java:175)
    at java.base/java.lang.reflect.Field.setAccessible(Field.java:169)
    at org.openide.util.lookup.implspi.ActiveQueue$Impl.<clinit>(Unknown Source)
    at org.openide.util.lookup.implspi.ActiveQueue.queue(Unknown Source)
    at org.openide.util.lookup.AbstractLookup.activeQueue(Unknown Source)
    at org.openide.util.lookup.AbstractLookup.access0(Unknown Source)
    at org.openide.util.lookup.AbstractLookup$ReferenceToResult.<init>(Unknown Source)
    at org.openide.util.lookup.AbstractLookup$ReferenceToResult.<init>(Unknown Source)
    at org.openide.util.lookup.AbstractLookup.lookup(Unknown Source)
    at org.openide.util.Lookup.lookupResult(Unknown Source)
    at org.openide.util.Lookup.lookupAll(Unknown Source)
    at org.netbeans.MainImpl$BootClassLoader.allCLIs(Unknown Source)
    at org.netbeans.CLIHandler.initialize(Unknown Source)
    at org.netbeans.MainImpl.execute(Unknown Source)
    at org.netbeans.MainImpl.main(Unknown Source)
    at org.netbeans.Main.main(Unknown Source)

Jun 08, 2017 8:57:06 PM org.openide.util.lookup.implspi.ActiveQueue reportError
WARNING: Cannot hack ReferenceQueue to fix bug #206621!
java.lang.IllegalAccessException: class org.openide.util.lookup.implspi.ActiveQueue$Impl cannot access a member of class java.lang.ref.ReferenceQueue (in module java.base) with modifiers "private"
    at java.base/jdk.internal.reflect.Reflection.newIllegalAccessException(Reflection.java:361)
    at java.base/java.lang.reflect.AccessibleObject.checkAccess(AccessibleObject.java:589)
    at java.base/java.lang.reflect.Field.checkAccess(Field.java:1074)
    at java.base/java.lang.reflect.Field.get(Field.java:415)
    at org.openide.util.lookup.implspi.ActiveQueue$Impl.<init>(Unknown Source)
    at org.openide.util.lookup.implspi.ActiveQueue.queue(Unknown Source)
    at org.openide.util.lookup.AbstractLookup.activeQueue(Unknown Source)
    at org.openide.util.lookup.AbstractLookup.access0(Unknown Source)
    at org.openide.util.lookup.AbstractLookup$ReferenceToResult.<init>(Unknown Source)
    at org.openide.util.lookup.AbstractLookup$ReferenceToResult.<init>(Unknown Source)
    at org.openide.util.lookup.AbstractLookup.lookup(Unknown Source)
    at org.openide.util.Lookup.lookupResult(Unknown Source)
    at org.openide.util.Lookup.lookupAll(Unknown Source)
    at org.netbeans.MainImpl$BootClassLoader.allCLIs(Unknown Source)
    at org.netbeans.CLIHandler.initialize(Unknown Source)
    at org.netbeans.MainImpl.execute(Unknown Source)
    at org.netbeans.MainImpl.main(Unknown Source)
    at org.netbeans.Main.main(Unknown Source)

t@tsu:~/src/edk2$ 
    
por tatsu 08.06.2017 / 20:58

2 respostas

3

O tutorial que você seguiu para instalar o NetBeans 8.1 é obsoleto. As versões atuais do NetBeans requerem o openjdk-8-jdk, não o openjdk-6-jdk ou o openjdk-7-jdk, como recomendado no tutorial. Desinstale o openjdk-6-jdk e o openjdk-7-jdk se você não precisar deles, e instale o openjdk-8-jdk usando o seguinte comando:

sudo apt install openjdk-8-jdk

Esperamos que a instalação do openjdk-6-jdk / openjdk-7-jdk não atrapalhe permanentemente o seu caminho Java e você possa começar a usar o NetBeans imediatamente. Se você tiver problemas com o NetBeans não reconhecendo o caminho Java depois de instalar o openjdk-8-jdk, comente e eu iremos adicionar informações sobre como corrigir isso.

    
por karel 09.06.2017 / 01:46
-1

Experimente outros IDE que são nativos do Linux World, como o Geany, em vez de NetBeans.

veja este link para instalar open-jdk . Como compilar um arquivo .java no Ubuntu?

depois disso, você pode usar o Gedit para codificar e o comando javac no terminal como compilador java.

    
por EsmaeelE 09.06.2017 / 01:31