Error: Could not create the Java virtual machine

To report bugs in the router software

Error: Could not create the Java virtual machine

Postby mrainess » Sun Jul 25, 2010 4:23 am

Hello,

I'm using Firefox 3.6.8 on Windows XP SP3 with Java 6 Update 21.
I have tested that Java works and that JNLP works by going to Sun's test pages.
When I click on http://www.freerouting.net/java/freeroute.jnlp the Java Web Start launcher starts.
Then I get the error dialog box shown below.

---------------------------
Java Virtual Machine Launcher
---------------------------
Could not create the Java virtual machine.
---------------------------
OK
---------------------------

How do I fix this

Mark
mrainess
 
Posts: 1
Joined: Sun Jul 25, 2010 4:07 am

Re: Error: Could not create the Java virtual machine

Postby alfons » Sun Jul 25, 2010 6:31 am

On my computer the router application runs without problems when I click your link above.
I have also installed Java Update 21 but on Windows Vista.
Does the problem also exists, if you start the router directly via the link on the FreeRouting website or if you try any of the old versions of the router?
The router application requires at least 1024 MB of virtual memory, but that should be available nowadays on any machine.
Otherwise I cannot see any reason, why the test examples of Sun work, but the FreeRouting application does not.
Have you tried, if the problem also exists on a different machine?
alfons
Site Admin
 
Posts: 188
Joined: Sun Nov 30, 2008 10:30 am
Location: Munich, Germany

Re: Error: Could not create the Java virtual machine

Postby obparham » Mon Jul 26, 2010 2:02 pm

Hi Alfons,

After reading your post this morning, I gave it a try and I'm seeing an error too. It seems to think my browser, Firefox 3.6.8, is running offline even though "Work Offline" is unchecked.

Here's the details:

Download.gif
Download.gif (5.91 KiB) Viewed 6762 times


Error.gif
Error.gif (5.77 KiB) Viewed 6750 times


Details.gif
Details.gif (9.85 KiB) Viewed 6747 times


Full text from Launch File tab:
Code: Select all
<?xml version="1.0" encoding="utf-8"?>
<!-- JNLP File for Freeroute -->

<jnlp
   spec="6.0+"
   codebase="http://freerouting.net/java"
   href="freeroute.jnlp">
   <information>
      <title>Routing Application</title>
      <vendor>FreeRouting</vendor>
      <description>Printed Circuit Board Routing Application</description>
      <homepage href="http://www.freerouting.net"/>
      <shortcut online="true"/>
   </information>
   <resources>     
      <jar download="eager" href="router.jar"/>   
      <extension href="help.jnlp" name="Java Help"/>
   <java version="1.6+" java-vm-args="-Xmx1024m"/>
   </resources>
   <application-desc main-class="gui.MainApplication">
      <argument>-webstart</argument>
   </application-desc>
</jnlp>


Full text from Exception tab:
Code: Select all
JNLPException[category: Download Error : Exception: null : LaunchDesc: null ]
   at com.sun.javaws.Launcher.prepareLaunchFile(Unknown Source)
   at com.sun.javaws.Launcher.prepareAllResources(Unknown Source)
   at com.sun.javaws.Launcher.prepareToLaunch(Unknown Source)
   at com.sun.javaws.Launcher.prepareToLaunch(Unknown Source)
   at com.sun.javaws.Launcher.launch(Unknown Source)
   at com.sun.javaws.Main.launchApp(Unknown Source)
   at com.sun.javaws.Main.continueInSecureThread(Unknown Source)
   at com.sun.javaws.Main$1.run(Unknown Source)
   at java.lang.Thread.run(Unknown Source)


Also, I get the same results with Work Offline checked and unchecked. Don't know what else to try.

Bruce
obparham
 
Posts: 19
Joined: Mon Dec 01, 2008 10:56 am
Location: Los Angeles, CA

Re: Error: Could not create the Java virtual machine

Postby alfons » Mon Jul 26, 2010 5:13 pm

Hi Bruce,

I allow my Router Application only to be be started when there exists a connection to the Internet.
In this way I get a statistics from my Internet provider, how often the router is started, and about the IP addresses of my users.
I do not collect any further information about the users and their board data via my router application.
If anybody does not trust this, he can switch off the Internet connection once the router is started.

