Postgres 12未安装在RHEL 7上的扩展名
希望在RHEL 7上的Postgres 12 dB上安装PGSTATTUPLE扩展名,以查看索引碎片。目前,我只安装了一个扩展名,这就是PLPGSQL扩展名。
执行“创建扩展PGSTATTUPLE”会导致以下错误:
SQL Error [58P01]: ERROR: could not open extension control file "/usr/pgsql-12/share/extension/pgstattuple.control": No such file or directory
我验证了pgstattuple.control不在/usr/usr/pgsql-12/share/share/扩展文件夹中。
在网上搜索,似乎表明需要安装PostgreSQL-Contrib才能获得PGSTATTUPLE扩展。因此,我执行了以下命令:
$ sudo yum install postgresql-contrib
不幸的是,YUM安装PostgreSQL-Contrib导致PGSTATTUPLE和其他扩展程序安装到/usr/pgsql-9.6/share/share/extension中 文件夹,不在我想要的/usr/usr/pgsql-12/share/伸展文件夹中。
为了咯咯笑,我尝试在/usr/pgsql-9.6/share/extension中复制所有pgstattuple*文件到/usr/usr/pgsql-12/share/extension/extension文件夹,然后尝试调用create greatent creatention pgstattuple,但这不起作用,但是另一个错误。
问题是:
- 我应该期望sudo yum安装postgresql-contrib真正安装了Postgres 12的PGSTATTUPLE扩展程序吗?还是还有其他一些Postgres 12的软件包名称?
- 这是我的红帽存储库配置的问题吗?
- 通常,安装Postgres 12的PGSTATTUPLE扩展名的命令是什么,以便PGSTATTUPLE文件最终输入/usr/pgsql-12/share/share/extension文件夹?
非常感谢您的建议。
谢谢。
Looking to install the pgstattuple extension on my Postgres 12 DB on RHEL 7 to see index fragmentation. Currently I only have one extension installed and that's the plpgsql extension.
Executing 'CREATE EXTENSION pgstattuple' results in the following error:
SQL Error [58P01]: ERROR: could not open extension control file "/usr/pgsql-12/share/extension/pgstattuple.control": No such file or directory
And I verified that the pgstattuple.control is not located in the /usr/pgsql-12/share/extension folder.
Searching around the net, seemed to indicate that the postgresql-contrib needed to be installed to get the pgstattuple extension. So I did the following command:
$ sudo yum install postgresql-contrib
Unfortunately the yum install postgresql-contrib resulted in the pgstattuple and other extensions being installed into the /usr/pgsql-9.6/share/extension
folder, and not in the /usr/pgsql-12/share/extension folder where I want them.
For giggles, I tried copying all the pgstattuple* files in /usr/pgsql-9.6/share/extension to /usr/pgsql-12/share/extension folder, and then tried calling CREATE extension pgstattuple, but that didn't work with another error.
Questions are:
- Should I expect sudo yum install postgresql-contrib to actually install the pgstattuple extension for Postgres 12?? Or is there some other package name for Postgres 12?
- Could this be some problem with my Red Hat Repository configuration?
- In general what's the command to install the pgstattuple extension for Postgres 12 so that the pgstattuple files will end up in /usr/pgsql-12/share/extension folder??
Really appreciate any suggestions you have.
Thank you.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论