Re: DB Error: connect failed

Поиск
Список
Период
Сортировка
От Rodolfo J. Paiz
Тема Re: DB Error: connect failed
Дата
Msg-id 1107409752.5201.18.camel@localhost.localdomain
обсуждение исходный текст
Ответ на DB Error: connect failed  ("Rodolfo J. Paiz" <rpaiz@simpaticus.com>)
Ответы Re: DB Error: connect failed  ("Rodolfo J. Paiz" <rpaiz@simpaticus.com>)
Re: DB Error: connect failed  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-novice
On Wed, 2005-02-02 at 23:33 -0600, Rodolfo J. Paiz wrote:
> What gets me is that *all* I get is
> that one "DB Error: connect failed" error.

Well, sorry to reply to my own post but I've got a little more detail
now. I modified my web page with this (straight from the PEAR manual):

    if (DB::isError($db)) {
    /*
     * This is not what you would really want to do in
     * your program.  It merely demonstrates what kinds
     * of data you can get back from error objects.
     */
    echo 'Standard Message: ' . $db->getMessage() . "<br>";
    echo 'Standard Code: ' . $db->getCode() . "<br>";
    echo 'DBMS/User Message: ' . $db->getUserInfo() . "<br>";
    echo 'DBMS/Debug Message: ' . $db->getDebugInfo() . "<br>";
 #   exit;
}

Now I get this as an error message:

Standard Message: DB Error: connect failed
Standard Code: -24
DBMS/User Message: [nativecode=Unable to connect to PostgreSQL server:
could not connect to server: Connection refused Is the server running on
host localhost and accepting TCP/IP connections on port 5432?] ** Array
DBMS/Debug Message: [nativecode=Unable to connect to PostgreSQL server:
could not connect to server: Connection refused Is the server running on
host localhost and accepting TCP/IP connections on port 5432?] ** Array

I do know the database is running, as I can use it with both psql and
phpPgAdmin. So, just the web page fails. Now to figure out how.

It is worth mentioning that the server is set up to IDENT users, so I
cannot log in as user "simpatic" and use psql as simpatic_www. Fails.
For perhaps the same or other reasons, phpPgAdmin also fails the
simpatic_www user... not sure why. So I cannot be 100% certain that the
user/pass of simpatic_www is correct. But it should be.

Thanks for any hints,

--
Rodolfo J. Paiz <rpaiz@simpaticus.com>


В списке pgsql-novice по дате отправления:

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: Re: [HACKERS] Last ID Problem
Следующее
От: Michael Glaesemann
Дата:
Сообщение: Re: Batch Insert tables