Re: Error during DBD::Pg install

[email protected] (Darren Duncan)
Newsgroups perl.dbd.pg
Message-ID <[email protected]>
Dennis Daupert wrote:
> I got one error during attempted installation of DBD::Pg.
> 
> Is it safe to do a 'force install' or is there some fix needed?

The failure appears to be that the tests for DBD::Pg need to talk to a Postgres 
database and are getting a permissions error from Postgres.

To make the test suite run, you need to make sure that the port/dbname/user/pass 
which the test suite is using matches up with an actual port/db/user/pass that 
you have.  The Particulars below says that what the test tried was port 5432, a 
db named 'test', a user named 'test', and a passwd named 'testme'.  You need to 
either create that database, or configure the test suite to use a different 
database/user/etc that you already have.  I believe there are docs with DBD::Pg 
that say how to do the latter; it involves either setting environment variables 
or creating a config file, I think.

Running the test suite is not essential to installing DBD::Pg and so you could 
certainly 'force install'; but running the test suite is highly recommended as 
it could root out some potential problems early, whereas otherwise you may just 
discover them when running your own code, even if your own code isn't wrong.

-- Darren Duncan

> Test Summary Report
> -------------------
> t/12placeholders.t (Wstat: 256 Tests: 235 Failed: 1)
>   Failed test:  113
>   Non-zero exit status: 1:
> Files=15, Tests=1698, 15 wallclock secs ( 0.27 usr  0.13 sys +  1.76 cusr
> 0.54 csys =  2.70 CPU)
> Result: FAIL
> Failed 1/15 test programs. 1/1698 subtests failed.
> make: *** [test_dynamic] Error 255
> 
> Particularrs:
> 
> # DBI                         Version 1.607
> # DBD::Pg                     Version 2.15.1
> # Perl                        Version 5.10.0
> # OS                          linux
> # PostgreSQL (compiled)       80307
> # PostgreSQL (target)         80307
> # PostgreSQL (reported)       PostgreSQL 8.3.7 on x86_64-pc-linux-gnu,
> compiled by GCC gcc-4.3.real (Ubuntu 4.3.3-5ubuntu4) 4.3.3
> # Default port                5432
> # DBI_DSN                     dbi:Pg:db="test"
> # DBI_USER                    test
> # Test schema                 dbd_pg_testschema
> # PGDATABASE                  test
> # PGPASSWORD                  testme
> # PGUSER                      test
> # LANG                        en_CA.UTF-8
> # array_nulls                 on
> # backslash_quote             safe_encoding
> # client_encoding             UTF8
> # server_encoding             UTF8
> # standard_conforming_strings off
> 
> #   Failed test 'Prepare works with placeholders after double slashes'
> #   at t/12placeholders.t line 516.
> #          got: 'DBD::Pg::db do failed: ERROR:  permission denied for
> schema pg_catalog at t/12placeholders.t line 511.
> # '
> #     expected: ''
> # Looks like you failed 1 test of 235.:
> t/12placeholders.t .. Dubious, test returned 1 (wstat 256, 0x100)
> Failed 1/235 subtests
> t/20savepoints.t .... ok
> t/99cleanup.t ....... 1/1 Removing test database directory
> t/99cleanup.t ....... ok
> 
> 
> best,
> 
>  /dennis
> 
> ------------------------------------------------
> Dennis Daupert, PhD
> Senior Systems Development Professional -- CSC Account
> CSC
> 
> GOS | o: 1.317.298.9499 | [email protected] | www.csc.com
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.