Let's look at what is happening: Minecraft is trying to do something which returns 0xc0000005
.
In ntstatus.h
, a list of error code definitions, 0xc0000005
is STATUS_ACCESS_VIOLATION
.
MSDN - Analyze Crashes to Find Security Vulnerabilities in Your Apps reports:
Access violation exceptions (STATUS_ACCESS_VIOLATION) are generated by modern processors when a memory access caused by an instruction or program execution does not satisfy certain conditions defined by the processor architecture or memory management unit structures.
So, we now know that Minecraft does something that causes invalid memory access.
But, what exactly is Minecraft doing?
j org.lwjgl.opengl.WindowsContextImplementation.nCreate(Ljava/nio/ByteBuffer;Ljava/nio/IntBuffer;Ljava/nio/ByteBuffer;)Ljava/nio/ByteBuffer;+0
j org.lwjgl.opengl.WindowsContextImplementation.create(Lorg/lwjgl/opengl/PeerInfo;Ljava/nio/IntBuffer;Ljava/nio/ByteBuffer;)Ljava/nio/ByteBuffer;+10
j org.lwjgl.opengl.Context.<init>(Lorg/lwjgl/opengl/PeerInfo;Lorg/lwjgl/opengl/ContextAttribs;Lorg/lwjgl/opengl/Context;)V+104
j org.lwjgl.opengl.Display.create(Lorg/lwjgl/opengl/PixelFormat;Lorg/lwjgl/opengl/Drawable;Lorg/lwjgl/opengl/ContextAttribs;)V+88
Here we see, Minecraft tries to allocate an OpenGL Device Context buffer in memory.
The thread mentioned by Ben Blank has a different stack trace and thus is irrelevant.
We first have to get more knowledge about your memory, which you gave:
I noticed that the command that the minecraft.jar file is being run with says that it can have up to 1024mb of ram. I only have ~500mb of ram, so it would be referencing pointers in an unknown location. I also notice a gl issue, which I'm not really sure how to fix.
Given that low amount of memory, I'm going to guess that your graphics card uses 128 MB shared memory which means that it uses RAM memory to operate. I'm guessing that your Windows uses another 100 MB. There is only 250 MB of memory remaining for Minecraft, and your page file.
Minecraft uses from 512 MB to 1 GB, consider that playing Minecraft will cause disk trashing.
VM Arguments:
jvm_args: -Xms512m -Xmx1024m
So, now, where does the problem lie?
"so it would be referencing pointers in an unknown location" -- no. Just because you tell it it's allowed to use 1024 MB doesn't mean it ignores allocation errors when it runs out of space and creates invalid addresses out of thin air to reference. For all I know it wouldn't even matter, Windows would just give it space in the page file. - Matthew Read
This comment on the question is not 100% correct, there are exceptions that don't use the page file.
Exactly, OpenGL Device Context buffers must be in RAM; the solution is to buy more RAM.
I doubt if 1 GB will do the job given that Minecraft can use up to 1 GB; better to be safe than sorry and get 2 GB to avoid future problems. This also makes sure you don't experience disk trashing to the page file, which can have a great impact on the performance...
Or well, I could be all wrong and it could be a driver problem. But seriously, 512 MB isn't enough...
Best Answer
When trying to run Minecraft on OS X systems, the launcher tries to use Java 6 for Mac by default. This is because Apple used to ship their own version of Java (SE 6) with the operating system (mainly for security reasons). In recent versions of OS X, however, Java is no longer included, hence the error message you're seeing.
There are two ways to solve this issue.
Option 1 - Install Java 6
You could give the launcher what it wants and install the legacy Apple Java SE 6 runtime. Installing Apple Java 6 will allow the launcher to open; however, your Minecraft instances will also run on Java 6, since that is what the game looks for by default unless you override the executable (more on that under Option 2, Step 4 below).
The issue with this option is that you have to introduce old technology to make things work. Having everything run on the latest and greatest Java 8 patch would make everything a whole lot cleaner and easier, which brings us to...
Option 2 - Just use Java 8, already! (recommended)
As you've discovered, installing Java 8 alone won't do you any good. The launcher stalls because it can't find the Java runtime it needs. So, to get around this, you'll need to manually call the launcher using command line. This solution is a bit technical, but I'll try to walk you through it.
Step 1
Install the Java 8 JDK. On Oracle's Java SE Downloads page, in the Java Platform, Standard Edition box, click Download by "JDK".
On the next page, in the first list of downloads, check "Accept License Agreement" and click on the download link for "Mac OS X x64".
Save the file, open it, and run the installer package once the disk image pops up.
Step 2
Make sure you can run Java via command line. Open up Terminal (Applications > Utilities > Terminal.app), type
java -version
and hit Enter. The command should return something intelligible like this:If you get something like
No Java runtime present, requesting install
, you may have installed the JRE (you need the JDK).Step 3
Now that you have the Java 8 CLI, you can execute the Minecraft launcher
jar
. Back in Terminal, run the following:Note: This assumes you have the
Minecraft.app
file in your Applications folder. Make sure the path is correct.If all went well, you should now see your launcher. Hooray!
Step 4
Make sure that all your profiles point to a Java 1.8 JDK binary under the Executable option. It should look something like this:
You should now be able to launch the game.
Step 5
At this point, you can play Minecraft using Java 8. However, opening up Terminal and running a command every time you want to play is a bit tedious. To get around that, you can create your own application that will do it for you.
Method 1
Create an Automator workflow. Open Automator (Applications > Automator.app), and choose the "Application" workflow (Screenshot).
In the Library panel on the left, search for "shell" and double-click Run Shell Script (Screenshot). In the newly created modal field, add the command we used to execute the Minecraft launcher back in Step 3, along with an interpreter directive, like so:
Next, click Run in the top right of the window as a test. The Minecraft launcher should open up. Quit it, go back to Automator, and save the project into Applications as
Minecraft Launcher.app
. You can now quit Automator.Method 2 (recommended)
Create an app package. In a plain Text Editor document, add the command we used to execute the Minecraft launcher back in Step 3, along with an interpreter directive, like so:
Next, save the file as
launcher.sh
to your Desktop folder. Back in Terminal, run the following commands in order:Credit: Based on a terrific little script by Thomas Alyott and modified by Mathias Bynens.
Note: This assumes you saved the
launcher.sh
file to your Desktop folder. Make sure the path is correct.If all the commands succeeded, they will have created a
Minecraft Launcher.app
in Applications.Step 6
With all that done, you should now have a working launcher app that will let you play Minecraft using Java 8. There's just one more thing you can do to make it even better.
Minecraft.app
and select "Get Info".Minecraft Launcher.app
and again select "Get Info".Awesome. Now it'll look great in your Dock!
Hopefully I've covered everything in enough detail. If you have any questions, leave a comment and I'll try my best to help.
Happy Minecrafting!