Interix port - psql cannot connect properly with the Pgsql server

Поиск
Список
Период
Сортировка
От Vikram S
Тема Interix port - psql cannot connect properly with the Pgsql server
Дата
Msg-id D9539C2261A6BB45B9DAB62C7081B3C10642A415@hyd-msg-01.fareast.corp.microsoft.com
обсуждение исходный текст
Ответы Re: Interix port - psql cannot connect properly with the Pgsql server  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-ports
Hi,
    I have the following problem with getting PostgreSQL running on
Interix 3.0 on a Windows system. (Interix 3.0 is a UNIX subsystem on top
of Windows NT)

    The server seems to hang at CommitTransactionCommand when I try
to just connect to it using psql.

    I saw a similar thing at
http://www.geocrawler.com/archives/3/10/1998/11/50/538024/ - which also
talks of a hang in CommitTransactionCommand in SunOS 4.1, but I didn't
find any resolutions to it. I can debug the problem more deeply if given
some pointers on where I can start looking. The bug report follows

Thanks!
Vikram

========================================================================
====
                          POSTGRESQL BUG REPORT
========================================================================
====

Your name        :          S.Vikram
Your email address    :     viks@microsoft.com


System Configuration
---------------------
  Architecture (example: Intel Pentium)      : Intel Pentium

  Operating System (example: Linux 2.0.26 ELF)     : Interix 3.0 Subsystem
on Windows 2000 SP2.

  PostgreSQL version (example: PostgreSQL-7.2.2):   PostgreSQL-7.2.2

  Compiler used (example:  gcc 2.95.2)        : gcc 2.7.2


Please enter a FULL description of your problem:
------------------------------------------------
I was able to compile PostgreSQL-7.2.2 without any problems on Interix
using gcc-2.7.2 and GNU make 3.79.1. I created the required postgres
user, start postmaster and was able to create a database "test". Started
the postmaster like this -

    /usr/local/pgsql/bin/postmaster -i -d 5 -D /usr/local/pgsql/data
>logfile 2>>1

However when I tried to connect to the database (as postgres) using the
following command

    /usr/local/pgsql/bin/psql -h 127.0.0.1 -e test

psql just waits and does not display the prompt.

The server log file displays the following :

------------------------------------------------------------------------
-----------
DEBUG:  redo record is at 0/1198B0; undo record is at 0/0; shutdown TRUE
DEBUG:  next transaction id: 103; next oid: 24748
DEBUG:  database system was not properly shut down; automatic recovery
in progre
ss
DEBUG:  ReadRecord: record with zero length at 0/1198F0
DEBUG:  redo is not required
DEBUG:  database system is ready
DEBUG:  proc_exit(0)
DEBUG:  shmem_exit(0)
DEBUG:  exit(0)
DEBUG:  reaping dead processes
DEBUG:  BackendStartup: forked pid=721 socket=8
/usr/local/pgsql/bin/postmaster child[721]: starting with (postgres -d5
-v131072
 -p test )
DEBUG:  InitPostgres
DEBUG:  StartTransactionCommand
DEBUG:  query: SELECT usesuper FROM pg_user WHERE usename =
'VIKRAM-DEV+postgres'
DEBUG:  parse tree: { QUERY :command 1  :utility <> :resultRelation 0
:into <> :
isPortal false :isBinary false :isTemp false :hasAggs false :hasSubLinks
false :
rtable ({ RTE :relname pg_user :relid 16478  :subquery <> :alias <>
:eref { ATTR
 :relname pg_user :attrs ( "usename"   "usesysid"   "usecreatedb"
"usetrace"
 "usesuper"   "usecatupd"   "passwd"   "valuntil" )} :inh true :inFromCl
true :c
heckForRead true :checkForWrite false :checkAsUser 0}) :jointree {
FROMEXPR :fro
mlist ({ RANGETBLREF 1 }) :quals { EXPR :typeOid 16  :opType op :oper {
OPER :op
no 93 :opid 0 :opresulttype 16 } :args ({ VAR :varno 1 :varattno 1
:vartype 19 :
vartypmod -1  :varlevelsup 0 :varnoold 1 :varoattno 1} { CONST
:consttype 19 :co
nstlen 32 :constbyval false :constisnull false :constvalue  32 [ 86 73
75 82 65
77 45 68 69 86 43 112 111 115 116 103 114 101 115 0 0 0 0 0 0 0 0 0 0 0
0 0 ] })
}} :rowMarks () :targetList ({ TARGETENTRY :resdom { RESDOM :resno 1
:restype 16
 :restypmod -1 :resname usesuper :reskey 0 :reskeyop 0 :ressortgroupref
0 :resju
nk false } :expr { VAR :varno 1 :varattno 5 :vartype 16 :vartypmod -1
:varlevel
sup 0 :varnoold 1 :varoattno 5}}) :groupClause <> :havingQual <>
:distinctClause
 <> :sortClause <> :limitOffset <> :limitCount <> :setOperations <>
:resultRelat
ions ()}
DEBUG:  rewritten parse tree:
DEBUG:  { QUERY :command 1  :utility <> :resultRelation 0 :into <>
:isPortal fal
se :isBinary false :isTemp false :hasAggs false :hasSubLinks false
:rtable ({ RT
E :relname <> :relid 0  :subquery { QUERY :command 1  :utility <>
:resultRelatio
n 0 :into <> :isPortal false :isBinary false :isTemp false :hasAggs
false :hasSu
bLinks false :rtable ({ RTE :relname pg_user :relid 16478  :subquery <>
:alias {
 ATTR :relname *OLD* :attrs <>} :eref { ATTR :relname *OLD* :attrs (
"usename"
 "usesysid"   "usecreatedb"   "usetrace"   "usesuper"   "usecatupd"
"passwd"
 "valuntil" )} :inh false :inFromCl false :checkForRead true
:checkForWrite fals
e :checkAsUser 0} { RTE :relname pg_user :relid 16478  :subquery <>
:alias { ATT
R :relname *NEW* :attrs <>} :eref { ATTR :relname *NEW* :attrs (
"usename"   "us
esysid"   "usecreatedb"   "usetrace"   "usesuper"   "usecatupd"
"passwd"   "va
luntil" )} :inh false :inFromCl false :checkForRead false :checkForWrite
false :
checkAsUser 1} { RTE :relname pg_shadow :relid 1260  :subquery <> :alias
<> :ere
f { ATTR :relname pg_shadow :attrs ( "usename"   "usesysid"
"usecreatedb"   "u
setrace"   "usesuper"   "usecatupd"   "passwd"   "valuntil" )} :inh true
:inFrom
Cl true :checkForRead true :checkForWrite false :checkAsUser 1})
:jointree { FRO
MEXPR :fromlist ({ RANGETBLREF 3 }) :quals <>} :rowMarks () :targetList
({ TARGE
TENTRY :resdom { RESDOM :resno 1 :restype 19 :restypmod -1 :resname
usename :res
key 0 :reskeyop 0 :ressortgroupref 0 :resjunk false } :expr { VAR :varno
3 :vara
ttno 1 :vartype 19 :vartypmod -1  :varlevelsup 0 :varnoold 3 :varoattno
1}} { TA
RGETENTRY :resdom { RESDOM :resno 2 :restype 23 :restypmod -1 :resname
usesysid
:reskey 0 :reskeyop 0 :ressortgroupref 0 :resjunk false } :expr { VAR
:varno 3 :
varattno 2 :vartype 23 :vartypmod -1  :varlevelsup 0 :varnoold 3
:varoattno 2}}
{ TARGETENTRY :resdom { RESDOM :resno 3 :restype 16 :restypmod -1
:resname usecr
eatedb :reskey 0 :reskeyop 0 :ressortgroupref 0 :resjunk false } :expr {
VAR :va
rno 3 :varattno 3 :vartype 16 :vartypmod -1  :varlevelsup 0 :varnoold 3
:varoatt
no 3}} { TARGETENTRY :resdom { RESDOM :resno 4 :restype 16 :restypmod -1
:resnam
e usetrace :reskey 0 :reskeyop 0 :ressortgroupref 0 :resjunk false }
:expr { VAR
 :varno 3 :varattno 4 :vartype 16 :vartypmod -1  :varlevelsup 0
:varnoold 3 :var
oattno 4}} { TARGETENTRY :resdom { RESDOM :resno 5 :restype 16
:restypmod -1 :re
sname usesuper :reskey 0 :reskeyop 0 :ressortgroupref 0 :resjunk false }
:expr {
 VAR :varno 3 :varattno 5 :vartype 16 :vartypmod -1  :varlevelsup 0
:varnoold 3
:varoattno 5}} { TARGETENTRY :resdom { RESDOM :resno 6 :restype 16
:restypmod -1
 :resname usecatupd :reskey 0 :reskeyop 0 :ressortgroupref 0 :resjunk
false } :e
xpr { VAR :varno 3 :varattno 6 :vartype 16 :vartypmod -1  :varlevelsup 0
:varnoo
ld 3 :varoattno 6}} { TARGETENTRY :resdom { RESDOM :resno 7 :restype 25
:restypm
od -1 :resname passwd :reskey 0 :reskeyop 0 :ressortgroupref 0 :resjunk
false }
:expr { CONST :consttype 25 :constlen -1 :constbyval false :constisnull
false :c
onstvalue  12 [ 12 0 0 0 42 42 42 42 42 42 42 42 ] }} { TARGETENTRY
:resdom { RE
SDOM :resno 8 :restype 702 :restypmod -1 :resname valuntil :reskey 0
:reskeyop 0
 :ressortgroupref 0 :resjunk false } :expr { VAR :varno 3 :varattno 8
:vartype 7
02 :vartypmod -1  :varlevelsup 0 :varnoold 3 :varoattno 8}})
:groupClause <> :ha
vingQual <> :distinctClause <> :sortClause <> :limitOffset <>
:limitCount <> :se
tOperations <> :resultRelations ()} :alias <> :eref { ATTR :relname
pg_user :att
rs ( "usename"   "usesysid"   "usecreatedb"   "usetrace"   "usesuper"
"usecatu
pd"   "passwd"   "valuntil" )} :inh false :inFromCl true :checkForRead
false :ch
eckForWrite false :checkAsUser 0}) :jointree { FROMEXPR :fromlist ({
RANGETBLREF
 1 }) :quals { EXPR :typeOid 16  :opType op :oper { OPER :opno 93 :opid
0 :opres
ulttype 16 } :args ({ VAR :varno 1 :varattno 1 :vartype 19 :vartypmod -1
:varle
velsup 0 :varnoold 1 :varoattno 1} { CONST :consttype 19 :constlen 32
:constbyva
l false :constisnull false :constvalue  32 [ 86 73 75 82 65 77 45 68 69
86 43 11
2 111 115 116 103 114 101 115 0 0 0 0 0 0 0 0 0 0 0 0 0 ] })}} :rowMarks
() :tar
getList ({ TARGETENTRY :resdom { RESDOM :resno 1 :restype 16 :restypmod
-1 :resn
ame usesuper :reskey 0 :reskeyop 0 :ressortgroupref 0 :resjunk false }
:expr { V
AR :varno 1 :varattno 5 :vartype 16 :vartypmod -1  :varlevelsup 0
:varnoold 1 :v
aroattno 5}}) :groupClause <> :havingQual <> :distinctClause <>
:sortClause <> :
limitOffset <> :limitCount <> :setOperations <> :resultRelations ()}
DEBUG:  plan: { SEQSCAN :startup_cost 0.00 :total_cost 1.01 :rows 1
:width 1 :qp
targetlist ({ TARGETENTRY :resdom { RESDOM :resno 1 :restype 16
:restypmod -1 :r
esname usesuper :reskey 0 :reskeyop 0 :ressortgroupref 0 :resjunk false
} :expr
{ VAR :varno 4 :varattno 5 :vartype 16 :vartypmod -1  :varlevelsup 0
:varnoold 4
 :varoattno 5}}) :qpqual ({ EXPR :typeOid 16  :opType op :oper { OPER
:opno 93 :
opid 62 :opresulttype 16 } :args ({ VAR :varno 4 :varattno 1 :vartype 19
:vartyp
mod -1  :varlevelsup 0 :varnoold 4 :varoattno 1} { CONST :consttype 19
:constlen
 32 :constbyval false :constisnull false :constvalue  32 [ 86 73 75 82
65 77 45
68 69 86 43 112 111 115 116 103 114 101 115 0 0 0 0 0 0 0 0 0 0 0 0 0 ]
})}) :le
fttree <> :righttree <> :extprm () :locprm () :initplan <> :nprm 0
:scanrelid 4
 }
DEBUG:  ProcessQuery
DEBUG:  CommitTransactionCommand

<Server waits here forever till I press Ctrl-C at the client, Then it
logs..>

DEBUG:  pq_recvbuf: unexpected EOF on client connection
DEBUG:  proc_exit(0)
DEBUG:  shmem_exit(0)
DEBUG:  exit(0)
DEBUG:  reaping dead processes
DEBUG:  child process (pid 2001) exited with exit code 0

------------------------------------------------------------------------
-----------


Please describe a way to repeat the problem.   Please try to provide a
concise reproducible example, if at all possible:
----------------------------------------------------------------------
The problem mentioned can be reproduced consistently on any machine
running Interix 3.0



В списке pgsql-ports по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: 7.2.2 on Mac OS 10.2.1 (Darwin 6.0)
Следующее
От: 4m44mmll
Дата:
Сообщение: C compiler cannot create executables