Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Sorry for my poor English, but i tried to explain my problem as simple as possible
We have a application which runs on java 1.6 and above. This application consists of two jar files, one is main jar file and other we had named it as angel as it is run in background through main jar.
Both the jar files runs on different ports.
Now the scene is when we run the main jar file with cmd as
java -jar jarfilename in windows the second jar gets ran automatically as expected. Both the jar runs on different ports and the application runs without interruption.
But when we do the same thing in Linux system one of the jar gets nonfunctional after 15 min with port remaining open and the application does not runs as per our expectaions.
The strange thing is when we run both the jars separately on Linux, non of the jars gets stuck and application runs as per out expectations.
Kindly let me now what i would need to do on OS level so that our application runs as per our expectations.
It depends on what your angel app does. If it for examples opens periodically some ports or writes something to files on the system, then it could be the file descriptor use limt problem. And perhaps setting the ulimt to something higher then the usual value of 1024 would help (for example :
Setting ulimit:
# ulimit -n 99999
or over Sysctl max files command:
#sysctl -w fs.file-max=100000
or in the /etc/sysctl.conf file. )
Alternatively you could perhaps think of the better way to solve the problem at hand for your second application then useing that much of the file access operations.
As per your suggestion i tried both the options seperately as well as combinedly but no difference. But when i run both the jars seprately, they runs without interuptions.
do these jars have logs? Probably you can find some relevant info in the logs. Also try to increase the memory of the JVM, probably it helps. http://wiki.vuze.com/w/Java_VM_memory_usage
Can you show an excerpt of source of how you start this "angel" .jar file from "main" .jar? The best if you could give full source or link to jars of both files.
java -jar -Xms1024 -Xmx2560 Opensync-server-platform-1.3.0.jar com.qarea.opendoc.server.Application (this is the main jar which run as seerver application
java -jar -Xms1024 -Xmx2560 Opensync-angel-services-1.3.0.jar angel.plugin.Main (this is the angel process)
For more info, there are no any errors in the log file.
Yes, but how you start "Opensync-angel-services-1.3.0.jar" FROM INSIDE "Opensync-server-platform-1.3.0.jar"? I mean the source code. I am afraid without full source code it will be impossible to guess what is wrong.
java.lang.InterruptedException
at java.lang.Object.wait(Native Method)
at java.lang.Object.wait(Object.java:167)
at java.lang.UNIXProcess.waitFor(UNIXProcess.java:115)
at com.qarea.opendoc.server.sm.socket.AngelSocket.startAngelPlugin(AngelSocket.java:59)
at com.qarea.opendoc.server.sm.socket.AngelSocket.run(AngelSocket.java:28)
- Dt : 2013-10-09 06:57:11.76 : EXCP
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.