{"action":"created","issue":{"url":"https://api.github.com/repos/markokr/pgbouncer-dev/issues/31","labels_url":"https://api.github.com/repos/markokr/pgbouncer-dev/issues/31/labels{/name}","comments_url":"https://api.github.com/repos/markokr/pgbouncer-dev/issues/31/comments","events_url":"https://api.github.com/repos/markokr/pgbouncer-dev/issues/31/events","html_url":"https://github.com/markokr/pgbouncer-dev/issues/31","id":44686922,"number":31,"title":"PostgreSQL: \"Invalid length of startup packet\" after KILL database","user":{"login":"okbob","id":546675,"avatar_url":"https://avatars.githubusercontent.com/u/546675?v=3","gravatar_id":"","url":"https://api.github.com/users/okbob","html_url":"https://github.com/okbob","followers_url":"https://api.github.com/users/okbob/followers","following_url":"https://api.github.com/users/okbob/following{/other_user}","gists_url":"https://api.github.com/users/okbob/gists{/gist_id}","starred_url":"https://api.github.com/users/okbob/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/okbob/subscriptions","organizations_url":"https://api.github.com/users/okbob/orgs","repos_url":"https://api.github.com/users/okbob/repos","events_url":"https://api.github.com/users/okbob/events{/privacy}","received_events_url":"https://api.github.com/users/okbob/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2014-10-02T13:39:59Z","updated_at":"2015-03-24T15:00:14Z","closed_at":null,"body":"Hi\r\n\r\nI am testing a usage of KILL statement. KILL works well, but next login to same database hangs (fails after login timeout), and I see messages \"Invalid length of startup packet\" in PostgreSQL log.\r\n\r\n```\r\npsql -p 6432 postgres -c \"SELECT 1\"\r\npsql -p 6432 pgbouncer -c \"KILL postgres\"\r\npsql -p 6432 postgres -c \"SELECT 1\" ## hangs, fails client_login_timeout (server down)\r\n```\r\n`SHOW CLIENTS` show last request as \"waiting\" state.\r\nNext connections to database postgres fails quickly: pgbouncer cannot connect to server\r\n\r\nBut sometimes I got a message LOG:  invalid length of startup packet in PostgreSQL log\r\n\r\nWorkaround - database should be disabled first.\r\n```\r\npsql -p 6432 postgres -c \"SELECT 1\"\r\npsql -p 6432 pgbouncer -c \"DISABLE postgres; KILL postgres\"\r\npsql -p 6432 postgres -c \"SELECT 1\"\r\n```\r\nIt is expected behaviour?\r\n"},"comment":{"url":"https://api.github.com/repos/markokr/pgbouncer-dev/issues/comments/85541513","html_url":"https://github.com/markokr/pgbouncer-dev/issues/31#issuecomment-85541513","issue_url":"https://api.github.com/repos/markokr/pgbouncer-dev/issues/31","id":85541513,"user":{"login":"petere","id":105543,"avatar_url":"https://avatars.githubusercontent.com/u/105543?v=3","gravatar_id":"","url":"https://api.github.com/users/petere","html_url":"https://github.com/petere","followers_url":"https://api.github.com/users/petere/followers","following_url":"https://api.github.com/users/petere/following{/other_user}","gists_url":"https://api.github.com/users/petere/gists{/gist_id}","starred_url":"https://api.github.com/users/petere/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/petere/subscriptions","organizations_url":"https://api.github.com/users/petere/orgs","repos_url":"https://api.github.com/users/petere/repos","events_url":"https://api.github.com/users/petere/events{/privacy}","received_events_url":"https://api.github.com/users/petere/received_events","type":"User","site_admin":false},"created_at":"2015-03-24T15:00:14Z","updated_at":"2015-03-24T15:00:14Z","body":"I noticed this as well.  Something is wrong with the `KILL` command."}}