Skip to Content
avatar image
Former Member

java errors when spawning multiple instances of dbisql

I have a bash script that spawns multiple instances of dbisql on an AWS ec2 ami linux instance. The instance has 7.5GB of RAM and 4 vcpu's. When it runs with more than about 10-20 instances, the computer becomes almost completely unresponsive and I have received errors:

Error: Could not create the Java Virtual Machine.

Error: A fatal exception has occurred. Program will exit.

Error occurred during initialization of VM

Example error file here:

http://pastebin.com/y9W11nba

The script looks something like this:

#!/bin/bash
php -f /var/scripts/labor/scripts/labor.php /delay_start:"5" /store_list:"s1" &
php -f /var/scripts/labor/scripts/labor.php /delay_start:"5" /store_list:"s2" &
php -f /var/scripts/labor/scripts/labor.php /delay_start:"5" /store_list:"s3" &
php -f /var/scripts/labor/scripts/labor.php /delay_start:"5" /store_list:"s4" &
php -f /var/scripts/labor/scripts/labor.php /delay_start:"5" /store_list:"s5" &
php -f /var/scripts/labor/scripts/labor.php /delay_start:"5" /store_list:"s6" &
php -f /var/scripts/labor/scripts/labor.php /delay_start:"5" /store_list:"s7" &
php -f /var/scripts/labor/scripts/labor.php /delay_start:"5" /store_list:"s8" &
php -f /var/scripts/labor/scripts/labor.php /delay_start:"5" /store_list:"s9" &
php -f /var/scripts/labor/scripts/labor.php /delay_start:"5" /store_list:"s10"

This same script has been running on a Windows computer for 5 years (using the start command instead of the "&" character to spawn the instances) with no issues. I don't know anything about java, so I don't know what the errors mean. Do I need more RAM, or to increase some value for java?

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • Nov 22, 2017 at 03:04 AM

    Hello Harold, I've gone through your JVM dump file and I found out it could be one of your jbisql JVM instances which is pid=9990 and dump file indicate that the size of this heap of this instance is 1.06GB. Your ec2 AMI Linux instance only has 7.5GB of RAM so it could be RAM size is not enough to lead to your issue. I suggest that you could modify your script just create 3 or 5 jbisql instances to test whether you could solve your problem. If it can be solved that means you need to increase your RAM of your cloud server. thanks.

    Internal Error (0xe0000002), pid=9990, tid=140653665359616

    heap: 0x0000000001000000 .. 0x0000000044a00000, 1.06 GB (276992 4.00 KB pages), needs commit: yes, can be uncommitted: yes)

    Add comment
    10|10000 characters needed characters exceeded

  • Nov 22, 2017 at 08:53 AM

    If RAM is limited, you might also try to use the old dbisqlc utility instead, in case you primarily want to run scripts...

    As it is C-based, it doesn't require a JVM and uses waaaaaay less memory.

    Add comment
    10|10000 characters needed characters exceeded

  • Nov 28, 2017 at 04:13 AM

    Hi,

    You are using am older patch of SAPJVM, it would help to apply the latest patch. Refer to these notes

    1442124 How to download a SAP JVM patch from the SMP

    1133020How to import a SAP JVM patch into an AS Java

    Regards,

    Asha

    Add comment
    10|10000 characters needed characters exceeded