Re: Postmaster Vr. 7.4.5 don't start on Cygwin 1.5.18
"Robson Richieri" <[email protected]> Thu, 20 Oct 2005 12:39:52 -0200
| Newsgroups | gmane.comp.db.postgresql.cygwin |
|---|---|
| Message-ID | <009d01c5d584$22c91510$8300a8c0@Robson> |
This is a multi-part message in MIME format.
------=_NextPart_000_009A_01C5D573.5DDAC1A0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
If anyone else has the same problem, I myself found out a solution =
reading other messages in this user list and I hope this can help them. =
Here are the steps I did in order to bring to life PostgreSql 7.4.5 that =
was not working on Cygwin 1.5.18.
I downloaded a snapshot (2005-Oct-19) of DLL cygwin from
http://cygwin.com/snapshots/=20
and installed the following files:
cygwin1-20051019.dll.bz2 (in /bin directory)
cygwin-inst-20051019.tar.bz2 (in their respective /usr sub-directories)
Then, I repeated only the first, 7th and 8th steps described in =
"postgresql-7.4.5.README" document, which install and start the =
cygserver as a NT service and initialize postgresql, since the other =
steps were valid from the previous installation (I already had a =
"postgres" user account and also the postmaster as a NT service =
installed).
At this time, I realized I could run under the "postgres" account using =
the command below on a DOS window prompt:
RunAs /user:postgres "C:\Cygwin\cygwin.bat"
As a "postgres" account, I could empty the directory =
/var/postgresql/data to initialize PostgreSQL cleanly:
initdb -D /var/postgresql/data
as described at step 8 of that document. I tried to start postmaster =
using "cygrunsrv -S postmaster", but it did not work. So, I tried the =
command (either as a "postgres" account):
/bin/pg_ctl start -D /var/postgresql/data -l =
/var/postgresql/data/postmaster.log
and "voil=E1", postmaster started running!
Using command:
psql -l
I could verify that it was ok:
List of databases
Name | Owner | Encoding
------------------+-----------------+---------------------
template0 | postgres | SQL_ASCII
template1 | postgres | SQL_ASCII
Thanks a lot to Vladimir Tsvetkov and other guys from this list for =
their suggestions, and excuse me all for this too long message
(I like to explain in details!!!).
Robson Richieri.
----- Original Message -----=20
From: Robson Richieri=20
To: [email protected]=20
Sent: Thursday, August 04, 2005 1:15 PM
Subject: Postmaster Vr. 7.4.5 don't start on Cygwin 1.5.18
Hi, could anyone help me?
I upgrade Cygwin (the old version run Postgres 7.1.2 with no problem, =
using ipc-daemon) and followed the steps conform document =
"postgresql-7.4.5.README" v 1.56 2004/06/26 14:13:29.
I tried to install PostgreSQL type NT services under Win2000. From =
step 1 to 7, everything worked fine. At step 8, I had to login on =
Windows with user name "postgres" and the password I had determined when =
I created the "postgres" user account (step 2), because I could NOT =
simulate command "su" on Cygwin (I didn't have a service to authenticate =
ssh conection, nor the command "RunAs" worked well: it always reported =
that the user or password was invalid!).
NOTE 1: my computer runs Win2000 on a private network with a Linux =
Server running Samba as a PDC (Primary Domain Controller). So, at this =
point, I logged the user "postgres" out of the domain, that is, I set up =
the domain as my local machine.
Ok, "initdb" finished succesfully. But, when I run the command on =
step 9 "cygrunsrv -S postmaster", after some time it returns the =
following error:
cygrunsrv: Error starting a service: QueryServiceStatus: Win32 error =
1053: the service did not answer to initial or control request on time=20
NOTE 2: after the number 1053 above, the translation is mine since the =
description of the error is in portuguese; sorry for incorrections.
When I looked at the window "Services" from Admin Tools of Windows, it =
showed a line "postmaster" with the status "starting". And this service =
only could be stopped using the Task Manager of Windows by means of =
selecting the corresponding cygrunsrv process and forcing its stop. The =
use of option "-E" of cygrunsrv process did not work for the same =
reason: a time-out error!
Finally, the command on step 10 "cygrunsrv -Q postmaster" given before =
the stopping of the service, displayed the information bellow:
Service : postmaster
Current State : Start Pending <<<---- ?!
Controls Accepted : Stop, Shutdown
Command : /usr/bin/postmaster -D /var/postgresql/data -i
The Cygwin itself works very well, so what's wrong with PostgreSQL? I =
apreciate if anybody could help me to solve this problem.
Thanks, very much!
Robson Richieri
[email protected]
------=_NextPart_000_009A_01C5D573.5DDAC1A0
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2800.1515" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>If anyone else has the same problem, I =
myself found=20
out a solution reading other messages in this user list and I hope =
this can=20
help them. Here are the steps I did in order to bring to life PostgreSql =
7.4.5 that was not working on Cygwin 1.5.18.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>I downloaded a snapshot =
(2005-Oct-19) of DLL=20
cygwin from</FONT></DIV>
<DIV><FONT face=3DArial size=3D2><A=20
href=3D"http://cygwin.com/snapshots/">http://cygwin.com/snapshots/</A>&nb=
sp;</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>and installed the=20
following files:</FONT></DIV>
<DIV><FONT><FONT face=3DArial =
size=3D2><EM></EM></FONT></FONT> </DIV>
<DIV><FONT><FONT face=3DArial=20
size=3D2><EM>cygwin1-20051019.dll.bz2</EM> &=
nbsp; (in=20
/bin directory)</FONT></FONT></DIV>
<DIV><FONT face=3DArial=20
size=3D2><EM>cygwin-inst-20051019.tar.bz2</EM> (in their =
respective=20
/usr sub-directories)</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>Then, I repeated only the =
first, 7th and=20
8th steps described in "postgresql-7.4.5.README" document, =
which=20
install and start the cygserver as a NT service and initialize =
postgresql,=20
since the other steps were valid from the previous installation (I =
already had a=20
"postgres" user account and also the postmaster as a NT service=20
installed).</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>At this time, I realized I could run =
under the=20
"postgres" account using the command below on a DOS window =
prompt:</FONT></DIV>
<DIV><FONT face=3DArial size=3D2><EM></EM></FONT> </DIV>
<DIV><FONT face=3DArial><EM>RunAs /user:postgres=20
"C:\Cygwin\cygwin.bat"</EM></FONT></DIV>
<DIV><FONT face=3D"Courier New"></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>As a "postgres" account, I could empty =
the=20
directory /var/postgresql/data to initialize PostgreSQL =
cleanly:</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial><EM>initdb -D =
/var/postgresql/data</EM></FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>as described at step 8 of =
that document. I=20
tried to start postmaster using "cygrunsrv -S postmaster", but it did =
not work.=20
So, I tried the command (either as a "postgres" account):</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial><EM>/bin/pg_ctl start -D /var/postgresql/data -l =
/var/postgresql/data/postmaster.log</EM></FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>and "voil=E1", postmaster started=20
running!</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>Using command:</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial><EM>psql -l</EM></FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>I could verify that it was =
ok:</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT=20
face=3DArial> =
=20
List of databases</FONT></DIV>
<DIV><FONT face=3DArial> =20
Name | =
Owner | Encoding</FONT></DIV>
<DIV><FONT=20
face=3DArial>------------------+-----------------+---------------------</=
FONT></DIV>
<DIV><FONT face=3DArial> template0 =
| =20
postgres | SQL_ASCII</FONT></DIV>
<DIV><FONT face=3DArial> template1 =
| =20
postgres | SQL_ASCII</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>Thanks a lot to Vladimir Tsvetkov and =
other guys=20
from this list for their suggestions, and excuse me all for this =
too long=20
message</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>(I like to explain in =
details!!!).</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>Robson Richieri.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV>----- Original Message ----- </DIV>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV=20
style=3D"BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: =
black"><B>From:</B>=20
<A [email protected] =
href=3D"mailto:[email protected]">Robson=20
Richieri</A> </DIV>
<DIV style=3D"FONT: 10pt arial"><B>To:</B> <A=20
[email protected]=20
=
href=3D"mailto:[email protected]">pgsql-cygwin-owner@post=
gresql.org</A>=20
</DIV>
<DIV style=3D"FONT: 10pt arial"><B>Sent:</B> Thursday, August 04, 2005 =
1:15=20
PM</DIV>
<DIV style=3D"FONT: 10pt arial"><B>Subject:</B> Postmaster Vr. 7.4.5 =
don't start=20
on Cygwin 1.5.18</DIV>
<DIV><FONT face=3DArial size=3D2></FONT><FONT face=3DArial =
size=3D2></FONT><FONT=20
face=3DArial size=3D2></FONT><FONT face=3DArial =
size=3D2></FONT><BR></DIV>
<DIV><FONT face=3DArial size=3D2>
<DIV><FONT face=3DArial size=3D2>Hi, could anyone help =
me?</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>I upgrade Cygwin (the old version run =
Postgres=20
7.1.2 with no problem, using ipc-daemon) and followed the steps =
conform=20
document "postgresql-7.4.5.README" v 1.56 2004/06/26 =
14:13:29.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>I tried to install PostgreSQL type NT =
services=20
under Win2000. From step 1 to 7, everything worked fine. At step 8, I =
had to=20
login on Windows with user name "postgres" and the password I had =
determined=20
when I created the "postgres" user account (step 2), because I could=20
NOT simulate command "su" on Cygwin (I didn't have a service to=20
authenticate ssh conection, nor the command "RunAs" worked well: it =
always=20
reported that the user or password was invalid!).</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2><U>NOTE 1</U>: my computer runs =
Win2000 on a=20
private network with a Linux Server running Samba as a PDC (Primary =
Domain=20
Controller). So, at this point, I logged the user "postgres" out =
of the=20
domain, that is, I set up the domain as my local machine.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>Ok, "initdb" finished =
succesfully. But,=20
when I run the command on step 9 "cygrunsrv -S postmaster", after some =
time it=20
returns the following error:</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2><STRONG>cygrunsrv: Error starting a =
service:=20
QueryServiceStatus: Win32 error 1053: the service did not answer to =
initial or=20
control request on time </STRONG></FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2><U>NOTE 2</U>: after the number 1053 =
above, the=20
translation is mine since the description of the error is in =
portuguese; sorry=20
for incorrections.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>When I looked at the window =
"Services" from Admin=20
Tools of Windows, it showed a line "postmaster" with the status =
"starting".=20
And this service only could be stopped using the Task Manager of =
Windows by=20
means of selecting the corresponding cygrunsrv process and forcing its =
stop.=20
The use of option "-E" of cygrunsrv process did not work for the same =
reason:=20
a time-out error!</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>Finally, the command on step 10 =
"cygrunsrv -Q=20
postmaster" given before the stopping of the service, displayed =
the=20
information bellow:</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3D"Courier New"=20
=
size=3D2><STRONG>Service &=
nbsp; :=20
postmaster</STRONG></FONT></DIV>
<DIV><FONT face=3D"Courier New" size=3D2><STRONG>Current=20
State : Start Pending =20
<<<---- ?!</STRONG></FONT></DIV>
<DIV><FONT face=3D"Courier New" size=3D2><STRONG>Controls =
Accepted :=20
Stop, Shutdown</STRONG></FONT></DIV>
<DIV><FONT face=3D"Courier New" =
size=3D2><STRONG>Command =20
: /usr/bin/postmaster -D=20
/var/postgresql/data -i</STRONG></FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>The Cygwin itself works very well, so =
what's=20
wrong with PostgreSQL? I apreciate =
if anybody could help me to=20
solve this problem.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>Thanks, very much!</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>Robson Richieri</FONT></DIV>
<DIV><FONT face=3DArial size=3D2><A=20
=
href=3D"mailto:[email protected]">[email protected]</A></FONT=
></DIV>
<DIV><FONT face=3DArial=20
size=3D2></FONT> </DIV></FONT></DIV></BLOCKQUOTE></BODY></HTML>
------=_NextPart_000_009A_01C5D573.5DDAC1A0--