LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Postgres Intallation on drake 10.1 (https://www.linuxquestions.org/questions/linux-newbie-8/postgres-intallation-on-drake-10-1-a-267092/)

alejandroye 12-16-2004 11:56 AM

Postgres Intallation on drake 10.1
 
Hello all

I just installed drake 10.1 and I tried to install postgres unknowing that came w/the distro, so I downloaded from the website and I folowed the instructions

I run ./configure and showed me:

checking build system type... i686-pc-linux-gnu
checking host system type... i686-pc-linux-gnu
checking which template to use... linux
checking whether to build with 64-bit integer date/time support... no
checking whether NLS is wanted... no
checking for default port number... 5432
checking for gcc... gcc
checking for C compiler default output... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking how to turn off strict aliasing in gcc... -fno-strict-aliasing
configure: using CFLAGS=-O2 -fno-strict-aliasing
checking whether the C compiler still works... yes
checking how to run the C preprocessor... gcc -E
checking allow thread-safe client libraries... no
checking whether to build with Tcl... no
checking whether to build with Tk... no
checking whether to build Perl modules... no
checking whether to build Python modules... no
checking whether to build Java/JDBC tools... no
checking whether to build with Kerberos 4 support... no
checking whether to build with Kerberos 5 support... no
checking whether to build with PAM support... no
checking whether to build with Rendezvous support... no
configure: using CPPFLAGS=-D_GNU_SOURCE
configure: using LDFLAGS=
checking for gawk... gawk
checking for flex... no
configure: WARNING:
*** Without Flex you will not be able to build PostgreSQL from CVS or
*** change any of the scanner definition files. You can obtain Flex from
*** a GNU mirror site. (If you are using the official distribution of
*** PostgreSQL then you do not need to worry about this because the Flex
*** output is pre-generated.)
checking whether ln -s works... yes
checking for ld used by GCC... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for ranlib... ranlib
checking for lorder... no
checking for tar... /bin/tar
checking for strip... strip
checking whether it is possible to strip libraries... yes
checking for bison... no
configure: WARNING:
*** Without Bison you will not be able to build PostgreSQL from CVS or
*** change any of the parser definition files. You can obtain Bison from
*** a GNU mirror site. (If you are using the official distribution of
*** PostgreSQL then you do not need to worry about this because the Bison
*** output is pre-generated.) To use a different yacc program (possible,
*** but not recommended), set the environment variable YACC before running
*** 'configure'.
checking for perl... /usr/bin/perl
checking for main in -lbsd... yes
checking for setproctitle in -lutil... no
checking for main in -lm... yes
checking for main in -ldl... yes
checking for main in -lnsl... yes
checking for main in -lsocket... no
checking for main in -lipc... no
checking for main in -lIPC... no
checking for main in -llc... no
checking for main in -ldld... no
checking for main in -lld... no
checking for main in -lcompat... no
checking for main in -lBSD... no
checking for main in -lgen... no
checking for main in -lPW... no
checking for main in -lresolv... yes
checking for library containing getopt_long... none required
checking for main in -lunix... no
checking for library containing crypt... -lcrypt
checking for library containing fdatasync... none required
checking for shmget in -lcygipc... no
checking for readline... no
configure: error: readline library not found
If you have readline already installed, see config.log for details on the
failure. It is possible the compiler isn't looking in the proper directory.
Use --without-readline to disable readline support.

what I suppose to do now, because after this I tried to do gmake and I got

You need to run the 'configure' program first. See the file
'INSTALL' for installation instructions.
gmake: *** [all] Error 1
[root@localhost postgresql-


what I have to do if postgres is already installed, how can start using postmaster and createdb?
somebody can help me

Also I test the following comands

createdb music
createdb: could not connect to database template1: FATAL: user "root" does not exist

postmaster
"root" execution of the PostgreSQL server is not permitted.
The server must be started under an unprivileged user ID to prevent
possible system security compromise. See the documentation for
more information on how to properly start the server.

initdb -D
initdb: cannot be run as root
Please log in (using, e.g., "su") as the (unprivileged) user that will
own the server process.


:newbie:


thanks you

michaelk 12-16-2004 12:18 PM

If postgresql is already installed then use Mandrake Control Center to start the service.

Use su to log on as the postgresql user. Login as root and then
su postgres

You can then initialize the database i.e. using initdb.
Add your regular user to postgresql
createuser username

Replace usernname with your real user name

Exit back and login as your regular user.
You can then create databases and use the psql frontend.

Documentation:
http://www.postgresql.org/docs/7.4/i...ive/index.html

alejandroye 12-16-2004 04:13 PM

that is the problem that I have, How can I be sure that postgres is in the system? and why I am having those error above

I tried run "service --status-all" and I check that postmaster is running
postmaster (pid 3334 3333 3329) is running...

that mean taht I have postgres in the system, how can I check whether it is

thanks

Tinkster 12-16-2004 04:40 PM

Well ... if configure failed you can't have run a
make && make install ... if postmaster is running
postgres MUST be installed by other means ...

do a
ps -ef | grep postmaster
to see where it lives


Cheers,
Tink

alejandroye 12-17-2004 08:46 AM

Yes, I did ps -ef | grep postmaster and I got

postgres 3329 1 0 Dec08 ? 00:00:01 /usr/bin/postmaster -p 5432 -D /var/lib/pgsql/data
root 26653 26194 0 09:32 pts/4 00:00:00 grep postmaster

this mean that posgres is running?


if not, Now what?, somebody help me ?

michaelk 12-17-2004 10:26 AM

See my previous post

alejandroye 12-17-2004 12:21 PM

:rolleyes: sorry and thanks you michaelk, but sometime being NEWBIE need more explanation as answer the simple question

" yes, you have postgres installed and do
=============
Use su to log on as the postgresql user. Login as root and then
su postgres

You can then initialize the database i.e. using initdb.
Add your regular user to postgresql
createuser username

Replace usernname with your real user name

Exit back and login as your regular user.
You can then create databases and use the psql frontend.
================
it will more helpfull :D

thank you again, this tip help me a lot and I realized where I was stood


All times are GMT -5. The time now is 09:22 AM.