ivan marchesini <marchesini@unipg.it> writes:
> I have installed a postgres db using a datadir different
> from /var/lib/pgsql/.psql_history.
> then:
> su postgres
> psql postgres
> All went fine but when I exit from psql from a db I obtain:
> _______
> could not save history to file "/var/lib/pgsql/.psql_history": No such
> file or directory
> _______
Apparently the postgres account still has HOME set to /var/lib/pgsql.
You'll want to make that point to some directory that actually exists.
regards, tom lane