472,960 Members | 2,011 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

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

Memory utilization (linux v. openbsd)

Hi all,

I have an app that runs on multiple boxes. On my slackware box, running
Python 2.5.1, top shows this:

Mem: 1002736k total, 453268k used, 549468k free, 31392k buffers
Swap: 2097136k total, 0k used, 2097136k free, 136876k cached

PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
2741 dnm 16 0 267m 261m 2676 S 99.3 26.7 14:54.62 python

The same app running on OpenBSD 4.1 (but on Python 2.5P3 from ports)
yields this (actually, I have 2 copies running on a dualcore box):

Memory: Real: 1130M/1989M act/tot Free: 792K Swap: 337M/2048M used/tot

PID USERNAME PRI NICE SIZE RES STATE WAIT TIME CPU
COMMAND
12380 dnm 64 0 926M 436M run/0 - 22:22 73.58%
python2.5
22956 dnm 64 0 933M 695M onproc/0 - 22:46 68.55%
python2.5

RES was has over 800M earlier in the job.

My problem is that the two process under OpenBSD are going to fail with
a MemoryError becaause the size just keeps getting larger and larger.
ulimit -d is 1G for each process.

Any idea why the memory utilization is so much higher under OpenBSD?

What I also find interesting is that the OpenBSD box seems to grind to a
halt (that's probably due to swapping since there's 500M of swap space
in use). Those processes should both be over 90% since they are CPU
bound, and they are that way at the start of the run. Gradually, the
system % creeps up as does idle, but there's no reason for them to be
idle. It's a CPU bound process. (While I'm typing this top is showing
cpu rats of 63% and 41% for the two jobs).

TIA,
nazgul
Jul 29 '07 #1
1 2800
na****@jsbsystems.com wrote:
My problem is that the two process under OpenBSD are going to fail with
a MemoryError becaause the size just keeps getting larger and larger.
ulimit -d is 1G for each process.
The problem is that you can't get accurate memory use readings from top.

The reality is that your python program is probably using the same
amount of memory on both platforms (in and of itself), but due to the
way the memory management OS system works, the usage is being reported
differently on BSD. Basically you're seeing the memory footprint of the
python executable, it's data (your program) and also all of the shared
libraries that python is linked to. Of course the shared libraries are
shared, so it's not like python's using all this memory just itself.
>
Any idea why the memory utilization is so much higher under OpenBSD?

What I also find interesting is that the OpenBSD box seems to grind to a
halt (that's probably due to swapping since there's 500M of swap space
in use). Those processes should both be over 90% since they are CPU
bound, and they are that way at the start of the run. Gradually, the
system % creeps up as does idle, but there's no reason for them to be
idle. It's a CPU bound process. (While I'm typing this top is showing
cpu rats of 63% and 41% for the two jobs).
I can't answer your questions or solve your problem. But I just wanted
to point out that the problem is likely somewhere besides python itself.
Maybe there are settings in the OS. Who knows. My guess is the
difference in overall memory footprint is due to differences in the C
library and its dependencies. You probably would want to bring this
issue up on the OpenBSD lists as it's clear that your BSD machine is
having problems generally (trashing to death). This doesn't appear to
be a python problem.
>
TIA,
nazgul
Jul 29 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

12
by: Anon | last post by:
Hello all, I'm hoping for some guidance here... I am a c/c++ "expert", but a complete python virgin. I'm trying to create a program that loads in the entire FreeDB database (excluding the...
3
by: Noah | last post by:
I'm getting configure warnings and make errors when I try to build Python 2.3.4 under OpenBSD 3.5. I don't see anything in the README under "Platform specific note" for OpenBSD. I tried opening...
25
by: Maurice LING | last post by:
Hi, I think I've hit a system limit in python when I try to construct a list of 200,000 elements. My error is malloc: vm_allocate (size = 2400256) failed...... Just wondering is this...
11
by: jong | last post by:
I have a problem with an C# application. The application is a 24x7 low volume message processing server. The server has a single thread of processing, running in a continuous loop, for each...
2
by: Steph L | last post by:
Hi, A given Milter program compiles ok on OpenBSD/FreeBSD/Linux but not on Solaris : it uses daemon(3) http://www.openbsd.org/cgi-bin/man.cgi?query=daemon&apropos=0&sektion...
35
by: Alex Martelli | last post by:
Having fixed a memory leak (not the leak of a Python reference, some other stuff I wasn't properly freeing in certain cases) in a C-coded extension I maintain, I need a way to test that the leak is...
5
by: nazgul | last post by:
Hi all, In my prev post, I indicated I was using 2.5.1 on one box and 2.5p3 on the OpenBSD box. I'm trying to build 2.5.1 on OpenBSD and I get this: Modules/posixmodule.c:5701: error: `lstat'...
1
by: Kaheru | last post by:
memory utilization increase? This is because when i try to keep track of the CPU utilization and memory utilization of my FTP server process (ftpserver.exe), the CPU utilization increase, but the...
7
by: balach | last post by:
hi all, i am new in .NET, some body please help me regarding calculating total cpu utilization and RAM memory utilization in percentage (Accurately) on page load event of ASP.NET. i found the...
2
by: DJRhino | last post by:
Was curious if anyone else was having this same issue or not.... I was just Up/Down graded to windows 11 and now my access combo boxes are not acting right. With win 10 I could start typing...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 4 Oct 2023 starting at 18:00 UK time (6PM UTC+1) and finishing at about 19:15 (7.15PM) The start time is equivalent to 19:00 (7PM) in Central...
4
NeoPa
by: NeoPa | last post by:
Hello everyone. I find myself stuck trying to find the VBA way to get Access to create a PDF of the currently-selected (and open) object (Form or Report). I know it can be done by selecting :...
3
NeoPa
by: NeoPa | last post by:
Introduction For this article I'll be using a very simple database which has Form (clsForm) & Report (clsReport) classes that simply handle making the calling Form invisible until the Form, or all...
1
by: Teri B | last post by:
Hi, I have created a sub-form Roles. In my course form the user selects the roles assigned to the course. 0ne-to-many. One course many roles. Then I created a report based on the Course form and...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 1 Nov 2023 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM) Please note that the UK and Europe revert to winter time on...
3
by: nia12 | last post by:
Hi there, I am very new to Access so apologies if any of this is obvious/not clear. I am creating a data collection tool for health care employees to complete. It consists of a number of...
0
NeoPa
by: NeoPa | last post by:
Introduction For this article I'll be focusing on the Report (clsReport) class. This simply handles making the calling Form invisible until all of the Reports opened by it have been closed, when it...
0
isladogs
by: isladogs | last post by:
The next online meeting of the Access Europe User Group will be on Wednesday 6 Dec 2023 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, Mike...

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.