473,408 Members | 2,888 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,408 software developers and data experts.

Java Linux Memory Usage

Hi,

I have a java program running on Linux Debian using jre 1.6 (I have tried under 1.5 with excatly the same results). As the program is running as a service I have been watching the memory usage from within linux, as well as using JProfiler. When looking at it from the operating system using ps or top I can see that the is a small increase in memory consumption every hour and never decreases again (like a memory leak).

So I looked at JProfiler and when looking at the memory heap it stays constant (as I started the program with -Xms32M and -Xmx32M). Also from within Jprofiler I checked the non heap memory and after setting a lower maximum on the code cache it look not to allocate memory more memory here.

So now with the Heap and non heap memory constant I wouldn't expect the process memory in linux to grow, but it does.

The profile of the java programs memory uasge from JProfiler show that everything is ok in regards to garbage collection

Can I trust the output from ps and top or is there a better way to determine the memory usage from the operating system?

Is this a problem or am I looking at something complete normal?

Thanks for you help

Thomas
Jul 18 '07 #1
2 4166
JosAH
11,448 Expert 8TB
Let the thing run (and keep it busy) for a couple of days. It's a nasty thing, that
can't be easily nailed down. I had similar behaviour once and only after a couple
of days I could spot the memory leak. OTOH, sometimes the amount of memory
allocated to the process grows and falls back again after some time. Best of
luck with that nasty behaviour. Let it run for a couple of days.

kind regards,

Jos
Jul 18 '07 #2
the 'top', 'ps', 'free' command of the linux os seems not to be useful for checking the memory info. your application may not get a memory leak, and the increase of the Memory Usage is just because you occupy more cache, and linux would release it some day, just wait for more time.

hope it works,
good luck

andy
Jul 19 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Adi | last post by:
A java program we have written crashes with IBM JDK 1.3.1 on linux. It works fine on other platforms(Solaris,HPUx). It gets a SIGSERV Signal 11 and crashes just after few minutes after starting up....
4
by: Bastien Raich | last post by:
Hello, I've been developping a Java application using sun's 1.4.1 on my NT4 box. It's a financial application that retrieves market data in real time, displays it in JTables, do some...
9
by: Tomer Ben-David | last post by:
Hi I have a big j2ee appliction that was so forth run on a single cpu machine. I have tested it on a dual cpu machine, its running much slower (about X3 times slower). I know that...
3
by: Kieron Briggs | last post by:
I am trying to run the java VM in a virtual linux webserver environment with WebCentral: http://www.webcentral.com.au/docs/products/display.cgi?id=104&productCategory=Linux%20Servers When I...
2
by: Dave Brueck | last post by:
Below is some information I collected from a *small* project in which I wrote a Python version of a Java application. I share this info only as a data point (rather than trying to say this data...
11
by: DrUg13 | last post by:
In java, this seems so easy. You need a new object Object test = new Object() gives me exactly what I want. could someone please help me understand the different ways to do the same thing in...
1
by: David Van D | last post by:
Hi there, A few weeks until I begin my journey towards a degree in Computer Science at Canterbury University in New Zealand, Anyway the course tutors are going to be teaching us JAVA wth bluej...
458
by: wellstone9912 | last post by:
Java programmers seem to always be whining about how confusing and overly complex C++ appears to them. I would like to introduce an explanation for this. Is it possible that Java programmers...
350
by: Lloyd Bonafide | last post by:
I followed a link to James Kanze's web site in another thread and was surprised to read this comment by a link to a GC: "I can't imagine writing C++ without it" How many of you c.l.c++'ers use...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.