Re: [ADMIN] Recover from failover

2011-12-05 Thread white.heron white
Dear All, As soon as the slave database server had been promoted to master. The old-server master database should be promote to become slave server. I believe database replication has been done by your vendor. In this case the new master database server will replicate data with new slave databas

Re: [ADMIN] Recover from failover

2011-12-05 Thread Jerry Sievers
Martin S writes: > Hello list, > > May be this information is inside the documentation, but couldn't find it. > > I'm doing some tests with postgres 9.1.1 and replication, and I was > wandering if there is some information about how to recover from a > failover. > > Suppose I'm doing some kernel

Re: [ADMIN] Database corrupted

2011-12-05 Thread Scott Marlowe
On Mon, Dec 5, 2011 at 1:53 PM, Tom Lane wrote: > Scott Marlowe writes: >> On Mon, Dec 5, 2011 at 1:18 PM, Yann ROBIN wrote: >>> kill -9 of the writer process > >> Are you sure you killed all the postgres backends before restarting >> the server?  If other backends are still running, with a dead

Re: [ADMIN] Recover from failover

2011-12-05 Thread Kevin Grittner
Martin S wrote: > May be this information is inside the documentation, but couldn't > find it. > > I'm doing some tests with postgres 9.1.1 and replication, and I > was wandering if there is some information about how to recover > from a failover. Does this page provide what you need?: http

Re: [ADMIN] Database corrupted

2011-12-05 Thread Yann ROBIN
On Mon, Dec 5, 2011 at 9:53 PM, Tom Lane wrote: > > There are interlocks against that ... although if you were foolish > enough to manually remove postmaster.pid, you could defeat them :-( > We didn't remove postmaster.pid -- Yann -- Sent via pgsql-admin mailing list (pgsql-admin@postgresql.o

Re: [ADMIN] Database corrupted

2011-12-05 Thread Tom Lane
Scott Marlowe writes: > On Mon, Dec 5, 2011 at 1:18 PM, Yann ROBIN wrote: >> kill -9 of the writer process > Are you sure you killed all the postgres backends before restarting > the server? If other backends are still running, with a dead > postmaster, and you restart the server, instant corru

Re: [ADMIN] Database corrupted

2011-12-05 Thread Kevin Grittner
Scott Marlowe wrote: > Yann ROBIN wrote: >> Version 9.0.4 on debian squeeze 6.0 running in KVM with virtio >> (kernel 2.6.32) I don't know anything about KVM or vertio, so hopefully others will step up. >> I think we have a hard drive issue. If at all possible, I would try to sort that ou

Re: [ADMIN] Database corrupted

2011-12-05 Thread Scott Marlowe
On Mon, Dec 5, 2011 at 1:18 PM, Yann ROBIN wrote: >> >> First things first: Before you do anything else, shut down >> PostgreSQL and make a copy of the data directory tree. >> >> http://wiki.postgresql.org/wiki/Corruption >> > > Did it. > >> Second, please post information about your environment.

[ADMIN] Recover from failover

2011-12-05 Thread Martin S
Hello list, May be this information is inside the documentation, but couldn't find it. I'm doing some tests with postgres 9.1.1 and replication, and I was wandering if there is some information about how to recover from a failover. Suppose I'm doing some kernel upgrades on the master, so in orde

Re: [ADMIN] Database corrupted

2011-12-05 Thread Yann ROBIN
> > First things first: Before you do anything else, shut down > PostgreSQL and make a copy of the data directory tree. > > http://wiki.postgresql.org/wiki/Corruption > Did it. > Second, please post information about your environment.  What > version of PostgreSQL is this?  What is your OS?  What

Re: [ADMIN] Database corrupted

2011-12-05 Thread Kevin Grittner
Yann ROBIN wrote: > Earlier this afternoon, our database crash with a stacktrace. First things first: Before you do anything else, shut down PostgreSQL and make a copy of the data directory tree. http://wiki.postgresql.org/wiki/Corruption Second, please post information about your environm

[ADMIN] Database corrupted

2011-12-05 Thread Yann ROBIN
Hi, Earlier this afternoon, our database crash with a stacktrace. We killed hardly the remaining postgres process left. Since then it's been hell !!! First Postgres told us that there was a corrupted index and we needed to reindex it. We couldn't do it because there was duplicate id in the table.