我正在尝试创建一个表空间,但总是得到相同的错误
pablo@MisCompras-dev:~$ psql -d postgres -U pablo
psql (11.2 (Ubuntu 11.2-1.pgdg18.04+1))
Type "help" for help.
postgres=# create tablespace miscompras_space owner pablo location '/home/pablo/postgres';
ERROR: could not set permissions on directory "/home/pablo/postgres": Operation not permitted我将/home、/home/pablo和/home/pablo/postgres的权限设置为777,在创建表空间时得到相同的错误。
我还使用以下命令将pablo添加到这三个目录的访问控制列表中:
setfacl -m pablo:rwx [directory]当我键入时:
getfacl [directory]用户:pablo:rwx对所有3个都显示。我做错了什么?提前感谢
发布于 2019-05-04 00:48:47
表空间目录必须归postgres所有,因此
chown postgres:postgres /home/pablo/postgres然后再次尝试运行:
postgres=# create tablespace miscompras_space owner pablo location '/home/pablo/postgres';祝好运
https://stackoverflow.com/questions/55973397
复制相似问题