[GENERAL] User defined type - analyze problem

2010-05-02 Thread Carsten Kropf
Hi *, I have a little problem with a user defined type: I constructed a type called "pointnd" which represents a multi-dimensional point. This point is subsequently used as an array type in another user defined type, like the following: CREATE TYPE document AS (words tsvector, points _pointnd);

Re: [GENERAL] PostgreSQL vs. Microsoft SQL server

2010-05-02 Thread Scott Marlowe
On Mon, May 3, 2010 at 12:04 AM, Thomas Løcke wrote: > On Sun, May 2, 2010 at 7:57 PM, Andy wrote: >> Skype, perhaps the largest telephony app in the world, uses Postgresql. >> >> Here's some info on their postgresql usage: >> >> http://highscalability.com/skype-plans-postgresql-scale-1-billion-u

Re: [GENERAL] PostgreSQL vs. Microsoft SQL server

2010-05-02 Thread Thomas Løcke
On Sun, May 2, 2010 at 7:57 PM, Andy wrote: > Skype, perhaps the largest telephony app in the world, uses Postgresql. > > Here's some info on their postgresql usage: > > http://highscalability.com/skype-plans-postgresql-scale-1-billion-users > https://developer.skype.com/SkypeGarage/DbProjects/Sky

Re: [GENERAL] Tracking down log segment corruption

2010-05-02 Thread Tom Lane
Gordon Shannon writes: > In any case, I will cease and desist from ALTER SET TABLESPACE for a while!. Here's the applied patch, if you are interested in testing it. regards, tom lane Index: src/backend/access/heap/heapam.c

Re: [GENERAL] Tracking down log segment corruption

2010-05-02 Thread Gordon Shannon
Sounds like you're on it. Just wanted to share one additional piece, in case it helps. Just before the ALTER INDEX SET TABLESPACE was issued, there were some writes to the table in question inside a serializable transaction. The transaction committed at 11:11:58 EDT, and consisted of, among a cou

Re: [GENERAL] Tracking down log segment corruption

2010-05-02 Thread Tom Lane
Gordon Shannon writes: > [ corruption on a standby slave after an ALTER SET TABLESPACE operation ] Found it, I think. ATExecSetTableSpace transfers the copied data to the slave by means of XLOG_HEAP_NEWPAGE WAL records. The replay function for this (heap_xlog_newpage) is failing to pay any atte

Re: [GENERAL] Tracking down log segment corruption

2010-05-02 Thread Gordon Shannon
On Sun, May 2, 2010 at 12:52 PM, Tom Lane wrote: > Gordon Shannon writes: > > Bingo. Yes it is reasonable. It was 25 seconds between my altering the > > index in question and the server crash. > > Sounds like we have a smoking gun. Could you show all your non-default > postgresql.conf setting

Re: [GENERAL] postgres crashes - could not reattach to shared memory

2010-05-02 Thread Dave Page
On Sun, May 2, 2010 at 7:41 PM, Tom Lane wrote: > Dave Page writes: >> On 5/2/10, Tom Lane wrote: >> I'm not so sure it's fair to the users though. > > Well, we did promise that Windows 8.2 would have the same lifespan as > 8.2 on other platforms: > http://www.postgresql.org/about/news.865 Righ

Re: [GENERAL] File compression in WinXP

2010-05-02 Thread Ivan Voras
On 2.5.2010 16:48, pasman pasmański wrote: > Hello. > I'm install postgresql 8.4.3 on WinXPsp3. > Because of small disk i create tablespace > pointing to commpressed folder and move > some tables to it. > Compression is good: 10GB to 3-4GB > speed acceptable (small activity,10 users) > > But is

Re: [GENERAL] Tracking down log segment corruption

2010-05-02 Thread Tom Lane
Gordon Shannon writes: > Bingo. Yes it is reasonable. It was 25 seconds between my altering the > index in question and the server crash. Sounds like we have a smoking gun. Could you show all your non-default postgresql.conf settings on the master? I'm wondering about full_page_writes in part

Re: [GENERAL] postgres crashes - could not reattach to shared memory

2010-05-02 Thread Tom Lane
Dave Page writes: > On 5/2/10, Tom Lane wrote: >> If we take seriously the proposition that we're still supporting 8.2 >> on Windows, we probably ought to do something about that. If we don't, >> we need to officially deprecate that version. > That's the last non-msvc++ version. Personally I'd

Re: [GENERAL] Tracking down log segment corruption

2010-05-02 Thread Gordon Shannon
On Sun, May 2, 2010 at 12:10 PM, Tom Lane wrote: > No, this would be a pg_database row with that OID. But it looks like > you found the relevant index anyway. > > Yup, realized that on second reading. > > These commands worked fine on the master, yet this seems suspiciously > > relevant. > > >

Re: [GENERAL] postgres crashes - could not reattach to shared memory

2010-05-02 Thread Dave Page
On 5/2/10, Tom Lane wrote: > Dave Page writes: >> On Sun, May 2, 2010 at 8:27 AM, Sofer, Yuval wrote: >>> PG "FATAL: could not reattach to shared memory (key=5432001, >>> addr=0210): Invalid argument. >>> >>> The version is 8.2.4, the platform is win32 > >> This was fixed in 8.3.8 and 8.4.1

Re: [GENERAL] Tracking down log segment corruption

2010-05-02 Thread Tom Lane
Gordon Shannon writes: > Interesting. There is no pg_class entry for 22362. No, this would be a pg_database row with that OID. But it looks like you found the relevant index anyway. > ... There is, however, an > entry for that filenode. It's an index I created Sat AM, about 6AM. > ... > - This

Re: [GENERAL] PostgreSQL vs. Microsoft SQL server

2010-05-02 Thread Andy
Skype, perhaps the largest telephony app in the world, uses Postgresql. Here's some info on their postgresql usage: http://highscalability.com/skype-plans-postgresql-scale-1-billion-users https://developer.skype.com/SkypeGarage/DbProjects/SkypePostgresqlWhitepaper --- On Sat, 5/1/10, Thomas Lø

Re: [GENERAL] Tracking down log segment corruption

2010-05-02 Thread Gordon Shannon
On Sun, May 2, 2010 at 11:02 AM, Tom Lane wrote: > > > Hmm ... AFAICS the only way to get that message when the incoming TID's > offsetNumber is only 2 is for the index page to be completely empty > (not zeroes, else PageAddItem's sanity check would have triggered, > but valid and empty). What t

Re: [GENERAL] Tracking down log segment corruption

2010-05-02 Thread Tom Lane
Gordon Shannon writes: > I just got ran into the same problem. Both servers are running 8.4.3, and > the standby server had been running for 2 days, processing many thousands of > logs successfully. Here's my error: > 4158 2010-05-02 11:12:09 EDT [26445]LOG: restored log file > "0001

Re: [GENERAL] Tracking down log segment corruption

2010-05-02 Thread Gordon Shannon
I just got ran into the same problem. Both servers are running 8.4.3, and the standby server had been running for 2 days, processing many thousands of logs successfully. Here's my error: 4158 2010-05-02 11:12:09 EDT [26445]LOG: restored log file "00013C7700C3" from archive 4158

Re: [GENERAL] About the limit of storage

2010-05-02 Thread Cédric Villemain
2010/5/2 Sean : > I need to have a PostgreSQL server with 10TB disk. I created a DB which > contains three tables. > > I understand that PostgreSQL has the following hard limit: > size per table: 32TB > size per DB: none > I wonder what I should do if the sum of my data exceed 10TB. It does not > e

[GENERAL] About the limit of storage

2010-05-02 Thread Sean
I need to have a PostgreSQL server with 10TB disk. I created a DB which contains three tables. I understand that PostgreSQL has the following hard limit: size per table: 32TBsize per DB: none I wonder what I should do if the sum of my data exceed 10TB. It does not exceed any limit that PostgreS

Re: [GENERAL] Indexing queries with bit masks

2010-05-02 Thread Mike Christensen
Hey thanks.. I thought I'd share the method I came up with for updating subscriptions. Basically, as far as my code is concerned the DB uses a bitmask (at least for updates) but I abstract it through a function. First off, I have a little helper function so I don't repeat the same code a bunch o

Re: [GENERAL] Order of execution in shell echo to psql

2010-05-02 Thread John Gage
Thanks very much for elucidating this. \g is going to help me in this situation more than the ; John On May 2, 2010, at 4:25 PM, Tom Lane wrote: David W Noon writes: On Sun, 2 May 2010 14:13:52 +0200, John Gage wrote abour [GENERAL] I issue the following command to the shell: echo '\o

[GENERAL] File compression in WinXP

2010-05-02 Thread pasman pasmański
Hello. I'm install postgresql 8.4.3 on WinXPsp3. Because of small disk i create tablespace pointing to commpressed folder and move some tables to it. Compression is good: 10GB to 3-4GB speed acceptable (small activity,10 users) But is this safe ? pasman

Re: [GENERAL] postgres crashes - could not reattach to shared memory

2010-05-02 Thread Tom Lane
Dave Page writes: > On Sun, May 2, 2010 at 8:27 AM, Sofer, Yuval wrote: >> PG "FATAL:  could not reattach to shared memory (key=5432001, >> addr=0210): Invalid argument. >> >> The version is 8.2.4, the platform is win32 > This was fixed in 8.3.8 and 8.4.1. I'm not entirely sure why it didn'

Re: [GENERAL] Order of execution in shell echo to psql

2010-05-02 Thread Tom Lane
David W Noon writes: > On Sun, 2 May 2010 14:13:52 +0200, John Gage wrote abour [GENERAL] >> I issue the following command to the shell: >> >> echo '\o file.txt \\ select * from table_name limit 10 \o ' | psql -- >> host 'localhost' --port 5432 --username 'johngage' 'database_name' > Try putti

Re: [GENERAL] int2vector

2010-05-02 Thread Tom Lane
AI Rumman writes: > What is int2vector data type? Is it possible to use it as an array? It's a restricted form of regular smallint[]. But having said that, using it in user tables is strongly discouraged --- if we change it and that breaks your code, you will get zero sympathy.

Re: [GENERAL] Order of execution in shell echo to psql

2010-05-02 Thread David W Noon
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Sun, 2 May 2010 14:13:52 +0200, John Gage wrote abour [GENERAL] Order of execution in shell echo to psql: >I issue the following command to the shell: > >echo '\o file.txt \\ select * from table_name limit 10 \o ' | psql -- >host 'localhost' --po

[GENERAL] Order of execution in shell echo to psql

2010-05-02 Thread John Gage
I issue the following command to the shell: echo '\o file.txt \\ select * from table_name limit 10 \o ' | psql -- host 'localhost' --port 5432 --username 'johngage' 'database_name' I expect the results to be redirected to file.txt because that is the meta-command immediately preceeding the

[GENERAL] int2vector

2010-05-02 Thread AI Rumman
What is int2vector data type? Is it possible to use it as an array? Any one please.

Re: [GENERAL] Large index operation crashes postgres

2010-05-02 Thread strk
On Mon, Mar 29, 2010 at 09:39:35AM +0200, Frans Hals wrote: > Paul, > > took your advice and installed Geos 3.2.0. > Index is now running for 14 hrs, postmaster is taking all the RAM. > Sadly it looks like the Geos update didn't save me. Frans, could you try installing GEOS 3.2.2 ? A leak was fix

Re: [GENERAL] PostgreSQL vs. Microsoft SQL server

2010-05-02 Thread Thomas Kellerer
Greg Smith wrote on 02.05.2010 01:16: Scott Ribe wrote: PG's locking scheme, MVCC, basically precludes certain specific optimizations that means a small number of very specific queries don't perform as well, while at the same time it means that throughput with multiple simultaneous connections s

Re: [GENERAL] postgres crashes - could not reattach to shared memory

2010-05-02 Thread Thomas Kellerer
Sofer, Yuval wrote on 02.05.2010 09:27: Hi Postgres crashes with - PG "FATAL: could not reattach to shared memory (key=5432001, addr=0210): Invalid argument. The version is 8.2.4, the platform is win32 Does someone know the reason/workaround ? I think this is supposed to be fixed with 8

Re: [GENERAL] postgres crashes - could not reattach to shared memory

2010-05-02 Thread Dave Page
On Sun, May 2, 2010 at 8:27 AM, Sofer, Yuval wrote: > Hi > > > > Postgres crashes with - > > > > PG "FATAL:  could not reattach to shared memory (key=5432001, > addr=0210): Invalid argument. > > The version is 8.2.4, the platform is win32 > > Does someone know the reason/workaround ? This was

Re: [GENERAL] postgres crashes - could not reattach to shared memory

2010-05-02 Thread Vibhor Kumar
On 02/05/10 12:57 PM, Sofer, Yuval wrote: PG "FATAL:  could not reattach to shared memory (key=5432001, addr=0210): Invalid argument.   On windows this kind of issue, generally happens due to Firewall/Antivirus Software. Please try with disabling the firewall/antiv

Re: [GENERAL] postgres crashes - could not reattach to shared memory

2010-05-02 Thread Shoaib Mir
On Sun, May 2, 2010 at 5:27 PM, Sofer, Yuval wrote: > > PG "FATAL: could not reattach to shared memory (key=5432001, > addr=0210): Invalid argument. > > > In my previous experiences with PostgreSQL on Windows I have seen such similar type of problems when Anti-virus software was running on t

[GENERAL] postgres crashes - could not reattach to shared memory

2010-05-02 Thread Sofer, Yuval
Hi Postgres crashes with - PG "FATAL: could not reattach to shared memory (key=5432001, addr=0210): Invalid argument. The version is 8.2.4, the platform is win32 Does someone know the reason/workaround ? Thanks, Yuval Sofer BMC Software CTM&D Business Unit DBA Team 972-52-

Re: [GENERAL] PostgreSQL vs. Microsoft SQL server

2010-05-02 Thread Dimitri Fontaine
Merlin Moncure writes: > On Sat, May 1, 2010 at 2:47 PM, Thomas Løcke > wrote: >> Anybody know of any recent comparisons made between the two? >> >> I'm in the process of buying a new telephony related software suite, > > if you are writing stuff in C/C++, doing significant coding INSIDE the >