Fabrice.Sznajderman@devoteam.com wrote:
> I look the processes on my server where was installed Postgres Database.
> I can saw, when I do top command, many process named : idle in transaction.
>
> What happend with this process? what is the cause of this message?
Each process corresponds to a single client connection to the database.
"idle in transaction" means that connection has a transaction open but
is not currently doing any work. If I had to guess at the cause of this
I'd say that you are using a connection pool and a 7.4 driver.
The JDBC driver would cause these idle transactions itself (mostly
harmlessly) in 7.4 and earlier releases when autocommit was off: a
commit or rollback would automatically start a new transaction even
before any queries had been run.
With 8.0 and later drivers a new transaction is only started when the
first query after a commit or rollback is done, so if you are using
these drivers it probably indicates an application bug where it is not
correctly closing transactions it begins.
-O