neeraj kumar <neeru.cse@xxxxxxxxx> writes: > Yes we use SSL to connect to DB. Hm. I'm suspicious that one of the functions that fetch data for an SSL connection threw an error. In particular, it doesn't look to be hard at all to make X509_NAME_to_cstring fall over --- an encoding conversion failure would do it, even without any stretchy assumptions about OOM this early in backend start. Have you got any SSL certificates floating around with non-ASCII subject name or issuer name? > From comment seems like each backend should have its own copy > of PgBackendStatus, it means st_changecount should be different for each > process. If st_changecount was corrupted for 1/2 process, how can it impact > newly created process. So could you please help to understand then how come > if we run new query via new console (means new process) that also is > getting stuck. No, that field is in shared memory. The easiest way to get it reset would be to restart the postmaster. It's possible you could do it without that, by starting enough sessions so that one of them takes up the broken pg_stat_activity slot. regards, tom lane