Skip to content

Nvidia driver 378.49 breaks Processing sketches (Target VM failed to initialize) #4853

Closed

Description

@briankngo
  1. Processing version 3.2.3
  2. PC operating system and hardware
    Windows 10 64-bit
    Intel i7-4790k processor
    H97 GAMING 3 Motherboard
    NVIDIA GeForce GTX 970 graphics card
    16.0 GB ddr3
  3. Here's a copy of the smallest possible piece of code that will produce the error
    error details: [https://cdn.discordapp.com/attachments/271440764402139138/273695422998904842/error.JPG ]
    alt. “Could not run the sketch (Target VM failed to initialize). For more information, read revisions.txt and Help ? Troubleshooting.”
  4. Processing used to work but now it just says, "Could not run the sketch (Target VM failed to initialize). For more information, read revisions.txt and Help ? Troubleshooting." Processing just stopped working and I don't know how to fix it. An error started to pop up every time i try to run something. A reinstall did not fix the problem, I tried deleting preferences, and finding the solution in the forums.

Activity

  1. dwhit commented on Jan 25, 2017

    @dwhit

    Yeah same bug for me. I've used processing on a mac before, just tried installing on my windows machine after updating nvidia driver this afternoon, and all I get is the same could not run sketch error, even on a blank sketch. Super relieving to know someone else has the same bug.

  2. aarondbaron commented on Jan 25, 2017

    @aarondbaron

    This happened to me as well. same graphics card. i rolled back the driver and processing was back to normal and working.

  3. qckpea commented on Jan 25, 2017

    @qckpea

    Same issue here, after totally wiping out NVIDIA drivers it works properly.

    Win 10 64bit
    GTX 970 8GB
    i5 4590
    H97 PC-MATE(MS-7850)

    Processing 3.2.3 but this issue is present with earlier versions as well.

  4. esponapule commented on Jan 26, 2017

    @esponapule

    Same here. Will not run and all the fonts are corrupt after Nvidia driver update. Both x86 and x64 versions of processing

    Windows 10 x64
    GTX 1050t
    GeForce Driver 378.49 released 01/23/2017

    Could not run the sketch (Target VM failed to initialize).
    Make sure that you haven't set the maximum available memory too high.
    For more information, read revisions.txt and Help ? Troubleshooting.
    

    (https://cloud.githubusercontent.com/assets/3163504/22315489/9d0163e2-e32c-11e6-8da5-9408d256c54d.png)

  5. ricsinaruto commented on Jan 26, 2017

    @ricsinaruto

    Same issue here with gtx 970 card.
    Processing stopped working after installing the 378.49 driver, had to downgrade to the previously released 376.33 driver

  6. MoritzBrueckner commented on Jan 28, 2017

    @MoritzBrueckner

    Same here.

    Windows 8.1 x64
    GTX 750ti
    Driver 378.49

    Installing previous driver version solves the problem

  7. caicofer commented on Jan 28, 2017

    @caicofer

    Yeah, the driver is definetely the problem. I was having the exact same issue and everything went back to normal after I donwgraded the driver.

  8. JakubValtar commented on Jan 28, 2017

    @JakubValtar
    Contributor

    It's a bug in Nvidia driver. Lots of games running on Java (like Minecraft) have problems as well. For now, please use older driver until Nvidia releases fixed driver.

  9. changed the title [-] Processing cannot run after NVidia drivers update?[/-] [+]Nvidia driver 378.49 breaks Processing sketches (Target VM failed to initialize)[/+] on Jan 28, 2017
  10. benfry commented on Jan 30, 2017

    @benfry
    Contributor

    Reddit thread from Minecraft fans with discussion about problem/solutions: https://www.reddit.com/r/Minecraft/comments/5q05wu/psa_latest_nvidia_gpu_driver_crashes_minecraft/

  11. benfry commented on Jan 30, 2017

    @benfry
    Contributor

    Anyone know of a means to get the driver version (i.e. from command line, a file, etc)? This is gonna be a bumpy couple of days/weeks for anyone who gets stuck on this driver, so we may want to warn people from the PDE.

  12. JakubValtar commented on Jan 30, 2017

    @JakubValtar
    Contributor

    @benfry This sketch works on my pc and my test PC with clean Win10 install, sorry I can't test more today.

    You should also handle exceptions better

    import java.util.Scanner;
    
    try {
      Process p = Runtime.getRuntime().exec("powershell Get-WmiObject Win32_PnPSignedDriver| select devicename, driverversion | where {$_.devicename -like \\\"*nvidia*\\\"}");
      InputStream is = p.getInputStream();
      Scanner s = new Scanner(is).useDelimiter("\\A");
      String result = s.hasNext() ? s.next() : "";
      s.close();
      boolean hasBuggyDriver = result.contains("3.7849");
      println("buggy driver found:", hasBuggyDriver);
    } catch (IOException e) {
      
    }

    PowerShell returns this, last five numbers give version: 3.6909 -> 369.09

    
    devicename                                          driverversion
    ----------                                          -------------
    NVIDIA Virtual Audio Device (Wave Extensible) (WDM) 1.2.31.0
    NVIDIA GeForce GTX 760M                             21.21.13.6909
    
    
    
  13. benfry commented on Jan 30, 2017

    @benfry
    Contributor

    That's what I'm looking for; thanks.

  14. algotrash commented on Feb 2, 2017

    @algotrash

    Removing 3D vision drivers worked well for me, thank you benfry for the link.

  15. 11 remaining items

  16. leadedge commented on Feb 27, 2017

    @leadedge

    This could be resolved by NVIDIA driver 378.66. Works for me with a quick test.

  17. JakubValtar commented on Feb 27, 2017

    @JakubValtar
    Contributor

    @benfry works for me: image

    The problem could be that some manufacturers may not include NVIDIA in the device name.

  18. JakubValtar commented on Feb 27, 2017

    @JakubValtar
    Contributor

    @leadedge could you please copy paste this code into Processing editor, run it and post here what the console shows? It should list your graphics cards with their driver versions.

    import java.util.Scanner;
    
    try {
      Process p = Runtime.getRuntime().exec("powershell Get-WmiObject Win32_PnPSignedDriver| select devicename, driverversion | where {$_.devicename -like \\\"*nvidia*\\\"}");
      InputStream is = p.getInputStream();
      Scanner s = new Scanner(is).useDelimiter("\\A");
      String result = s.hasNext() ? s.next() : "";
      s.close();
      boolean hasBuggyDriver = result.contains("3.7849");
      println("buggy driver found:", hasBuggyDriver);
      println(result);
    } catch (IOException e) {
      e.printStackTrace();
    }
  19. leadedge commented on Feb 28, 2017

    @leadedge

    The sketch stops at - Scanner s = new Scanner(is).useDelimiter("\A");

    If I change it to - Scanner s = new Scanner(is); - I can print 21 lines -

    devicename
    driverversion
    (two lines of dashes removed due to style problems)
    NVIDIA
    Virtual
    Audio
    Device
    (Wave
    Ex...
    3.40.1.0
    NVIDIA
    High
    Definition
    Audio
    1.3.34.21
    NVIDIA
    GeForce
    GT
    640
    21.21.13.7866

  20. leadedge commented on Mar 2, 2017

    @leadedge

    I realise that the post above might not be all that useful. From this, it seems to me that the code in the processing core might not be working in my environment. I don't know why but, similar to above, the sketch stops with -

    String[] lines = loadStrings(createReader(p.getInputStream()));

    Here is what I have been able to get to work - clearly the driver number would be changed to 3.7849.

    try {  
      Process p = Runtime.getRuntime().exec("powershell Get-WmiObject Win32_PnPSignedDriver| select devicename, driverversion | where {$_.devicename -like \\\"*nvidia*\\\"}");
      BufferedReader reader = createReader(p.getInputStream());
      String line;
      do { 
        line = reader.readLine();
        println(line);
        if (line.contains("3.786")) {
          println("driver found:");
        }    
      } while(!line.equals(null));
      println("done");
    } catch (Exception e) {
       println("Problem checking NVIDIA driver", e);
    }
    
  21. added a commit that references this issue on Apr 22, 2017
  22. benfry commented on Apr 22, 2017

    @benfry
    Contributor

    I've just checked in a new version of the code that works more like this—can you try it? It's not functionally any different from using loadStrings() but maybe I'm missing something.

  23. leadedge commented on Apr 23, 2017

    @leadedge

    I don't know what the problem is with loadStrings, but I checked again and it stops the sketch.

    I think the current code is OK on my system. Here is what works ( I still have not updated the driver) -

    import java.util.Scanner;
    import java.util.regex.Pattern;
    
     try { 
      Process p = Runtime.getRuntime().exec("powershell Get-WmiObject Win32_PnPSignedDriver| select devicename, driverversion | where {$_.devicename -like \\\"*nvidia*\\\"}");
      BufferedReader reader = createReader(p.getInputStream());
      String line = null;
      while ((line = reader.readLine()) != null) {
        println(line);
        if (line.contains("3.7849")) {
          println("buggy driver found 1");
        } 
        else if (line.contains("3.8165")) {
          println("buggy driver found 2");
        }
        else if (line.contains("3.7866")) {
          println("My driver found OK");
        }
      }
    } catch (Exception e) {
       println("Problem checking NVIDIA driver", e);
    }
    
  24. leadedge commented on Apr 23, 2017

    @leadedge

    To check the latest problem, I installed 381.65 and it works OK on Windows 7. Must be specific to Windows 10 and maybe only laptops, because the hotfix is only for Windows 10 laptops. But I haven't tried Windows 8.

  25. benfry commented on Apr 23, 2017

    @benfry
    Contributor

    Ok, I've tweaked the check to only run on Windows 10. I think this is all we can do from our end.

    If someone has a bad driver on Windows 10 and the error message doesn't pop up, please let us know.

  26. charlesdedijon commented on Jun 17, 2017

    @charlesdedijon

    Hello,
    i try to update the driver but my card is NVIDIA GeForce 6600 GT (Windows 7 64bit with processing 3.3) so i can't use the new driver 378.57...
    The message "Could not run the sketch (Target VM failed to initialize)" arrive after 66minute of start programm. I don't understand.

    Please, help me.

  27. charlesdedijon commented on Jun 18, 2017

    @charlesdedijon

    NVIDIA GeForce 6600 GT 9.18.13.783
    Contr?leur de r?seau NVIDIA nForce 1.0.1.211
    Gestion de syst?me NVIDIA nForce PCI 6.1.7601.17514
    Pont HyperTransport NVIDIA nForce4 6.1.7601.17514

  28. github-actions commented on Jun 15, 2021

    @github-actions

    This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

  29. locked as resolved and limited conversation to collaborators on Jun 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions