archive command Permission Denied?
| От | Jason Long |
|---|---|
| Тема | archive command Permission Denied? |
| Дата | |
| Msg-id | 4914B948.1020606@supernovasoftware.com обсуждение исходный текст |
| Ответы |
Re: archive command Permission Denied?
|
| Список | pgsql-general |
Please bear with me. I am fairly new to Linux.
I am working on archiving my WAL files. For now I am just mailing myself a list of the directory contents using the following script.
-rwxr-xr-x 1 postgres postgres 87 Oct 28 20:23 /var/lib/pgsql/mail-WAL-list.sh
the contents are simply
ls -lrt /var/lib/pgsql/data/pg_xlog/ | mail -s "WAL files are:" myemail@mydomain.com
I also have this set up to run in the postgres users cron at 8 a.m.
I can run this when logged on as postgres and the cron runs fine as well, but I keep seeing the following in my logs.
LOG: archive command failed with exit code 126
DETAIL: The failed archive command was: /var/lib/pgsql/mail-WAL-list.sh
WARNING: transaction log file "0000000100000000000000F0" could not be archived: too many failures
sh: /var/lib/pgsql/mail-WAL-list.sh: Permission denied
I would appreciate any advice on what permission I need to set in order for this command to run.
I am working on archiving my WAL files. For now I am just mailing myself a list of the directory contents using the following script.
-rwxr-xr-x 1 postgres postgres 87 Oct 28 20:23 /var/lib/pgsql/mail-WAL-list.sh
the contents are simply
ls -lrt /var/lib/pgsql/data/pg_xlog/ | mail -s "WAL files are:" myemail@mydomain.com
I also have this set up to run in the postgres users cron at 8 a.m.
I can run this when logged on as postgres and the cron runs fine as well, but I keep seeing the following in my logs.
LOG: archive command failed with exit code 126
DETAIL: The failed archive command was: /var/lib/pgsql/mail-WAL-list.sh
WARNING: transaction log file "0000000100000000000000F0" could not be archived: too many failures
sh: /var/lib/pgsql/mail-WAL-list.sh: Permission denied
I would appreciate any advice on what permission I need to set in order for this command to run.
-- Thank you for your time, Jason Long CEO and Chief Software Engineer BS Physics, MS Chemical Engineering http://www.octgsoftware.com HJBug Founder and President http://www.hjbug.com
В списке pgsql-general по дате отправления: