title: Eclipse memory settings when getting "Java Heap Space" and "Out of Memory"
body: <p>When trying to launch and run a flex/java project in eclipse I kept getting a "Out of Memory Exception" and "Java Heap Space" using Eclipse, Tomcat and a JRE.</p>
  
  <p>While researching trying to adjust the memory settings I found three places to adjust these:</p>
  
  <ul>
  <li><p>Eclipse.ini</p></li>
  <li><p>The JRE Settings under Window > Preferences</p></li>
  <li><p>Catalina.sh or Catalina.bat</p></li>
  </ul>
  
  <p>What are the differences between setting -xms and -xmx in these different places and what does is mean?</p>
  
  <p>Is there any way to verify these memory settings are being set accordingly?</p>
  
  <p>What are the optimal -xms and -xmx settings for a computer with 2gb of RAM?</p>
  
  <p>Any other memory tips?</p>
  
  <p>Thanks.</p>