Datafiles binary portable?

Started by Stephen Harrisover 19 years ago4 messagesgeneral
Jump to latest
#1Stephen Harris
lists@spuddy.org

This is probably a silly question, but are the database files binary portable?
eg could I take datafiles from a Sparc and copy them to an Intel machine,
or would the endianness differences kill me?

I expect the answer to be "funny man! Of course not!" for reasons of speed
(native interger handling being quicker than forcing network-endianness,
for example) but you never know...

How about cross OS (eg from Linux Intel to Windows XP, or from Solaris Intel
to Linux Intel)?

(I almost expected this to be a FAQ, but I didn't see it there).

--

rgds
Stephen

#2Martijn van Oosterhout
kleptog@svana.org
In reply to: Stephen Harris (#1)
Re: Datafiles binary portable?

On Tue, Nov 28, 2006 at 11:00:35AM -0500, Stephen Harris wrote:

This is probably a silly question, but are the database files binary portable?
eg could I take datafiles from a Sparc and copy them to an Intel machine,
or would the endianness differences kill me?

No.

It may not even be compatable across the same platform with different
compilers and/or configure flags.

Have a nice day,
--
Martijn van Oosterhout <kleptog@svana.org> http://svana.org/kleptog/

Show quoted text

From each according to his ability. To each according to his ability to litigate.

#3Richard Huxton
dev@archonet.com
In reply to: Stephen Harris (#1)
Re: Datafiles binary portable?

Stephen Harris wrote:

This is probably a silly question, but are the database files binary portable?

No

eg could I take datafiles from a Sparc and copy them to an Intel machine,
or would the endianness differences kill me?

Yes

How about cross OS (eg from Linux Intel to Windows XP, or from Solaris Intel
to Linux Intel)?

Maybe. Wouldn't count on it though.

In fact the data files can be incompatible because of different
compile-time flags (64-bit integer dates on/off for example).
--
Richard Huxton
Archonet Ltd

#4Tom Lane
tgl@sss.pgh.pa.us
In reply to: Stephen Harris (#1)
Re: Datafiles binary portable?

Stephen Harris <lists@spuddy.org> writes:

This is probably a silly question, but are the database files binary portable?

No.

regards, tom lane