Search code examples
androidwindowsandroid-studiowindows-11

Android Studio won't open on Windows 11


So I can't get Android Studio to open through the studio64.exe launcher.

It was working perfectly just a few days ago and now it won't launch. Tried uninstalling and installing the latest Bumblebee 2021.1 with no luck. Tried deleting the Android studio files in AppData but still no luck. Even tried reverting to an older restore point with no success.

I have already set JDK_HOME and JAVA_HOME to the included Android Studio jre. After doing this the app now launches by running studio.bat but the actual launcher still fails. It just shows up for a brief second in Task Manager then disappears. No error messages or anything, just blank.

The weird thing is that I also have Intellij IDEA but that launches perfectly fine through it's launcher. Just Android Studio that is giving me issues.

Any help will be appreciated!

Edit: Attaching the log from the IDE.

    2022-01-29 18:00:25,568 [      0]   INFO -        #com.intellij.idea.Main - ------------------------------------------------------ IDE STARTED ------------------------------------------------------ 
2022-01-29 18:00:25,623 [     55]   INFO -        #com.intellij.idea.Main - IDE: Android Studio (build #AI-211.7628.21.2111.8092744, 19 Jan 2022 08:56) 
2022-01-29 18:00:25,624 [     56]   INFO -        #com.intellij.idea.Main - OS: Windows 10 (10.0, amd64) 
2022-01-29 18:00:25,634 [     66]   INFO -        #com.intellij.idea.Main - JRE: 11.0.11+9-b60-7590822 (Oracle Corporation) 
2022-01-29 18:00:25,635 [     67]   INFO -        #com.intellij.idea.Main - JVM: 11.0.11+9-b60-7590822 (OpenJDK 64-Bit Server VM) 
2022-01-29 18:00:25,637 [     69]   INFO -        #com.intellij.idea.Main - JVM Args: exit -Xms256m -Xmx1280m -XX:ReservedCodeCacheSize=512m -XX:+UseG1GC -XX:SoftRefLRUPolicyMSPerMB=50 -XX:CICompilerCount=2 -Dsun.io.useCanonCaches=false -Djdk.http.auth.tunneling.disabledSchemes="" -Djdk.attach.allowAttachSelf=true -Djdk.module.illegalAccess.silent=true -Dkotlinx.coroutines.debug=off -Djna.nosys=true -Djna.boot.library.path= -Didea.vendor.name=Google -Djb.vmOptionsFile=C:\Program Files\Android\Android Studio\bin\studio64.exe.vmoptions -Djava.library.path=C:\Program Files\Android\Android Studio\jre\\bin;C:\Program Files\Android\Android Studio\jre\\bin\server -Didea.platform.prefix=AndroidStudio -Didea.jre.check=true -Dide.native.launcher=true -Didea.vendor.name=Google -Didea.paths.selector=AndroidStudio2021.1 -XX:ErrorFile=C:\Users\bmkil\java_error_in_studio64_%p.log -XX:HeapDumpPath=C:\Users\bmkil\java_error_in_studio64.hprof 
2022-01-29 18:00:25,638 [     70]   INFO -        #com.intellij.idea.Main - library path: C:\Program Files\Android\Android Studio\jre\\bin;C:\Program Files\Android\Android Studio\jre\\bin\server 
2022-01-29 18:00:25,638 [     70]   INFO -        #com.intellij.idea.Main - boot library path: C:\Program Files\Android\Android Studio\jre\bin 
2022-01-29 18:00:25,658 [     90]   INFO -        #com.intellij.idea.Main - locale=en_GB JNU=Cp1252 file.encoding=Cp1252
  idea.config.path=C:\Users\bmkil\AppData\Roaming\Google\AndroidStudio2021.1
  idea.system.path=C:\Users\bmkil\AppData\Local\Google\AndroidStudio2021.1
  idea.plugins.path=C:\Users\bmkil\AppData\Roaming\Google\AndroidStudio2021.1\plugins
  idea.log.path=C:\Users\bmkil\AppData\Local\Google\AndroidStudio2021.1\log 
