Re: Linux user www-data has no access to amphora2 DB
От | David Stanaway |
---|---|
Тема | Re: Linux user www-data has no access to amphora2 DB |
Дата | |
Msg-id | 1019497878.24392.69.camel@ciderbox обсуждение исходный текст |
Ответ на | Linux user www-data has no access to amphora2 DB (Denny-Schierz <cuall@gmx.de>) |
Список | pgsql-admin |
On Mon, 2002-04-22 at 12:32, Denny-Schierz wrote: > Hi pgsql-admin, > > i want to install the amphora2 light groupware software under Debian Woody > with pgsql 7.2.1. I have to restore a dump into the amphora2 DB that > i created before.: > ----------------- > testlinux:/home/amphora2/inst# su www-data -s /bin/bash -c 'psql amphora2 < amphora2.0.dump' > ----------------- > > but postgres tells me: Does www-data exist as a postgres user? I have tried to reproduce your problem, but I can't. I don't have a password for www-data so I use sudo: dstanawa@ciderbox:~$ sudo -u www-data psql -c "select version()" template1 version ----------------------------------------------------------------------- PostgreSQL 7.2.1 on powerpc-unknown-linux-gnu, compiled by GCC 2.95.4 (1 row) dstanawa@ciderbox:~$ tail -11 /etc/postgresql/pg_hba.conf local all ident sameuser #host all 127.0.0.1 255.0.0.0 trust host all 0.0.0.0 0.0.0.0 reject # If you want to allow non-local connections, you will need to change 'reject' # to 'crypt' or some other suitable authentication method. (Debian postgresql # is not built with Kerberos authentication enabled.) # To allow TCP/IP access, even from localhost, the postmaster must also be # started with the -i option or the option TCPIP_SOCKET must be set in # /etc/postgresql/postgresql.conf. dstanawa@ciderbox:~$ cat /etc/debian_version 3.0 > ----------------- > psql: FATAL 1: IDENT authentication failed for user "www-data" > ----------------- > > my pg_hba.conf: > > local amphora2 ident amphora > local all ident sameuser > host all 127.0.0.1 255.0.0.0 ident sameuser > host all 0.0.0.0 0.0.0.0 reject Anyway.. you probably want to restore the database as a super user (EG: User Postgres) The dump script should have \connect - "www-data" statements in it. It also may have some \connect - "postgresql" statements too. which could cause problems as user www-data -- David Stanaway
Вложения
В списке pgsql-admin по дате отправления: