Thread: did freese in creating a database cluster

did freese in creating a database cluster

From
Tsutomu Nakajima
Date:
Hello, PostGreSQL-Masters

<<System>>
PostGreSQL: 7.4.30 the postgres-installer ( postgresql-7.4.30.tar.gz) 
OS: AIXv5.2 TL09 (POWER5)
Machine: 9119-590(1LPAR)

<<Status>>
I have got the following status or problem with an initdb command,
which is "initdb -D /usr/local/pgsql/data -d".
The point of "selecting default max_connections..." did freeze,
and the status is the same although I have waited for 24 hours.

<<Question>>
1. What was the situation happend in creating a database cluster?
2. Would you please give me solution or workaround for this status?

<<In Details>>
[postgres:/home/pp/postgres]initdb -D /usr/local/pgsql/data -d
Running in debug mode.

initdb: internal variables:
  PGDATA=/usr/local/pgsql/data
  datadir=/usr/local/pgsql/share
  PGPATH=/usr/local/pgsql/bin
  ENCODING=
  ENCODINGID=0
  POSTGRES_SUPERUSERNAME=postgres
  POSTGRES_BKI=/usr/local/pgsql/share/postgres.bki
  POSTGRES_DESCR=/usr/local/pgsql/share/postgres.description
  POSTGRESQL_CONF_SAMPLE=/usr/local/pgsql/share/postgresql.conf.sample
  PG_HBA_SAMPLE=/usr/local/pgsql/share/pg_hba.conf.sample
  PG_IDENT_SAMPLE=/usr/local/pgsql/share/pg_ident.conf.sample
The files belonging to this database system will be owned by user "postgres".
This user must also own the server process.

The database cluster will be initialized with locales:
  COLLATE:  C
  CTYPE:    C
  MESSAGES:
  MONETARY: C
  NUMERIC:  C
  TIME:     C

fixing permissions on existing directory /usr/local/pgsql/data... ok
creating directory /usr/local/pgsql/data/base... ok
creating directory /usr/local/pgsql/data/global... ok
creating directory /usr/local/pgsql/data/pg_xlog... ok
creating directory /usr/local/pgsql/data/pg_clog... ok
selecting default max_connections...



Regards
Tsutomu

Re: did freese in creating a database cluster

From
Tsutomu Nakajima
Date:
I add the information of freeze status in creating a database cluster.
The info is that the following process exists.

postgres 1331432  708812   0 11:08:31 pts/10  0:00 /bin/sh /usr/local/pgsql/bin/initdb -D /usr/local/pgsql/data -d
postgres 1347694 1331432 120 11:08:32 pts/10  0:05 /usr/local/pgsql/bin/postgres -boot -x0 -F -D/usr/local/pgsql/data -c shared_buffers=500 -c max_connections=100 template1
* TIME is now.

Regard
Tsutomu


> <<System>>
> PostGreSQL: 7.4.30 the postgres-installer ( postgresql-7.4.30.tar.gz)
> OS: AIXv5.2 TL09 (POWER5)
> Machine: 9119-590(1LPAR)

> <<Status>>
> I have got the following status or problem with an initdb command,
> which is "initdb -D /usr/local/pgsql/data -d".
> The point of "selecting default max_connections..." did freeze,
> and the status is the same although I have waited for 24 hours.

> <<Question>>
> 1. What was the situation happend in creating a database cluster?
> 2. Would you please give me solution or workaround for this status?

> <<In Details>>
> [postgres:/home/pp/postgres]initdb -D /usr/local/pgsql/data -d
> Running in debug mode.

> initdb: internal variables:
>   PGDATA=/usr/local/pgsql/data
>   datadir=/usr/local/pgsql/share
>   PGPATH=/usr/local/pgsql/bin
>   ENCODING=
>   ENCODINGID=0
>   POSTGRES_SUPERUSERNAME=postgres
>   POSTGRES_BKI=/usr/local/pgsql/share/postgres.bki
>   POSTGRES_DESCR=/usr/local/pgsql/share/postgres.description
>   POSTGRESQL_CONF_SAMPLE=/usr/local/pgsql/share/postgresql.conf.sample
>   PG_HBA_SAMPLE=/usr/local/pgsql/share/pg_hba.conf.sample
>   PG_IDENT_SAMPLE=/usr/local/pgsql/share/pg_ident.conf.sample
> The files belonging to this database system will be owned by user
> "postgres".
> This user must also own the server process.

> The database cluster will be initialized with locales:
>   COLLATE:  C
>   CTYPE:    C
>   MESSAGES:
>   MONETARY: C
>   NUMERIC:  C
>   TIME:     C
>
> fixing permissions on existing directory /usr/local/pgsql/data... ok
> creating directory /usr/local/pgsql/data/base... ok
> creating directory /usr/local/pgsql/data/global... ok
> creating directory /usr/local/pgsql/data/pg_xlog... ok
> creating directory /usr/local/pgsql/data/pg_clog... ok
> selecting default max_connections...


Re: did freese in creating a database cluster

From
Fujii Masao
Date:
On Tue, Dec 28, 2010 at 11:21 AM, Tsutomu Nakajima <ns1090156@gmail.com> wrote:
> I add the information of freeze status in creating a database cluster.
> The info is that the following process exists.
>
> postgres 1331432  708812   0 11:08:31 pts/10  0:00 /bin/sh
> /usr/local/pgsql/bin/initdb -D /usr/local/pgsql/data -d
> postgres 1347694 1331432 120 11:08:32 pts/10  0:05
> /usr/local/pgsql/bin/postgres -boot -x0 -F -D/usr/local/pgsql/data -c
> shared_buffers=500 -c max_connections=100 template1
> * TIME is now.

Though I'm not sure what the cause is, I recommend you to upgrade
your database since 7.4 is already end-of-life.

Regards,

--
Fujii Masao
NIPPON TELEGRAPH AND TELEPHONE CORPORATION
NTT Open Source Software Center

Re: did freese in creating a database cluster

From
Gurjeet Singh
Date:
On Mon, Dec 27, 2010 at 11:05 PM, Fujii Masao <masao.fujii@gmail.com> wrote:
On Tue, Dec 28, 2010 at 11:21 AM, Tsutomu Nakajima <ns1090156@gmail.com> wrote:
> I add the information of freeze status in creating a database cluster.
> The info is that the following process exists.
>
> postgres 1331432  708812   0 11:08:31 pts/10  0:00 /bin/sh
> /usr/local/pgsql/bin/initdb -D /usr/local/pgsql/data -d
> postgres 1347694 1331432 120 11:08:32 pts/10  0:05
> /usr/local/pgsql/bin/postgres -boot -x0 -F -D/usr/local/pgsql/data -c
> shared_buffers=500 -c max_connections=100 template1
> * TIME is now.

Though I'm not sure what the cause is, I recommend you to upgrade
your database since 7.4 is already end-of-life.


Yeah, looks like you are creating a fresh  database so it is highly recommended to use the latest version of Postgres, say 9.0 or maybe 8.4.

Regards,

--
gurjeet.singh
@ EnterpriseDB - The Enterprise Postgres Company
http://www.EnterpriseDB.com

singh.gurjeet@{ gmail | yahoo }.com
Twitter/Skype: singh_gurjeet

Mail sent from my BlackLaptop device

Re: did freese in creating a database cluster

From
John R Pierce
Date:
On 12/27/10 6:21 PM, Tsutomu Nakajima wrote:
> >  <<System>>
> >  PostGreSQL: 7.4.30 the postgres-installer ( postgresql-7.4.30.tar.gz)
> >  OS: AIXv5.2 TL09 (POWER5)
> >  Machine: 9119-590(1LPAR)

as others have said, 7.4 is really really old and completely at end of
life, and should certainly not be used for new projects.

I have had no problems building and running PostgreSQL 8.4.5 on AIX 5.3L
and 6.1, on Power 5 and 6 gear, using IBM XL C for AIX v11.1

to build 8.4, I first built zlib 1.2.5 and readline 6.1 as static
libraries, built in my compile user's $HOME/src/* tree.

my build environment is...

   export
PATH=/usr/bin:/etc:/usr/sbin:/usr/ucb:/home/postgres/bin:/usr/bin/X11:/sbin
   export CC=/usr/vacpp/bin/xlc


zlib build:
   $  CFLAGS="-q64" AR="/usr/bin/ar -X64" ./configure --prefix=$HOME/src
--64 --static && gmake && gmake install

readline build:
   $ CC=/usr/vacpp/bin/xlc CFLAGS="-q64 -I$HOME/src/include"
LDFLAGS="-L$HOME/src/lib" AR="/usr/bin/ar" ./configure
--prefix=$HOME/src && gmake && gmake install

then I built postgres via...
   $ CC=/usr/vacpp/bin/xlc CFLAGS="-q64 -I$HOME/src/include -O2
-qarch=pwr5 -qtune=balanced" LDFLAGS="-L$HOME/src/lib" AR="/usr/bin/ar" .
/configure --prefix=/opt/pgsql84 && gmake && gmake test && sudo gmake
install



then, as the postgres user, I setup...

$ export PGDATA=/u10/pgsql/data
$ export
PATH=/usr/bin:/etc:/usr/sbin:/usr/ucb:/home/postgres/bin:/usr/bin/X11:/sbin:/opt/pgsql84/bin

(I have the above in the PG user's .profile, actually)

$ initdb -E UTF8

and it ran in at most a couple seconds on a Power 520.




Re: did freese in creating a database cluster

From
Tsutomu Nakajima
Date:
Thank you for responsing the problem.
Although you suggested, I had needed to prepare for version7 on AIX 5.2L.

Thus, i tried to build v7.4.6 not v7.4.30, and it was successfly. Thanks.

           Tsutomu