From pgsql-php@borsos.hu Fri Jan 24 18:37:39 2003 Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id 77E83477381 for ; Fri, 24 Jan 2003 13:37:39 -0500 (EST) Received: from Piac (www.compax.hu [213.163.10.114]) by postgresql.org (Postfix) with ESMTP id 7059C476074 for ; Fri, 24 Jan 2003 12:56:46 -0500 (EST) Received: from [213.163.10.121] by Piac (ArGoSoft Mail Server Pro for WinNT/2000/XP, Version 1.8 (1.8.2.5)); Fri, 24 Jan 2003 18:50:12 +0100 Message-ID: <000b01c2c3d2$0d80f9a0$790aa3d5@compax> From: =?iso-8859-2?Q?Borsos_J=F3zsef?= To: Subject: what do I wrong??? Date: Fri, 24 Jan 2003 18:57:22 +0100 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_0008_01C2C3DA.6D803200" X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2800.1106 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106 X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200301/76 X-Sequence-Number: 1821 This is a multi-part message in MIME format. ------=_NextPart_000_0008_01C2C3DA.6D803200 Content-Type: text/plain; charset="iso-8859-2" Content-Transfer-Encoding: quoted-printable $conn_string =3D "host=3Dx.x.x.x port=3D5432 dbname=3Dxxxx user=3DCOMPAX pa= ssword=3Dxxxx"; $connect =3D pg_connect($conn_string); RESULT: Warning: pg_connect() [function.pg-connect]: Unable to connect to PostgreSQ= L server: Password authentication failed for user 'COMPAX' . in xxx on line= 4 ------=_NextPart_000_0008_01C2C3DA.6D803200 Content-Type: text/html; charset="iso-8859-2" Content-Transfer-Encoding: quoted-printable
$conn_string =3D "host=3Dx.x.x.x port=3D54= 32=20 dbname=3Dxxxx user=3DCOMPAX password=3Dxxxx";
  $connect =3D=20 pg_connect($conn_string);
 
RESULT:
 
