**
(Postgrex.Error)ERROR 58P01
(undefined_file):无法打开扩展控制文件“/usr/local/Cellar/postgresql@9.6/9.6.5/share/postgresql@9.6/ extension / postgis.control“:没有这样的文件或目录
当我尝试运行mix ecto.migrate
...
为什么要看那条路?我试过移动postgis.control
如果我运行此命令find /usr -name postgis.control
,它会给我这个结果:
/usr/local/Cellar/postgis/2.4.0_1/share/postgresql/extension/postgis.control
/usr/local/share/postgresql@9.6/extension/postgis.control
有人知道我如何移动postgis.control或我可能做错了吗?
答案 0 :(得分:1)
文件postgis.control
应位于PostgreSQL共享目录的extension
子目录中。您可以通过运行pg_config --sharedir
来找到共享目录的位置。
所有其他属于PostGIS扩展的文件也必须到位:与控制文件位于同一目录中的SQL文件,以及pg_config --libdir
中的共享库。