Re: [GENERAL] Unable to dump database using pg_dump

2008-06-12 Thread Craig Ringer
Adam Dear wrote: > Let me ask this question. Is there any other option for moving data > from one server to another that doesn't involve pg_dump? If I can get > the data out of this server, and onto my new one I don't care if the old > server gets fixed. I just need the data. The new server alr

Re: [GENERAL] Unable to dump database using pg_dump

2008-06-12 Thread Adam Dear
What is Slony? I have a super user account for the server and the database. Joshua D. Drake wrote: On Thu, 2008-06-12 at 11:33 -0500, Adam Dear wrote: Let me ask this question. Is there any other option for moving data from one server to another that doesn't involve pg_dump? If I can get t

Re: [GENERAL] Unable to dump database using pg_dump

2008-06-12 Thread Tom Lane
Adam Dear <[EMAIL PROTECTED]> writes: > Let me ask this question. Is there any other option for moving data > from one server to another that doesn't involve pg_dump? If I can get > the data out of this server, and onto my new one I don't care if the old > server gets fixed. I just need the d

Re: [GENERAL] Unable to dump database using pg_dump

2008-06-12 Thread Alvaro Herrera
Adam Dear wrote: > Let me ask this question. Is there any other option for moving data > from one server to another that doesn't involve pg_dump? If I can get > the data out of this server, and onto my new one I don't care if the old > server gets fixed. I just need the data. The new serv

Re: [GENERAL] Unable to dump database using pg_dump

2008-06-12 Thread Joshua D. Drake
On Thu, 2008-06-12 at 11:33 -0500, Adam Dear wrote: > Let me ask this question. Is there any other option for moving data > from one server to another that doesn't involve pg_dump? If I can get > the data out of this server, and onto my new one I don't care if the old > server gets fixed. I

Re: [GENERAL] Unable to dump database using pg_dump

2008-06-12 Thread Adam Dear
Let me ask this question. Is there any other option for moving data from one server to another that doesn't involve pg_dump? If I can get the data out of this server, and onto my new one I don't care if the old server gets fixed. I just need the data. The new server already has the table st

Re: [GENERAL] Unable to dump database using pg_dump

2008-06-12 Thread Tom Lane
Adam Dear <[EMAIL PROTECTED]> writes: > If I restored the data directory again wouldn't that undo the Vacuum > Freeze command that I did that has locked the database into the state > that it is in now? It'd undo the freeze, but that doesn't get you any closer to a solution. What you need is to g

Re: [GENERAL] Unable to dump database using pg_dump

2008-06-12 Thread Adam Dear
I downloaded a hex editor, but honestly, I can't make heads or tails of what I'm looking at. I'm not sure what needs changing. Also, FYI, you mentioned that you thought I had deleted the record with ctid=(0,2). I did delete that, but thats what caused the database to not work. I restored a

Re: [GENERAL] Unable to dump database using pg_dump

2008-06-12 Thread Tom Lane
Adam Dear <[EMAIL PROTECTED]> writes: > I'm comfortable enough with it that I can edit it if I can find exactly > what to edit. Whats the best way to edit the file? I've opened it using: > vim -b 1260 > Here is what is at the end of the block in the file. If you could point > me in the right

Re: [GENERAL] Unable to dump database using pg_dump

2008-06-12 Thread Alvaro Herrera
Adam Dear wrote: > I'm comfortable enough with it that I can edit it if I can find exactly > what to edit. Whats the best way to edit the file? I've opened it > using: > > vim -b 1260 > > Here is what is at the end of the block in the file. If you could point > me in the right direction, I'

Re: [GENERAL] Unable to dump database using pg_dump

2008-06-12 Thread Adam Dear
I'm comfortable enough with it that I can edit it if I can find exactly what to edit. Whats the best way to edit the file? I've opened it using: vim -b 1260 Here is what is at the end of the block in the file. If you could point me in the right direction, I'd appreciate it. @[EMAIL PROTEC

Re: [GENERAL] Unable to dump database using pg_dump

2008-06-11 Thread Tom Lane
Adam Dear <[EMAIL PROTECTED]> writes: > madisoncounty=# select ctid,xmin,xmax,cmin,cmax,usename from pg_shadow; > ctid | xmin | xmax | cmin | cmax |usename > ---+--+--+--+--+--- > (0,1) |1 | 596 | 596 |1 | postgres > (0,2) |2 |1 |1 |

Re: [GENERAL] Unable to dump database using pg_dump

2008-06-11 Thread Adam Dear
madisoncounty=# select ctid,xmin,xmax,cmin,cmax,usename from pg_shadow; ctid | xmin | xmax | cmin | cmax |usename ---+--+--+--+--+--- (0,1) |1 | 596 | 596 |1 | postgres (0,2) |2 |1 |1 |0 | postgres (0,5) |2 |0 |0 |0