Warning: pg_connect() [function.pg-connect]: Unable to connect to PostgreSQL server: Passwor= d=20 authentication failed for user 'COMPAX' . in xxx on line= =20 4
------=_NextPart_000_0008_01C2C3DA.6D803200-- From mhoroschun@canprint.com.au Tue Jan 28 04:23:14 2003 Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id DCB20476E24 for ; Mon, 27 Jan 2003 23:23:14 -0500 (EST) Received: from neuromancer.canprint.com.au (mail.canprint.com.au [198.142.3.43]) by postgresql.org (Postfix) with ESMTP id 67D3A476F2D for ; Mon, 27 Jan 2003 23:20:06 -0500 (EST) Received: (from root@localhost) by neuromancer.canprint.com.au (8.12.6/8.11.1) id h0S4K6F6058972 for pgsql-php@postgresql.org; Tue, 28 Jan 2003 15:20:06 +1100 (EST) (envelope-from mhoroschun@canprint.com.au) Received: from canprint.com.au (cp252.canprint.intranet [192.168.1.252]) by neuromancer.canprint.com.au (8.12.6/8.11.1) with ESMTP id h0S4K1Bq058935; Tue, 28 Jan 2003 15:20:03 +1100 (EST) (envelope-from mhoroschun@canprint.com.au) Date: Tue, 28 Jan 2003 15:19:57 +1100 Subject: Re: what do I wrong??? Content-Type: text/plain; charset=ISO-8859-1; format=flowed Mime-Version: 1.0 (Apple Message framework v551) Cc: To: =?ISO-8859-1?Q?Borsos_J=F3zsef?= From: Matthew Horoschun In-Reply-To: <000b01c2c3d2$0d80f9a0$790aa3d5@compax> Message-Id: Content-Transfer-Encoding: quoted-printable X-Mailer: Apple Mail (2.551) X-Virus-Scanned: by Sophos SWEEP at CanPrint Communications X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200301/77 X-Sequence-Number: 1822 Hi Borsos, Could be a lot of different things. 1. What does pg_hba.conf contain? 2. You appear to be connecting using TCP/IP. Have you started=20 postmaster with the -i option or is 'tcpip_tocket =3D true' in=20 postgresql.conf? 3. Can you connect using the same host, port, dbname, user and password=20 using the psql command-line client? Matthew. On Saturday, January 25, 2003, at 04:57 AM, Borsos J=F3zsef wrote: > $conn_string =3D "host=3Dx.x.x.x port=3D5432 dbname=3Dxxxx user=3DCOMPAX= =20 > password=3Dxxxx"; > =A0 $connect =3D pg_connect($conn_string); > =A0 > RESULT: > =A0 > Warning: pg_connect() [function.pg-connect]: Unable to connect to=20 > PostgreSQL server: Password authentication failed for user 'COMPAX' .=20 > in xxx on line 4 > -- Matthew Horoschun Network Administrator CanPrint Communications Pty. Ltd. From mhoroschun@canprint.com.au Mon Feb 3 14:41:43 2003 X-Original-To: pgsql-php@postgresql.org Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id 9D5F2475F4F for ; Mon, 3 Feb 2003 09:41:43 -0500 (EST) Received: from mta04ps.bigpond.com (mta04ps.bigpond.com [144.135.25.136]) by postgresql.org (Postfix) with ESMTP id 39E25476063 for ; Mon, 3 Feb 2003 09:30:28 -0500 (EST) Received: from canprint.com.au ([144.135.25.75]) by mta04ps.bigpond.com (Netscape Messaging Server 4.15 mta04ps Jul 16 2002 22:47:55) with SMTP id H9QLMU00.28F; Tue, 4 Feb 2003 00:30:30 +1000 Received: from CPE-203-51-28-152.nsw.bigpond.net.au ([203.51.28.152]) by PSMAM03.mailsvc.email.bigpond.com(MailRouter V3.0n 89/610541); 04 Feb 2003 00:30:30 Date: Tue, 4 Feb 2003 01:30:30 +1100 Subject: Re: what do I wrong??? Content-Type: text/plain; charset=US-ASCII; format=flowed Mime-Version: 1.0 (Apple Message framework v551) Cc: To: =?ISO-8859-1?Q?Borsos_J=F3zsef?= From: Matthew Horoschun In-Reply-To: <009601c2cb8b$09573cc0$790aa3d5@compax> Message-Id: <0BB3FC26-3784-11D7-A8CA-000393B3A702@canprint.com.au> Content-Transfer-Encoding: 7bit X-Mailer: Apple Mail (2.551) X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200302/10 X-Sequence-Number: 1861 > Thank You for answer. > > 1. and 2. I don't no, becouse I'm not administrator on server. > PostgreSQL > server 7.1 and RedHut Linux x.xx > 3. Yes when I connet to the server with SSH client PuTTY for windows. > > My Web server run on Win2000, and PHP code is on IIS 5.0 server. I > mean it > is a problem with crypt() routine. It would be a good idea to contact your system administrator and ask them 1 and 2, otherwise you'll be wasting your time with trial and error. Alternatively, if you have SSH access to the machine then you could try working both out for yourself (do a process listing, see if you have read access to postgresql.conf and pg_hba.conf) How do you know its a problem with the crypt() routine? I can't see how that could be related, unless I'm missing something significant. Matthew. -- Matthew Horoschun Network Administrator CanPrint Communications Pty. Ltd. Mobile: 0417 282 378 Direct: (02) 6295 4544 Telephone: (02) 6295 4422 Facsimile: (02) 6295 4473 From pgsql-php@Borsos.hu Thu Feb 6 13:59:44 2003 X-Original-To: pgsql-php@postgresql.org Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id D5371474E4F for ; Thu, 6 Feb 2003 08:59:44 -0500 (EST) Received: from Piac (www.compax.hu [213.163.10.114]) by postgresql.org (Postfix) with ESMTP id 98FF5474E44 for ; Thu, 6 Feb 2003 08:59:42 -0500 (EST) Received: from [213.163.10.121] by Piac (ArGoSoft Mail Server Pro for WinNT/2000/XP, Version 1.8 (1.8.2.5)); Thu, 6 Feb 2003 14:52:40 +0100 Message-ID: <000e01c2cde8$13b30000$790aa3d5@compax> From: =?iso-8859-2?Q?Borsos_J=F3zsef?= To: "Mileta Vinerte" Cc: References: <000b01c2c3d2$0d80f9a0$790aa3d5@compax> <3E368E04.7060308@cbnco.com> Subject: Re: what do I wrong??? Date: Thu, 6 Feb 2003 15:00:12 +0100 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_000B_01C2CDF0.733CBA40" X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2800.1106 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106 X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200302/31 X-Sequence-Number: 1882 This is a multi-part message in MIME format. ------=_NextPart_000_000B_01C2CDF0.733CBA40 Content-Type: text/plain; charset="iso-8859-2" Content-Transfer-Encoding: quoted-printable ----- Original Message -----=20 From: Mileta Vinerte=20 To: Borsos J=F3zsef=20 Sent: Tuesday, January 28, 2003 3:04 PM Subject: Re: [PHP] what do I wrong??? Hi Jozsef, Ther is my code (db_connect.php): =20=20=20=20=20=20=20=20 Borsos J=F3zsef wrote: $conn_string =3D "host=3Dx.x.x.x port=3D5432 dbname=3Dxxxx user=3DCOMPA= X password=3Dxxxx"; $connect =3D pg_connect($conn_string); RESULT: Warning: pg_connect() [function.pg-connect]: Unable to connect to Postg= reSQL server: Password authentication failed for user 'COMPAX' . in xxx on = line 4 Thanks for helping, but this is the answer: Warning: pg_connect() [function.pg-connect]: Unable to connect to Postgre= SQL server: fe_sendauth: no password supplied . in C:\Inetpub\wwwroot\Borso= s\db_connect.php on line 17 ERROR: Connection to Server failed! ------=_NextPart_000_000B_01C2CDF0.733CBA40 Content-Type: text/html; charset="iso-8859-2" Content-Transfer-Encoding: quoted-printable
 
