HypoPG / hypopg

Hypothetical Indexes for PostgreSQL
https://hypopg.readthedocs.io
Other
1.39k stars 59 forks source link

Cannot create extension in psql (Ubuntu) #61

Closed minhduchoang301 closed 2 years ago

minhduchoang301 commented 2 years ago

I use Ubuntu 20.04 (wsl2). I tried sudo make install and it ran perfectly. However, it fails with this error when I create extension:

ERROR: could not load library "/usr/lib/postgresql/13/lib/hypopg.so": /usr/lib/postgresql/13/lib/hypopg.so: undefined symbol: errstart_cold

rjuju commented 2 years ago

Hi,

errstart_cold was introduced in pg 14 and it looks like you're creating the extension on pg13.

Do you have pg14 (or more recent) installed? One usual issue is getting a difffent pg_config when using sudo compared to the one on your current shell.

You should check that sudo pg_config returns the correct postgres version, if not fix it and do a full clean / make / make install cycle.

minhduchoang301 commented 2 years ago

Thank you! problem solved