Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I am trying to figure out why I get some weird entries in my postgresql log after I do a restart:

2010-05-14 11:30:25 EEST LOG:  database system was shut down at 2010-05-14 11:30:22 EEST
2010-05-14 11:30:25 EEST LOG:  autovacuum launcher started
2010-05-14 11:30:25 EEST LOG:  database system is ready to accept connections
2010-05-14 11:30:25 EEST LOG:  incomplete startup packet
2010-05-14 11:30:40 EEST WARNING:  there is already a transaction in progress
2010-05-14 11:30:40 EEST LOG:  could not receive data from client: Connection reset by peer
2010-05-14 11:30:40 EEST LOG:  unexpected EOF on client connection

First, there's the 2010-05-14 11:30:25 EEST LOG: incomplete startup packet which bugs me. Anyone has any idea why this happens?

And also, this one is very strange: 2010-05-14 11:30:40 EEST WARNING: there is already a transaction in progress ...

share|improve this question
add comment

2 Answers 2

up vote 2 down vote accepted

incomplete startup packet means a connection was established but the Postgres server didn't get the handshake it was expecting (I get a ton of these as my monitoring system checks to make sure port 5432 is open but isn't smart enough to actually log in to & query the DB).
Whether or not this is a problem depends on if you expect to have something connecting and not handshaking: For me seeing it once every 5 minutes isn't an issue, but if you're not expecting it this message could be an indication that you're being port scanned.

WARNING: there is already a transaction in progress means exactly what it says: Someone tried to start a transaction while already in a transaction (BEGIN ... BEGIN).
If you see this a lot somebody wrote some bad SQL in a program and you should find/fix it because the corresponding COMMIT and ROLLBACK statements may not do what you expect. If you see it once and never again someone probably fat-fingered a transaction in psql.

share|improve this answer
add comment

In our environment, incomplete startup packet are caused by haproxy sending a heartbeat on a programmable interval (for us, every 600000 milliseconds). We use haproxy in tcp mode to relay business users requests to run reports again postgres.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.