agora inbox for postgres@postgres.berkeley.edu  
help / color / mirror / Atom feed
Endian problems with P95
3+ messages / 2 participants
[nested] [flat]

* Endian problems with P95
@ 1995-05-26 12:15 Richard Taylor <rjt@rivers.dra.hmg.gb>
  1995-05-26 16:50 ` Re: Endian problems with P95 Jolly Chen <jolly@postgres.Berkeley.EDU>
  0 siblings, 1 reply; 3+ messages in thread

From: Richard Taylor @ 1995-05-26 12:15 UTC (permalink / raw)
  To: legacy


We are having problems with postgres95. When the postmaster is compiled on 
a big endian machine only monitors compiled and run on big endian a machine
can talk to it. When the postmaster is compiled on a little endian machine
only monitors compiled and run on little endian a machine can talk to it.

Has anyone else experienced this problem ?

The combinations we have tried are

postmaster			monitor			

Alpha/OSF1 3.0			Alpha/OSF1 3.0 		OK
				Mips/Dec Ultrix 4.4	OK
				Sparc/SunOs 4.1.3	FAILS

Sparc/SunOs 4.1.3		Sparc/SunOs 4.1.3	OK
				Mips/Dec Ultrix 4.4	FAILS
				Alpha/OSF1 3.0		FAILS

When the monitor is run it simply hangs, no messages are received from the
postmaster or from the monitor.

Any ideas.

Richard

			------------------------------
Richard Taylor, N129, DRA Malvern, St Andrews Rd, Malvern, Worcs. WR14 3PS. UK.
   Tel: +44 1684 896028; Fax: +44 1684 894303; Email: rjt@rivers.dra.hmg.gb

==============================================================================
   To add/remove yourself to/from the POSTGRES mailing list: send mail with 
   the subject line ADD or DEL to "postgres-request@postgres.Berkeley.EDU".
   If this fails, send mail to "post_questions@postgres.Berkeley.EDU" and
   a human will deal with it.  DO NOT post to the "postgres" mailing list.
==============================================================================
              URL: http://s2k-ftp.CS.Berkeley.EDU:8000/postgres/



^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: Endian problems with P95
  1995-05-26 12:15 Endian problems with P95 Richard Taylor <rjt@rivers.dra.hmg.gb>
@ 1995-05-26 16:50 ` Jolly Chen <jolly@postgres.Berkeley.EDU>
  1995-05-26 22:48   ` Re: Endian problems with P95 Jolly Chen <jolly@postgres.Berkeley.EDU>
  0 siblings, 1 reply; 3+ messages in thread

From: Jolly Chen @ 1995-05-26 16:50 UTC (permalink / raw)
  To: rjt@rivers.dra.hmg.gb; +Cc: postgres95@postgres.Berkeley.EDU; legacy


> 
> We are having problems with postgres95. When the postmaster is compiled on 
> a big endian machine only monitors compiled and run on big endian a machine
> can talk to it. When the postmaster is compiled on a little endian machine
> only monitors compiled and run on little endian a machine can talk to it.
> 
> Has anyone else experienced this problem ?
> 

This is a problem that is common to both postgres and postgres95.  The
frontend/backend protocol does not use an architectural neutral format.
For that matter, the data in the database is not stored in an
architectural neutral format, either.  What this means is that you
cannot use client/servers with different word-sizes or different
endian representation.

One way to solve this problem is to change everything to a neutral
format like XDR.  This requires substantial code changes and some small
penalty performances.  We have no current plans to do this in
postgres95 although it is on our (wish we had the time) TODO list.

- Jolly Chen

P.S.  please sent postgres95 specific messages to
postgres95@postgres.berkeley.edu

==============================================================================
   To add/remove yourself to/from the POSTGRES mailing list: send mail with 
   the subject line ADD or DEL to "postgres-request@postgres.Berkeley.EDU".
   If this fails, send mail to "post_questions@postgres.Berkeley.EDU" and
   a human will deal with it.  DO NOT post to the "postgres" mailing list.
==============================================================================
              URL: http://s2k-ftp.CS.Berkeley.EDU:8000/postgres/



^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: Endian problems with P95
  1995-05-26 12:15 Endian problems with P95 Richard Taylor <rjt@rivers.dra.hmg.gb>
  1995-05-26 16:50 ` Re: Endian problems with P95 Jolly Chen <jolly@postgres.Berkeley.EDU>
@ 1995-05-26 22:48   ` Jolly Chen <jolly@postgres.Berkeley.EDU>
  0 siblings, 0 replies; 3+ messages in thread

From: Jolly Chen @ 1995-05-26 22:48 UTC (permalink / raw)
  To: Jolly Chen <jolly@postgres.Berkeley.EDU>; +Cc: rjt@rivers.dra.hmg.gb; postgres95@postgres.Berkeley.EDU; legacy


> > 
> > We are having problems with postgres95. When the postmaster is compiled on 
> > a big endian machine only monitors compiled and run on big endian a machine
> > can talk to it. When the postmaster is compiled on a little endian machine
> > only monitors compiled and run on little endian a machine can talk to it.
> > 
> > Has anyone else experienced this problem ?
> > 
> 
> This is a problem that is common to both postgres and postgres95.  The
> frontend/backend protocol does not use an architectural neutral format.
> For that matter, the data in the database is not stored in an
> architectural neutral format, either.  What this means is that you
> cannot use client/servers with different word-sizes or different
> endian representation.
> 

Egg on my face!  I have to retract what I said.  Postgres is actually
smart about transferring integers between the frontends and backends so
that heterogeneous clients and servers can connect and transfer data in
ASCII.  (We chop the integer up into bytes and transfer it a byte at a
time and reconstruct the integer when we receive it) Postgres95 broke
this for the initial startup message that is sent between the frontend
to the backend.  We've fixed this and posted a patch to our home page
about it.

The data that is stored in your database is still stored in the native
format of the server, not in a neutral format.  However, if you are
always retrieving tuples out in ASCII and storing tuples in ASCII from
your front-end, then you are safe.  If you use binary portals, then you
will get the binary representation of the sending host. 

I'm very sorry about the confusion.

- Jolly Chen

==============================================================================
   To add/remove yourself to/from the POSTGRES mailing list: send mail with 
   the subject line ADD or DEL to "postgres-request@postgres.Berkeley.EDU".
   If this fails, send mail to "post_questions@postgres.Berkeley.EDU" and
   a human will deal with it.  DO NOT post to the "postgres" mailing list.
==============================================================================
              URL: http://s2k-ftp.CS.Berkeley.EDU:8000/postgres/



^ permalink  raw  reply  [nested|flat] 3+ messages in thread


end of thread, other threads:[~1995-05-26 22:48 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
1995-05-26 12:15 Endian problems with P95 Richard Taylor <rjt@rivers.dra.hmg.gb>
1995-05-26 16:50 ` Jolly Chen <jolly@postgres.Berkeley.EDU>
1995-05-26 22:48   ` Jolly Chen <jolly@postgres.Berkeley.EDU>

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox