Received: from ciderbox.stanaway.net (ciderbox.stanaway.net [170.76.50.98]) by postgresql.org (Postfix) with ESMTP id 4DA85475934 for ; Mon, 22 Apr 2002 13:51:20 -0400 (EDT) Received: by ciderbox.stanaway.net (Postfix, from userid 1000) id C7AC09354C; Mon, 22 Apr 2002 12:51:18 -0500 (CDT) Subject: Re: Linux user www-data has no access to amphora2 DB From: David Stanaway To: Denny-Schierz Cc: pgsql-admin@postgresql.org In-Reply-To: <19237774917.20020422193259@gmx.de> References: <19237774917.20020422193259@gmx.de> Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="=-xVPRBT4VM30jazH43rax" X-Mailer: Ximian Evolution 1.0.3 Date: 22 Apr 2002 12:51:18 -0500 Message-Id: <1019497878.24392.69.camel@ciderbox> Mime-Version: 1.0 X-Archive-Number: 200204/205 X-Sequence-Number: 4093 --=-xVPRBT4VM30jazH43rax Content-Type: text/plain Content-Transfer-Encoding: quoted-printable On Mon, 2002-04-22 at 12:32, Denny-Schierz wrote: > Hi pgsql-admin, >=20 > i want to install the amphora2 light groupware software under Debian Woo= dy > 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 amphora= 2 < amphora2.0.dump' > ----------------- >=20 > but postgres tells me: Does www-data exist as a postgres user?=20 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=20 version=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 ----------------------------------------------------------------------- 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=20 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=20 3.0 > ----------------- > psql: FATAL 1: IDENT authentication failed for user "www-data" > ----------------- >=20 > my pg_hba.conf: >=20 > 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 --=-xVPRBT4VM30jazH43rax Content-Type: application/pgp-signature; name=signature.asc Content-Description: This is a digitally signed message part -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.6 (GNU/Linux) Comment: For info see http://www.gnupg.org iQEXAwUAPMRNlr6yIDFGeSAyFAKUcAQAoAwLCNUL455WKvy90Iiwlc0JJ3nExbNk Jyg3CWnBYm5HqSak+NwwVkJhe+1a+vLBzMAmeCfIqxS2yXMfluXs/f7SgEAkWbTU P5gRiC1EHwYFkQ/d3ackp6FZbWSimiNa++iqg3DDuHHkhU9bicpmpDRte3GhMh/B PsSSim3d1h8EALBxOohUhY9VDymzHYPH+FVNe7rfAzx8qhCpUAbYTVtHBLaDO/dS H/jxy8T/pWqMfPgKGF7bO2VfokH0ZZfUwYsQuBdskWSnQKLFre2qjBbRofnbmT03 ZmcPsrWLDYFR7vYA4GlF/q+Z8yevM9h+tEQk5yGog8qqm4zmPMAy9o9Q =oqAN -----END PGP SIGNATURE----- --=-xVPRBT4VM30jazH43rax--