Skip to content
This repository has been archived by the owner on Jun 28, 2019. It is now read-only.

Unable to launch #7

Open
gfelot opened this issue Mar 24, 2015 · 16 comments
Open

Unable to launch #7

gfelot opened this issue Mar 24, 2015 · 16 comments

Comments

@gfelot
Copy link

gfelot commented Mar 24, 2015

Hi Paolo Rotolo,

I'm on a fresh install of Ubuntu 15.04. I installed via your repo Android Studio but the program doesn't appear anywhere. Even via a terminal my PC didn't found the bin or something related to.

Thanks.

@paolorotolo
Copy link
Owner

Hi,
thanks for your report.

Please, open a terminal and paste this command:
/opt/android-studio/bin/studio.sh

Can you tell me if it works :)?

@chemouna
Copy link

I had the same problem on ubuntu 14 , with /opt/android-studio/bin/studio.sh it launched it ... thank you

@paolorotolo
Copy link
Owner

Are you using Unity or GNOME? Also Ubuntu i386 or amd64?

@chemouna
Copy link

Unity and amd64

@milesimarco
Copy link

Same problem here: no app appearing in the dash. Ubuntu 15.04 Unity 64 bit

With /opt/android-studio/bin/studio.sh the software is launched.

@paolorotolo
Copy link
Owner

Could you paste here what's in android-studio.desktop file in /usr/share/applications please?

nano /usr/share/applications/android-studio.desktop

@maelsan
Copy link

maelsan commented May 14, 2015

Me too (Ubuntu 15.04 Unity & 64 Bits).
Here's the content of .desktop file ->

[Desktop Entry]
Version=1.0
Type=Application
Terminal=false
Name=Android Studio
Exec=/opt/android-studio/bin/studio.sh
Comment=Integrated Android developer tools for development and debugging.
Icon=androidstudio
Categories=GNOME;GTK;Development;IDE;

@mrzulkarnine
Copy link

I got this error:

Start Failed: Internal error. Please report to https://code.google.com/p/android/issues

java.lang.NoClassDefFoundError: com.intellij.util.lang.ClassPath
at java.lang.Class.initializeClass(libgcj.so.14)
at com.intellij.util.lang.UrlClassLoader.createClassPath(UrlClassLoader.java:179)
at com.intellij.util.lang.UrlClassLoader.(UrlClassLoader.java:173)
at com.intellij.util.lang.UrlClassLoader$Builder.get(UrlClassLoader.java:128)
at com.intellij.ide.BootstrapClassLoaderUtil.initClassLoader(BootstrapClassLoaderUtil.java:68)
at com.intellij.ide.Bootstrap.main(Bootstrap.java:32)
at com.intellij.idea.Main.main(Main.java:83)
Caused by: java.lang.ClassNotFoundException: sun.misc.Resource not found in gnu.gcj.runtime.SystemClassLoader{urls=[file:/opt/android-studio/bin/../lib/bootstrap.jar,file:/opt/android-studio/bin/../lib/extensions.jar,file:/opt/android-studio/bin/../lib/util.jar,file:/opt/android-studio/bin/../lib/jdom.jar,file:/opt/android-studio/bin/../lib/log4j.jar,file:/opt/android-studio/bin/../lib/trove4j.jar,file:/opt/android-studio/bin/../lib/jna.jar], parent=gnu.gcj.runtime.ExtensionClassLoader{urls=[], parent=null}}
at java.net.URLClassLoader.findClass(libgcj.so.14)
at java.lang.ClassLoader.loadClass(libgcj.so.14)
at java.lang.ClassLoader.loadClass(libgcj.so.14)
at java.lang.Class.forName(libgcj.so.14)
at java.lang.Class.initializeClass(libgcj.so.14)
...6 more

Also, an UI exception occurred on attempt to show above message:
java.lang.ExceptionInInitializerError
at java.lang.Class.initializeClass(libgcj.so.14)
at com.intellij.util.containers.ConcurrentIntObjectHashMap.getUnsafe(ConcurrentIntObjectHashMap.java:2787)
at com.intellij.util.containers.ConcurrentIntObjectHashMap.(ConcurrentIntObjectHashMap.java:2752)
at java.lang.Class.initializeClass(libgcj.so.14)
at com.intellij.util.containers.ContainerUtil.createConcurrentIntObjectMap(ContainerUtil.java:2334)
at com.intellij.util.containers.ConcurrentRefValueIntObjectHashMap.(ConcurrentRefValueIntObjectHashMap.java:31)
at com.intellij.util.containers.ConcurrentWeakValueIntObjectHashMap.(ConcurrentWeakValueIntObjectHashMap.java:31)
at com.intellij.util.containers.ContainerUtil.createConcurrentIntObjectWeakValueMap(ContainerUtil.java:2362)
at com.intellij.openapi.util.Key.(Key.java:38)
at java.lang.Class.initializeClass(libgcj.so.14)
at com.intellij.util.ui.UIUtil.(UIUtil.java:202)
at java.lang.Class.initializeClass(libgcj.so.14)
at com.intellij.idea.Main.showMessage(Main.java:234)
at com.intellij.idea.Main.showMessage(Main.java:217)
at com.intellij.idea.Main.main(Main.java:86)
Caused by: java.lang.RuntimeException: Could not find 'theUnsafe' field in the class sun.misc.Unsafe
at com.intellij.util.concurrency.AtomicFieldUpdater.getUnsafe(AtomicFieldUpdater.java:44)
at com.intellij.util.concurrency.AtomicFieldUpdater.(AtomicFieldUpdater.java:38)
at java.lang.Class.initializeClass(libgcj.so.14)

Please assist.

@mrzulkarnine
Copy link

Nevermind, I fixed it by installing jdk 7

@loide
Copy link

loide commented Aug 28, 2015

I solved this using 'sudo desktop-file-install android-studio.desktop' on /usr/share/applications

@bibz
Copy link

bibz commented Aug 30, 2015

I experimented this issue on Linux Mint 17.1.
@loide's solution works like a charm, thanks!

@paolorotolo
Copy link
Owner

Awesome guys, I'm going to add the tip in FAQ. 👍

@Rafnuss
Copy link

Rafnuss commented Nov 23, 2015

Same problem appear after installing jdk 8 after android studio. @loide 's solution worked for me ! @paolorotolo , I can't see the trick on the FAQ, did you just forgot to update it or am I just missing the info somewhere ?

@FranklinYu
Copy link

@loide's suggestion

sudo desktop-file-install /usr/share/applications/android-studio.desktop

works on Ubuntu 14.04 LTS. Thanks a log!

@ghost
Copy link

ghost commented Mar 16, 2016

@loide 's solution works on LinuxMint17.3 x64 cinema

@codingyourlife
Copy link

I had the same problem and on my second attempt on a new machine I found this to be prequisits:
#Install Java8
sudo apt-add-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install oracle-java8-installer

#configure Java8 (in my case I had to select 1)
sudo update-alternatives --config java

#this stuff is required to avoid mksdcard error on first run of the studio
sudo apt-get install lib32z1 lib32ncurses5 lib32stdc++6

#press ctrl+w and search for "MaxPermSize" and remove the line
sudo nano /opt/android-studio/bin/studio64.vmoptions
sudo nano /opt/android-studio/bin/studio.vmoptions

Then install AS and reboot. Everything should work then.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests