Win a copy of Terraform in Action this week in the Cloud forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Tim Cooke
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Liutauras Vilda
Sheriffs:
  • Jeanne Boyarsky
  • Rob Spoor
  • Bear Bibeault
Saloon Keepers:
  • Jesse Silverman
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Piet Souris
  • Al Hobbs
  • salvin francis

setting JAVA_OPTS variable in linux

 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Hi All,

I’m very new to this setting JAVA_OPTS variable.
Please can you explain in detail.

Stepwise proc for configuring
for linux machines as well(not much aware about the linux commands aswell)

–one more question :
1) If i have two tomcat application running on my windows XP ,does this JAVA_OPTS
size apply for both, if yes how to make it specific for each application.

2)what does Xms and DXms stand for.

Thanks in advance
 
Saloon Keeper
Posts: 24587
168
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Welcome to the JavaRanch, Gangam!

Tomcat comes setup to use 2 environment variables: CATALINA_HOME and CATALINA_BASE. One refers to the directory that contains all the parts of Tomcat that can be shared between multiple instances of Tomcat. The other is a separate directory for each Tomcat instance.

In the basic setup, CATALINA_HOME and CATALINA_BASE point the the same directory and both sets of subdirectories share that common root. In your case, however, you'd have a separate CATALINA_BASE for each Tomcat you're running and it would contain things like that Tomcat's conf/server.xml file, the webapps directory, work directory, log directory, and so forth.

The easiest way to setup JAVA_OPTS is to create a file named "$CATALINA_BASE/bin/setenv.sh" and define JAVA_OPTS in that file. setenv.sh will be executed ("sourced") as part of the startup and control functions provided by $CATALINA_BASE/bin/catalina.sh, which is in turn invoked by the Tomcat startup and shutdown scripts.
 
Gangam Mekerira
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks a lot Tim

 
You showed up just in time for the waffles! And this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
reply
    Bookmark Topic Watch Topic
  • New Topic