Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

Trying run a java app but have java issue

Discussion in 'General Discussion' started by TJCooper, Mar 17, 2004.

  1. TJCooper

    TJCooper Member

    Joined:
    Sep 21, 2003
    Messages:
    22
    Likes Received:
    0
    Trophy Points:
    151
    Location:
    St. Louis, MO
    I am try to run this command (some fields changed for privacy) in ssh to start it

    Code:
    cd /home/USERNAME/;nohup /usr/bin/j2sdk1.4.2_03/bin/java -jar jwwim_server_sql2.jar 127.0.0.1 USERNAME_DATABASENAME USERNAME_DATABASEUSERNAME DATABASEPASS PORTNUMBER
    I can run it with no problems as root but get this error if i run as the user

    Code:
    Error occurred during initialization of VM
    Could not reserve enough space for object heap
    Any ideas???

    I also tried putting the java installation in the users folder and still no luck..
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  2. jnagro

    jnagro Active Member

    Joined:
    Jun 28, 2003
    Messages:
    33
    Likes Received:
    0
    Trophy Points:
    156
    same issue here... someone please post info...
     
  3. jnagro

    jnagro Active Member

    Joined:
    Jun 28, 2003
    Messages:
    33
    Likes Received:
    0
    Trophy Points:
    156
    Problem Found

    java needs a lot of system resources, cpanel puts some ulimit restrictions in /etc/bashrc to limit normal users... with these default ulimit settings java uses more than its share and gets killed... if you comment out those lines and re-login you will be able to run it... i am currently looking for correct ulimit settings soi you can still limit users to some degree and let them use java... i will post those later...
     
  4. TJCooper

    TJCooper Member

    Joined:
    Sep 21, 2003
    Messages:
    22
    Likes Received:
    0
    Trophy Points:
    151
    Location:
    St. Louis, MO
    instead of editing /etc/bashrc I added this to the command -Xmx48M like here below...

    Code:
    cd /home/USERNAME/;
    nohup /usr/bin/j2sdk1.4.2_03/bin/java -Xmx48M -jar jwwim_server_sql2.jar 127.0.0.1 USERNAME_DATABASENAME USERNAME_DATABASEUSERNAME DATABASEPASS PORTNUMBER
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice