Обсуждение: Need help for installation of PostgreSQl

Поиск
Список
Период
Сортировка

Need help for installation of PostgreSQl

От
xuan luo
Дата:
Hello  pgsql maintainer,
 
I want to install PostgreSQL to my computer, but I get error message as below:
 
creating template1 database in /usr/share/postgresql/data/base/1... IpcSemapho
Create: semget(key=1, num=17, 03600) failed: Function not implemented
initdb failed.
Removing /usr/share/postgresql/data.
 
In the message, it let me remove /usr/share/postgresql/data. However, there is no data folder under /usr/share/postgresql/.
 
Below are my installation procedure:
 
Prepare:
1. Download setup.exe (for cygwin1.5).
2. Run setup.exe to get Cygwin (root directory).
3. Download Cygipc and copy it to root Cygwin directory.
and
Install:
1. # ipc-daemon2  --install-as-service
 
2. # net  user  postgres  $password  /add  /fullname:postgres  /comment:'PostgreSQL  user  account'  /homedir:"$(cygpath  -w  /hom/postgres)"  #
 
3. # mkpasswd  -l  -u  postgres  >>/etc/passwd
 
4. # cmd  /c  secpol.msc  #
 
5. # cygrunsrv  --install  postmaster  --path  /usr/bin/postmaster  --args  "-D  /usr/share/postgresql/data  -i"  --dep  ipc-daemon2  --termsig  INT  --user  postgres  --shutdown  #
 
6. # mkdir  /usr/share/postgresql/data
 
7. # chown  postgres  /usr/share/postgresql/data  #
 
8. # net  start  ipc-daemon2  #
 
9.  initdb  -D  /usr/share/postgresql/data
 
 
Problem is here:
creating template1 database in /usr/shar
Create: semget(key=1, num=17, 03600) fai
initdb failed.
Removing /usr/share/postgresql/data.
 
I can't even go down to
10. # net  start  postmaster  #
 and
11. # psql  -U  postgres  template1  #
 
 
I tried to delete Cygwin folder many times and re-install, but is doesn't work.  I really need you to point how to solve the problem. In the user guide, the problem is listed there, but there is no solution.
 
Could you please help?
 
Thanks and regards,
 
Rose

postmaster clean shutdown

От
"Chris Faulkner"
Дата:
Hello all

ON a couple of occasions, when I have rebooted my machine, postmaster has
not shutdown cleanly. So on restart, postmaster does not start because the
old .pid and /tmp/.s Lock files are in place.

I have cygwin IPC daemon 2 and that looks OK.

This does not happen all the time - it is very rare but quite a nuisance
when it does.

Has anyone else found this ? Or does anyone have a good general solution ?


Thanks


Chris Faulkner



Re: Need help for installation of PostgreSQl

От
Marsh Ray
Дата:
xuan luo wrote:

> 2. # net  user  postgres  $password  /add  /fullname:postgres
> /comment:'PostgreSQL  user  account'  /homedir:"$(cygpath  -w
> /hom/postgres)"  #

Did you mean "/home/postgres" ?

I assume you've seen:
http://www.postgresql.org/docs/faqs/text/FAQ_MSWIN

Are you on Windows XP Home?
http://archives.postgresql.org/pgsql-cygwin/2003-01/msg00068.php

Also, I had to add a password to the user for the service.

- Marsh