Java application getting killed automatically in Solaris

Hi to all,

I have developed a Java application for Solaris 10.

I am uing JDK 5.
But it is getting killed after some time.

And at the terminal, I got message as Killed.

I am new to Solaris.

Can anybody help me?

Depending on how many objects you are allocating, you could be blowing your heap. Memory leaks are still possible in Java. Make sure you are dereferencing your objects (setting to null) so garbage collection can reclaim them. Also make sure socket and db connections are not remaining open. It is quite possible that your application needs to have larger memory bounds.

To set larger memory bounds from between 32MB to 128MB: java -Xms32m -Xmx128m MyClassName

I am using non root account.
Is it cause of it.

Same application is running good in windows 2003 platform having less memory.

How are you firing up the process calling it? it could be something as simple as you need to nohup the process and stick it into the background. This would prevent the process from dying when you logged out.

and no, running as a non-privileged user is a good idea. only use the root user when you have to. Depending on what your app does, you should be able to run everything as a non-privileged user at all times.