0

I just want to pg_dumpall my postgresql db in /home/ftpuser/backups/ folder i just created.

So I created a group (backuppers) with ftpuser and postgres as members. then i chgrp backuppers to /home/ftpuser/backups/, also chown postgres:backuppers just to be sure. In fact ls -l output tells me that /home/ftpuser/backups/ belongs to postgres.

The problem is that ftpuser can read and write to that folder, but postgres user can't. Even ls outputs access denied. Postgres simply cant read or write to that folder, even if it's owned by postgres himself. Any hint?

I also tried to create a folder like /backups owned by postgres and by the backuppers group, in fact postgres and ftpuser can read and write from that folder. Then the problem is that when i log in from ftp (lftp -u ftpuser ipaddress), ftpuser is unable to write, read and even cd /backups.

4
  • I guess you have to have the permissions on the /home/ftpusers as well, your user need to go through that directory as well. Jul 1, 2017 at 17:16
  • actually it has those permissions. Btw i ended up not using lftp but using curl and a workaround. Ty anyway Jul 1, 2017 at 22:44
  • curl ? how does it help with dumping a folder ? Jul 2, 2017 at 19:43
  • i moved the dump done with pg_dump in a folder accessible through ftps and accessible also with ftpuser then used curl to download that folder Jul 3, 2017 at 14:11

1 Answer 1

-1

Ended up with using curl, it's probably a lftp problem

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .