answersLogoWhite

0


Best Answer

You can specify the starting and maximum heap sizes when you launch a Java program by using the command line switches:

-Xms<size> set initial Java heap size

-Xmx<size> set maximum Java heap size

Example: The following line will run the MyProgram Java program with 64-128mb heap space.

java -Xms64m -Xmx128m MyProgram

User Avatar

Wiki User

14y ago
This answer is:
User Avatar
More answers
User Avatar

Wiki User

14y ago

You can use the -Xms and -Xmx arguments to set the starting and maximum heap size of your Java application.

Running the following line will launch MyProgram with a starting heap size of 32MB and a maximum size of 128MB.

java -Xms 32M -Xmx 128M MyProgram

The maximum amount of Heap space you can use for your application would depend on the type of OS and JVM you are using. For a 32 bit OS and JVM the maximum heap space is only 2 GB whereas for a 64 bit OS and JVM the amount of heap space you can use is virtually unlimited.

This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: What are the steps to increase java heap space on a server?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

How do you increase java heap size on mobile phones?

How do increase java heap space on mobile


How much extra space is used by heap sort?

O(1)


What are HEAP tables in MySQL?

Heap is no longer the accepted term for these kinds of tables in MySQL but it is still supported for backwards compatibility. The new accepted term is Memory and as the name suggest, Memory tables store their data directly in memory. Memory tables are used primarily as temporary tables. When you delete a row from a memory table, you do not free up space in the server memory. Space is only freed once the table is deleted.


What is a heap?

Answer:- A sorting algorithm that works by first organizing the data to be sorted into a special type of binary tree called a heap. The heap itself has, by definition, the largest value at the top of the tree, so the heap sort algorithm must also reverse the order. It does this with the following steps:1. Remove the topmost item (the largest) and replace it with the rightmost leaf. The topmost item is stored in an array.2. Re-establish the heap.3. Repeat steps 1 and 2 until there are no more items left in the heap.The sorted elements are now stored in an array.A heap sort is especially efficient for data that is already stored in a binary tree. In most cases, however, the quick sort algorithm is more efficient.GOURAV KHARE (CHANDIGARH)gouravsonu89@gmail.com


What is the difference between binary heap and binomial heap?

The difference between Binomial heap and binary heap is Binary heap is a single heap with max heap or min heap property and Binomial heap is a collection of binary heap structures(also called forest of trees).


What heap means?

It means to heap


What are the names of the Septimus Heap books in order?

1. Septimus Heap: Magyk2. Septimus Heap: Flyte3. Septimus Heap: Physik4. Septimus Heap: Queste5. Septimus Heap: Syren6.Septimus Heap:Dark (coming summer 2011!)7.Septimus Heap:(Untitled) unknown date for coming


What is the birth name of Todd Heap?

Todd Heap's birth name is Todd Benjamin Heap.


Is heap a collective noun?

Yes, the noun 'heap' is used as a collective noun for: a heap of trash.


What are stored in heap memory?

Objects are stored in heap.


What is Fibonacci heaps algorithm?

fibonacci heap is a heap


How tall is Mark Heap?

Mark Heap is 6'.