Re: [GENERAL] Unable to dump database using pg_dump

2008-06-11 Thread Tom Lane
Adam Dear <[EMAIL PROTECTED]> writes: > The record is still there. Hmph. Could we see all the system columns from that table? select ctid,xmin,xmax,cmin,cmax,usename from pg_shadow; regards, tom lane -- Sent via pgsql-general mailing list (pgsql-general@postgresq

Re: [GENERAL] Unable to dump database using pg_dump

2008-06-11 Thread Adam Dear
I tried: Vacuum Freeze pg_shadow; Then Reindex database madisoncounty; Then Delete from pg_shadow where ctid='(0,1)'; The record is still there. Tom Lane wrote: Adam Dear <[EMAIL PROTECTED]> writes: I tried: Delete from pg_shadow where ctid = '(0,1)'; DELETE 0 This is looking more and

Re: [GENERAL] Unable to dump database using pg_dump

2008-06-11 Thread Tom Lane
Adam Dear <[EMAIL PROTECTED]> writes: > I tried: > Delete from pg_shadow where ctid = '(0,1)'; > DELETE 0 This is looking more and more like a transaction ID wraparound problem. Did you try the vacuum freeze suggestion? regards, tom lane -- Sent via pgsql-general mailing

Re: [GENERAL] Unable to dump database using pg_dump

2008-06-11 Thread Adam Dear
I managed to get the server started again. It was failing because the permissions on the data folder were not right. Now, though, I'm back to where I started. There are two postgres users in the pg_shadow table. One of them has a password, the other doesn't, but they both have the same sysi

Re: [GENERAL] Unable to dump database using pg_dump

2008-06-11 Thread Tom Lane
Adam Dear <[EMAIL PROTECTED]> writes: > I'm not seeing the madisoncounty user in there. Odder and odder. It might be worth trying "vacuum freeze pg_shadow". > Also, I tried starting > the db using /etc/init.d/postgres start, and it fails. Fails how? In particular, what shows up in the postmas

Re: [GENERAL] Unable to dump database using pg_dump

2008-06-11 Thread Adam Dear
I really appreciate you help so far. here is what I am seeing . I did: select * from pg_shadow; 1: usename (typeid = 19, len = 64, typmod = -1, byval = f) 2: usesysid(typeid = 23, len = 4, typmod = -1, byval = t) 3: usecreatedb (typeid = 16, len = 1, typmod = -1, byv

Re: [GENERAL] Unable to dump database using pg_dump

2008-06-11 Thread Tom Lane
Adam Dear <[EMAIL PROTECTED]> writes: > I ran the select as instructed, and this is the output: > madisoncounty=# select ctid, usename, usesysid from pg_shadow; > ctid |usename| usesysid > ---+---+-- > (0,1) | postgres |1 > (0,2) | postgres |

Re: [GENERAL] Unable to dump database using pg_dump

2008-06-11 Thread Adam Dear
I ran the select as instructed, and this is the output: madisoncounty=# select ctid, usename, usesysid from pg_shadow; ctid |usename| usesysid ---+---+-- (0,1) | postgres |1 (0,2) | postgres |1 (0,5) | madisoncounty | 100 (3 rows

Re: [GENERAL] Unable to dump database using pg_dump

2008-06-11 Thread Tom Lane
Adam Dear <[EMAIL PROTECTED]> writes: > pg_dump: query to obtain list of schemas failed: ERROR: more than one > row returned by a subquery used as an expression > The pg_dump command is from version 7.4.11. This is the version of > postgres I am running on my old server. Just FYI, when doing

Re: [GENERAL] Unable to dump database using pg_dump

2008-06-11 Thread Adam Dear
The pg_dump command is from version 7.4.11. This is the version of postgres I am running on my old server. Craig Ringer wrote: Adam Dear wrote: pg_dump: query to obtain list of schemas failed: ERROR: more than one row returned by a subquery used as an expression Is the pg_dump command fro

Re: [GENERAL] Unable to dump database using pg_dump

2008-06-11 Thread Craig Ringer
Adam Dear wrote: pg_dump: query to obtain list of schemas failed: ERROR: more than one row returned by a subquery used as an expression Is the pg_dump command from the old postgresql install or the new one? -- Craig Ringer -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org

[GENERAL] Unable to dump database using pg_dump

2008-06-11 Thread Adam Dear
I am migrating to a new server. I am trying to get a dump of my database to import into postgres 8.1.11 on my new server. When I run the pg_dump commmand: pg_dump --clean --file=madison.sql --schema=public -U madisoncounty madisoncounty I get this message: pg_dump: query to obtain list of