Skip site navigation (1) Skip section navigation (2)

Fw: Leaking Handles in Postgres 7.1.2 on Cygwin dll 1.3.2 on Win 2000

From: "eCommerce Software Solutions Inc(dot)" <vinaysoni1(at)home(dot)com>
To: <pgsql-hackers(at)postgresql(dot)org>
Subject: Fw: Leaking Handles in Postgres 7.1.2 on Cygwin dll 1.3.2 on Win 2000
Date: 2001-07-22 04:19:11
Message-ID: 003a01c11265$75d82160$0100a8c0@cr786209a (view raw, whole thread or download thread mbox)
Lists: pgsql-hackers
----- Original Message ----- 
From: eCommerce Software Solutions Inc. 
To: pgsql-bugs(at)postgresql(dot)org 
Cc: pgsql-cygwin-request(at)postgresql(dot)org 
Sent: Saturday, July 21, 2001 9:15 PM
Subject: Leaking Handles in Postgres 7.1.2 on Cygwin dll 1.3.2 on Win 2000

The situation is this:

I have cygwin with ( dll 1.3.2 ) and latest Postgresql 7.1.2 on Win 2000
with SP1.

I use Java and JDBC to connect from a Windows to Postgresql server to do a
very simple select:
select count(*) from table1; // returns count of 2

It works fine.

Now I run this on 10 threads in my Java program. Each thread loops for
100000000 times.

When I do this every thing appears to be ok at first. Then, I realize that I
am loosing free memory really fast.

I go in the "task manager" in windows 2000 and look at the memory usage for
each process. It is fine i.e not growing.

But Available physical memory is going down really fast. I have no clue at

Then I notice that in Performance tab of Windows task manager, under Totals,
the handles is running very fast.

I discovered that it begins from 4080 and goes on incrimenting ( to a very
large number ) until I run out of memory.

Since both client and DB server are on the same machine it is hard to tell
which is leaking handles!

Now I moved the client to another machine.  The client uses JDBC to connect
to the PG Database running in Win2000 Cygwin environment on another Machine.
I looked at the Windows Task Monitor to notice that there are no leaking
handles on the client Machine. Therefore leak is not in my Program.

The handles are being leaked by PG on the Machine acting as DB Server in
Cygwin environment.

I hope this isolates the problem further to PG and Cygwin and not JDBC and
Client code.

Lets fix this problem.



pgsql-hackers by date

Next:From: Domingo Alvarez DuarteDate: 2001-07-22 10:16:55
Subject: unique index doesn't accept functions on fields
Previous:From: Tatsuo IshiiDate: 2001-07-22 00:28:03
Subject: Re: SIGCHLD handler in Postgres C function.

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group