zabbix-backup
zabbix-backup copied to clipboard
Do not read neither the system-wide psqlrc file nor the user's ~/.psqlrc file
During unknown tables check there is error:
Reading database options from /etc/zabbix/zabbix_server.conf...
Configuration:
- type: psql
- host: 127.0.0.1 (127.0.0.1)
- port: 5432
- database: zabbix
- user: zabbix
- output: /tmp/tmp.tzM4s7yilr
Fetching list of existing tables...
ERROR
Unknown tables found in database:
- Time:
- 7.813
- ms
To include them (full data backup) specify -f, to ignore them use -i
It happens because I use \timing in ~/.psqlrc to see how long each query takes.
Adding --no-psqlrc solves the issue.
PS: System info: postgres-server-11 on debian-8 (jessie)
PPS: Sorry my Markdown skill is poor.
maybe you should add an option to enable/disable this behavior, rather than always disabling?
@ironbishop, thanks for comment. IMO backup software should just work, in case of bath mode, it should not rely on local user preferences. I would prefer to leave this PR as-is, if it's possible.
btw, there is duplicate: #25
There is, and it's missing the cli option the same way. Can you add it?