CPU 100% usage caused by unknown postgres query

2019-08-18 07:11发布

问题:

I installed timescaledb extension (v.5.0) for PostgreSQL (v9.6) on 16.04 Linux box and observes that Postgres process occupies 100% CPU:

here is result of top command:

PID   USER      PR  NI    VIRT    RES    SHR S %CPU %MEM   TIME+   COMMAND
19885 postgres  20   0  192684   3916   1420 S 98.3  0.1   5689:04 x3606027128                                     

I run query SELECT pid, datname, usename, query FROM pg_stat_activity and find two weird queries

pid   datname   username  query
19882 postgres  postgres  select Fun013301 ('./x3606027128 &')
19901 postgres  postgres  select Fun013301 ('./ps3597605779 &')

function Fun013301 is not existed in postgres database. I cannot figure out what ./x3606027128 command is!?