----- Original Message -----
Fro= m:=20 Mileta= =20 Vinerte
Sent: Tuesday, January 28, 2003 3:= 04=20 PM
Subject: Re: [PHP] what do I=20 wrong???

Hi Jozsef,

Ther is my code=20  (db_connect.php):

<?php
//****************************= *****************************************************
//  &nbs= p;   =20 db_connect.php
//
//      1. Connect to the=20 server
//    2. Connect to the database with the=20 username=3Dpostgres and=20 pw=3Dpostgre$
//
//************************************************= *********************************

$server=3D"172.30.30.27";
$port= =3D"5432";
$db=3D"doors";
$dbusername=3D"postgres";
$dbuserpw=3D"p= ostgre$";

//connect=20 to server
$serverconn =3Dpg_Connect($server,=20 $port,$db);

    if(!$serverconn)
  &nb= sp;=20     {
        echo "ERROR= :=20 Connection to Server failed!";
       = =20 exit;
        }
   =20    
$dbconn =3Dpg_pconnect("dbname=3D$db user=3D$dbuse= rname=20 password=3D$dbuserpw");
       =20
        if(!$dbconn)
  &nb= sp;=20     {
        echo "ERROR= :=20 Connection to Database failed!";
       = =20 exit;
        }
?>  &nbs= p;=20    


Borsos J=F3zsef wrote:
$conn_string =3D "host=3Dx.x.x.x port= =3D5432=20 dbname=3Dxxxx user=3DCOMPAX password=3Dxxxx";
  $connect =3D=20 pg_connect($conn_string);
 
RESULT:
 
Warning: pg_connect()=20 [function.pg-connect]: Unable to connect to Postgre= SQL=20 server: Password authentication failed for user 'COMPAX' . in=20 xxx on line=20 4

 
Thanks for helping, but this is the answer:
 
Warning: pg_connect() [function.pg-connect]:= Unable=20 to connect to PostgreSQL server: fe_sendauth: no password supplied . in= =20 C:\Inetpub\wwwroot\Borsos\db_connect.php on line 17
ERRO= R:=20 Connection to Server failed!
------=_NextPart_000_000B_01C2CDF0.733CBA40--