LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   can't installing Postgresql (https://www.linuxquestions.org/questions/linux-software-2/cant-installing-postgresql-45113/)

importboy03 02-12-2003 04:10 PM

can't installing Postgresql
 
When I try to install Postgesql, I got this message:
[root@localhost root]# rpm -iv postgresql-7.2.2*
warning: postgresql-7.2.2-1.i386.rpm: V3 DSA signature: NOKEY, key ID db42a60e
error: Failed dependencies:
postgresql-libs = 7.2.2 is needed by postgresql-7.2.2-1
libpq.so.2 is needed by postgresql-7.2.2-1

any idea?

Tinkster 02-12-2003 04:17 PM

Install postgresql libs first? :)

cheers,
Tink

importboy03 02-12-2003 05:25 PM

got it, thanks

importboy03 02-13-2003 11:54 AM

After installation, I can't find any files associated with the postgresql. Does anybody know how to start the db? I got this error when running the 'psql' command:

psql: could not connect to server: No such file or directory
Is the server running locally and accepting
connections on Unix domain socket "/tmp/.s.PGSQL.5432"?

How do I fix this problem and start the db? In addition, I like to access the db with JDBC. I read the doc on the postgresql.com and still don't understand how to communicate with the db. I already installed JDBC driver, but I don't know how to test it. BTW, I'm planning using JSP application for this db.

Tinkster 02-13-2003 01:28 PM

You sure you read the docs? :)
They are quite straight forward ...

Check whether postgresql starts is up & running
Code:

ps -A | grep postmaster
If it's not, do:
Code:

su - postgres
pg_ctl start

Cheers,
Tink

importboy03 02-13-2003 01:56 PM

got it it running finally. I found a differnet doc from http://www.opennet.ru/docs/HOWTO/Pos...-6.html#ss6.1.
that help me. The reason is that I must install all packages of postgresql. I didn't install postgresql-server-7.2.2-1.i386.rpm at the time. Oh, I don't understand why I must switch user to postgres without adding postgres user. I installed it with root. Is this mean I have to use postgres user everytime I want to work with the db?

Tinkster 02-13-2003 02:21 PM

I have never installed Postgres from RPM's,
so wouldn't know what the makers of an RPM
do to it ...

The default is *not* to run postmaster from
user root (security measures, I believe)

What one is supposed to do is to create an
entry in rc.local that starts the dbm as user
postgres.

And know, you don't have to su to postgres to
use the database :)

Cheers,
Tink


All times are GMT -5. The time now is 03:47 AM.