I am also using Firefox 3.6.8 on Windows Vista and get a similar message when I try to start the router without an Internet connection.
But if I start the router via the link on my website (which is the only way, which I intended to support completely), there exists no problem.
alfons
Site Admin
 
Posts: 188
Joined: Sun Nov 30, 2008 10:30 am
Location: Munich, Germany

Re: Error: Could not create the Java virtual machine

Postby obparham » Tue Jul 27, 2010 2:08 pm

Hi Alfons,

I did a little more experimenting. If I use the link in FreePCB to start the router, a (Java?) message pops up saying something about being offline with an option button to go online. Once that online option is used, the router starts normally and, from that point on, I can start the router from the browser again. When the router would not start yesterday in Firefox, there was no "go online" pop-up.

So I guess the question is whose "online" status is being tested and how do I control it. I looked through the Java Console options and didn't find anything. Any ideas?

Bruce
obparham
 
Posts: 19
Joined: Mon Dec 01, 2008 10:56 am
Location: Los Angeles, CA

Re: Error: Could not create the Java virtual machine

Postby alfons » Tue Jul 27, 2010 5:33 pm

Hi Bruce

Originally I intended to support my router application only, when it is started via the link on the FreeRouting website.
In this case the user must be automatically on-line, because otherwise he would not be able visit my website.
Are there any problems, if you try to start my router that way?
If the user wants to start the router via the downloaded JNLP-file, he has to check himself, that he is connected to the Internet.
Also he has to assure himself, that his downloaded JNLP-file is not outdated and eventually replace it by the newest version.
alfons
Site Admin
 
Posts: 188
Joined: Sun Nov 30, 2008 10:30 am
Location: Munich, Germany

Re: Error: Could not create the Java virtual machine

Postby charlie » Sat Aug 21, 2010 2:23 pm

I got the same error when running the freeroute.jnlp from the site. I ran on Linux, it was ok. However I got the same error as stated when ran on Windows XP. The problem is that the max heap size -Xmx1024m is too big for the application to be run on the platform. Retarded windows... I tried different ways to fix it, here are the methods I used:

1) Save a copy of freeroute.jnlp and change the Xmx1024m value to Xmx768m. And then run this copy of freeroute.jnlp.

OR

2) Use your Window Explorer, from Tool -> Folder Option -> File Type, look for JNLP, click on it and then used Advanced settings below, edit the "Launch" value from

"C:\Program Files\Java\jre6\bin\javaws.exe" "%1"
to
"C:\Program Files\Java\jre6\bin\javaws.exe" -Xnosplash -J-Xmx768m "%1"

Note that -Xnosplash added because I got "Splash: recv failed". No idea why happened... I guess windows hates Java running on it.

Hopefully this would fix the problem.
charlie
 
Posts: 1
Joined: Sat Aug 21, 2010 1:43 pm

Re: Error: Could not create the Java virtual machine

Postby obparham » Sun Aug 22, 2010 4:11 pm

Hi Alfons,

This appears to be a Java issue (bug?). It happened to me again, this morning, after a reboot. I got the same "off-line" error message although Firefox, after visiting a number of other sites, was clearly on-line. And, again, starting from within FreePCB fixed the problem.

Since you are the most knowledgeable Java expert I know of, how do I tell Java I'm "on-line" since it's clearly not tracking browser or system network status?

Thanks.

Bruce
obparham
 
Posts: 19
Joined: Mon Dec 01, 2008 10:56 am
Location: Los Angeles, CA

Re: Error: Could not create the Java virtual machine

Postby alfons » Mon Aug 23, 2010 5:55 am

Hi Bruce,

I have removed the line

<shortcut online="true"/>

from the file freeroute.jnlp.
I am not a Java expert, but maybe this is worth a try.
alfons
Site Admin
 
Posts: 188
Joined: Sun Nov 30, 2008 10:30 am
Location: Munich, Germany

Re: Error: Could not create the Java virtual machine

Postby obparham » Wed Aug 25, 2010 1:52 pm

Hi Alfons,

Well, it did something.

On the first try, I still get the same "not online" message but a second try pops up a different not online message with a go online option button. If I use the button, from then on, it work fine.

Bruce
obparham
 
Posts: 19
Joined: Mon Dec 01, 2008 10:56 am
Location: Los Angeles, CA

Next

Return to Bug Report

Who is online

Users browsing this forum: No registered users and 1 guest

cron