2022-01-29 18:00:25,705 [    137]   INFO -        #com.intellij.idea.Main - JNA library (64-bit) loaded in 42 ms 
2022-01-29 18:00:25,730 [    162]   INFO - penapi.util.io.win32.IdeaWin32 - Native filesystem for Windows is operational 
2022-01-29 18:00:25,744 [    176]   INFO -                         STDERR -  
2022-01-29 18:00:25,745 [    177]   INFO -                         STDERR - Start Failed 
2022-01-29 18:00:25,745 [    177]   INFO -                         STDERR - Internal error. Please refer to https://code.google.com/p/android/issues 
2022-01-29 18:00:25,745 [    177]   INFO -                         STDERR -  
2022-01-29 18:00:25,745 [    177]   INFO -                         STDERR - com.intellij.ide.plugins.StartupAbortedException: UI initialization failed 
2022-01-29 18:00:25,745 [    177]   INFO -                         STDERR -     at com.intellij.idea.StartupUtil.lambda$prepareApp$3(StartupUtil.java:196) 
2022-01-29 18:00:25,745 [    177]   INFO -                         STDERR -     at java.base/java.util.concurrent.CompletableFuture.uniExceptionally(CompletableFuture.java:986) 
2022-01-29 18:00:25,745 [    177]   INFO -                         STDERR -     at java.base/java.util.concurrent.CompletableFuture$UniExceptionally.tryFire(CompletableFuture.java:970) 
2022-01-29 18:00:25,745 [    177]   INFO -                         STDERR -     at java.base/java.util.concurrent.CompletableFuture.postComplete(CompletableFuture.java:506) 
2022-01-29 18:00:25,745 [    177]   INFO -                         STDERR -     at java.base/java.util.concurrent.CompletableFuture.completeExceptionally(CompletableFuture.java:2088) 
2022-01-29 18:00:25,745 [    177]   INFO -                         STDERR -     at com.intellij.idea.StartupUtil.lambda$scheduleInitUi$9(StartupUtil.java:392) 
2022-01-29 18:00:25,745 [    177]   INFO -                         STDERR -     at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) 
2022-01-29 18:00:25,745 [    177]   INFO -                         STDERR -     at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) 
2022-01-29 18:00:25,745 [    177]   INFO -                         STDERR -     at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:668) 
2022-01-29 18:00:25,745 [    177]   INFO -                         STDERR -     at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:665) 
2022-01-29 18:00:25,746 [    178]   INFO -                         STDERR -     at java.base/java.security.AccessController.doPrivileged(Native Method) 
2022-01-29 18:00:25,746 [    178]   INFO -                         STDERR -     at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1.run(Executors.java:665) 
2022-01-29 18:00:25,746 [    178]   INFO -                         STDERR -     at java.base/java.lang.Thread.run(Thread.java:829) 
2022-01-29 18:00:25,746 [    178]   INFO -                         STDERR - Caused by: java.util.concurrent.CompletionException: java.lang.UnsatisfiedLinkError: C:\Program Files\Android\Android Studio\jre\bin\awt.dll: Can't find dependent libraries 
2022-01-29 18:00:25,746 [    178]   INFO -                         STDERR -     at java.base/java.util.concurrent.CompletableFuture.encodeThrowable(CompletableFuture.java:331) 
2022-01-29 18:00:25,746 [    178]   INFO -                         STDERR -     at java.base/java.util.concurrent.CompletableFuture.completeThrowable(CompletableFuture.java:346) 
2022-01-29 18:00:25,746 [    178]   INFO -                         STDERR -     at java.base/java.util.concurrent.CompletableFuture$BiRelay.tryFire(CompletableFuture.java:1423) 
2022-01-29 18:00:25,746 [    178]   INFO -                         STDERR -     ... 10 more 
2022-01-29 18:00:25,746 [    178]   INFO -                         STDERR - Caused by: java.lang.UnsatisfiedLinkError: C:\Program Files\Android\Android Studio\jre\bin\awt.dll: Can't find dependent libraries 
2022-01-29 18:00:25,746 [    178]   INFO -                         STDERR -     at java.base/java.lang.ClassLoader$NativeLibrary.load0(Native Method) 
2022-01-29 18:00:25,746 [    178]   INFO -                         STDERR -     at java.base/java.lang.ClassLoader$NativeLibrary.load(ClassLoader.java:2442) 
2022-01-29 18:00:25,746 [    178]   INFO -                         STDERR -     at java.base/java.lang.ClassLoader$NativeLibrary.loadLibrary(ClassLoader.java:2498) 
2022-01-29 18:00:25,746 [    178]   INFO -                         STDERR -     at java.base/java.lang.ClassLoader.loadLibrary0(ClassLoader.java:2694) 
2022-01-29 18:00:25,746 [    178]   INFO -                         STDERR -     at java.base/java.lang.ClassLoader.loadLibrary(ClassLoader.java:2648) 
2022-01-29 18:00:25,746 [    178]   INFO -                         STDERR -     at java.base/java.lang.Runtime.loadLibrary0(Runtime.java:830) 
2022-01-29 18:00:25,746 [    178]   INFO -                         STDERR -     at java.base/java.lang.System.loadLibrary(System.java:1873) 
2022-01-29 18:00:25,746 [    178]   INFO -                         STDERR -     at java.desktop/java.awt.Toolkit$3.run(Toolkit.java:1395) 
2022-01-29 18:00:25,746 [    178]   INFO -                         STDERR -     at java.desktop/java.awt.Toolkit$3.run(Toolkit.java:1393) 
2022-01-29 18:00:25,746 [    178]   INFO -                         STDERR -     at java.base/java.security.AccessController.doPrivileged(Native Method) 
2022-01-29 18:00:25,746 [    178]   INFO -                         STDERR -     at java.desktop/java.awt.Toolkit.loadLibraries(Toolkit.java:1392) 
2022-01-29 18:00:25,746 [    178]   INFO -                         STDERR -     at java.desktop/java.awt.Toolkit.<clinit>(Toolkit.java:1430) 
2022-01-29 18:00:25,747 [    179]   INFO -                         STDERR -     at java.desktop/java.awt.EventQueue.invokeLater(EventQueue.java:1318) 
2022-01-29 18:00:25,747 [    179]   INFO -                         STDERR -     at com.intellij.idea.StartupUtil.lambda$scheduleInitUi$9(StartupUtil.java:343) 
2022-01-29 18:00:25,747 [    179]   INFO -                         STDERR -     ... 7 more 
2022-01-29 18:00:25,747 [    179]   INFO -                         STDERR -  
2022-01-29 18:00:25,747 [    179]   INFO -                         STDERR - ----- 
2022-01-29 18:00:25,747 [    179]   INFO -                         STDERR - Your JRE: 11.0.11+9-b60-7590822 amd64 (Oracle Corporation) 
2022-01-29 18:00:25,747 [    179]   INFO -                         STDERR - C:\Program Files\Android\Android Studio\jre 
2022-01-29 18:00:25,759 [    191]   INFO -                         STDERR -  
2022-01-29 18:00:25,759 [    191]   INFO -                         STDERR - Also, a UI exception occurred on an attempt to show the above message 
2022-01-29 18:00:25,760 [    192]   INFO -                         STDERR - java.lang.NoClassDefFoundError: Could not initialize class java.awt.Toolkit 
2022-01-29 18:00:25,760 [    192]   INFO -                         STDERR -     at java.desktop/java.awt.Component.<clinit>(Component.java:626) 
2022-01-29 18:00:25,760 [    192]   INFO -                         STDERR -     at com.intellij.idea.Main.showMessage(Main.java:323) 
2022-01-29 18:00:25,760 [    192]   INFO -                         STDERR -     at com.intellij.idea.Main.showMessage(Main.java:278) 
2022-01-29 18:00:25,760 [    192]   INFO -                         STDERR -     at com.intellij.ide.plugins.StartupAbortedException.logAndExit(StartupAbortedException.java:87) 
2022-01-29 18:00:25,760 [    192]   INFO -                         STDERR -     at com.intellij.ide.plugins.StartupAbortedException.processException(StartupAbortedException.java:35) 
2022-01-29 18:00:25,760 [    192]   INFO -                         STDERR -     at com.intellij.idea.StartupUtil.lambda$prepareApp$3(StartupUtil.java:196) 
2022-01-29 18:00:25,760 [    192]   INFO -                         STDERR -     at java.base/java.util.concurrent.CompletableFuture.uniExceptionally(CompletableFuture.java:986) 
2022-01-29 18:00:25,761 [    193]   INFO -                         STDERR -     at java.base/java.util.concurrent.CompletableFuture$UniExceptionally.tryFire(CompletableFuture.java:970) 
2022-01-29 18:00:25,761 [    193]   INFO -                         STDERR -     at java.base/java.util.concurrent.CompletableFuture.postComplete(CompletableFuture.java:506) 
2022-01-29 18:00:25,761 [    193]   INFO -                         STDERR -     at java.base/java.util.concurrent.CompletableFuture.completeExceptionally(CompletableFuture.java:2088) 
2022-01-29 18:00:25,761 [    193]   INFO -                         STDERR -     at com.intellij.idea.StartupUtil.lambda$scheduleInitUi$9(StartupUtil.java:392) 
2022-01-29 18:00:25,761 [    193]   INFO -                         STDERR -     at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) 
2022-01-29 18:00:25,761 [    193]   INFO -                         STDERR -     at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) 
2022-01-29 18:00:25,761 [    193]   INFO -                         STDERR -     at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:668) 
2022-01-29 18:00:25,761 [    193]   INFO -                         STDERR -     at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:665) 
2022-01-29 18:00:25,761 [    193]   INFO -                         STDERR -     at java.base/java.security.AccessController.doPrivileged(Native Method) 
2022-01-29 18:00:25,762 [    194]   INFO -                         STDERR -     at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1.run(Executors.java:665) 
2022-01-29 18:00:25,762 [    194]   INFO -                         STDERR -     at java.base/java.lang.Thread.run(Thread.java:829) 
2022-01-29 18:00:25,763 [    195]   INFO -        #com.intellij.idea.Main - ------------------------------------------------------ IDE SHUTDOWN ------------------------------------------------------ 
2022-01-29 18:00:25,820 [    252]   INFO - org.jetbrains.io.BuiltInServer - web server stopped 

Solution

  • Ok, I have figured out the issue. There seems to be an issue with the include JRE version: 11.0.11+9-b60-7590822 (Oracle Corporation) which is causing issues with Java AWT used for the laucher UI. This issue seems to only happen when you have installed the Windows 11 KB5008353 Cumulative update to Build 22000.469. Or maybe the included JRE is broken.

    But the current fix I did was take the contents of C:\Program Files\JetBrains\IntelliJ IDEA Community Edition 2021.3.1\jbr which is JRE version: 11.0.13+7-b1751.21 (JetBrains s.r.o.) and place them in C:\Program Files\Android\Android Studio\jre (you should of course rename the old jre folder so you don't loose the original files).

    Doing this will allow you to launch the app through studio64.exe directly like before. Until this is fixed this is the only way to get it working again. You can star the issue I created on Google's issue tracker: https://issuetracker.google.com/issues/216891004