Обсуждение: postgres perl DBI
I'm having issues with installing the postgres DBI for perl. Here is the output of make test and a verification postmaster is running: [~/DBD-Pg-0.95] dmfetter@mwabs505! make test PERL_DL_NONLAZY=1 /usr/local/bin/perl -Iblib/arch -Iblib/lib -I/usr/local/lib/perl5/5.00503/sun4-solaris -I/usr/local/lib/perl5/5.00503 test.pl OS: solaris Use of uninitialized value at test.pl line 53. DBI->data_sources .......... not ok: DBI->connect(dbname=template1) failed: PQconnectPoll() -- connect() failed: Connection refused Is the postmaster running (with -i) at 'mwabs504' and accepting connections on TCP/IP port '5432'? at test.pl line 59 DBI->connect ............... not ok: PQconnectPoll() -- connect() failed: Connection refused Is the postmaster running (with -i) at 'mwabs504' and accepting connections on TCP/IP port '5432'? make: *** [test_dynamic] Error 255 [~/DBD-Pg-0.95] dmfetter@mwabs505! ps -ef|grep post dmfetter 24865 24254 0 21:35:38 pts/5 0:00 grep post postgres 23964 1 0 17:31:28 ? 0:00 /usr/local/postgres/bin/postmaster -S -i Does anyone have any suggestions for me to try so I can fix this? Thank you, David M. Fetter 503.450.6609 UNIX System Analyst Emery World Wide "It has become appallingly clear that our technology has surpassed our humanity." - Albert Einstein
Вложения
"Fetter, David M" wrote: > I'm having issues with installing the postgres DBI for perl. Here is the > output of make test and a verification postmaster is running: > > [~/DBD-Pg-0.95] dmfetter@mwabs505! make test > PERL_DL_NONLAZY=1 /usr/local/bin/perl -Iblib/arch -Iblib/lib > -I/usr/local/lib/perl5/5.00503/sun4-solaris -I/usr/local/lib/perl5/5.00503 > test.pl > OS: solaris > Use of uninitialized value at test.pl line 53. > DBI->data_sources .......... not ok: > DBI->connect(dbname=template1) failed: PQconnectPoll() -- connect() failed: > Connection refused > Is the postmaster running (with -i) at 'mwabs504' > and accepting connections on TCP/IP port '5432'? > at test.pl line 59 Is the postmaster running? Do you run the make test routine with a user who can access the database. Try the same with the postgres user. I usually do only the make install step as root. Regards Herbie -- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Herbert Liechti E-Mail: Herbert.Liechti@thinx.ch ThinX networked business services Stahlrain 10, CH-5200 Brugg ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
"Fetter, David M" <Fetter.David@emeryworld.com> writes: > DBI->connect(dbname=template1) failed: PQconnectPoll() -- connect() failed: > Connection refused > Is the postmaster running (with -i) at 'mwabs504' > and accepting connections on TCP/IP port '5432'? > at test.pl line 59 "Connection refused" at this stage generally means that the connect request never got as far as the postmaster. Are you sure you are connecting to the right machine? Your script > [~/DBD-Pg-0.95] dmfetter@mwabs505! ps -ef|grep post > dmfetter 24865 24254 0 21:35:38 pts/5 0:00 grep post > postgres 23964 1 0 17:31:28 ? 0:00 > /usr/local/postgres/bin/postmaster -S -i suggests you are on mwabs505 not mwabs504. regards, tom lane
Silly me, I didn't even notice the mwabs504/505 difference. I had my .profile setup for another machine. It compiled fine now. Thanks. -----Original Message----- From: Tom Lane [mailto:tgl@sss.pgh.pa.us] Sent: Monday, July 31, 2000 6:30 PM To: Fetter, David M Cc: PostgreSQL-General (E-mail) Subject: Re: [GENERAL] postgres perl DBI "Fetter, David M" <Fetter.David@emeryworld.com> writes: > DBI->connect(dbname=template1) failed: PQconnectPoll() -- connect() failed: > Connection refused > Is the postmaster running (with -i) at 'mwabs504' > and accepting connections on TCP/IP port '5432'? > at test.pl line 59 "Connection refused" at this stage generally means that the connect request never got as far as the postmaster. Are you sure you are connecting to the right machine? Your script > [~/DBD-Pg-0.95] dmfetter@mwabs505! ps -ef|grep post > dmfetter 24865 24254 0 21:35:38 pts/5 0:00 grep post > postgres 23964 1 0 17:31:28 ? 0:00 > /usr/local/postgres/bin/postmaster -S -i suggests you are on mwabs505 not mwabs504. regards, tom lane