Re: database file compatibility patch
От | Tom Lane |
---|---|
Тема | Re: database file compatibility patch |
Дата | |
Msg-id | 10048.1128302797@sss.pgh.pa.us обсуждение исходный текст |
Ответ на | database file compatibility patch (Qingqing Zhou <zhouqq@cs.toronto.edu>) |
Ответы |
Re: database file compatibility patch
|
Список | pgsql-patches |
Qingqing Zhou <zhouqq@cs.toronto.edu> writes: > This patches checks MAXIMUM_ALIGNOF and endian to make sure that the > database file used is compatible with the server version. I missed seeing this patch in my inbox, so wrote and applied my own version earlier today. Sorry for the missed communication :-(. It's about the same result though. > What it comes down > to is that MAXIMUM_ALIGNOF is sufficient to tell the difference between > the platforms we need to deal with. Also, check the endian to make sure > that the multibytes numbers storage is compatible. There's not much need to check endianness explicitly, since the pg_control_version check will surely fail if there's an endianness discrepancy (not to mention the other checks on pg_control fields). [ Actually, I had originally thought that alignment would be reflected implicitly in pg_control too, but given that it's mostly int32 fields I don't think that can be relied on. ] What I did add, after reviewing the past discussion of these issues, is a simple-minded test to see if the floating-point storage format is the same. That and endianness/alignment are the only points that have been mentioned as likely causes of cross-platform incompatibility. regards, tom lane
В списке pgsql-patches по дате отправления: