X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 4992C8B9EBC for ; Wed, 23 Feb 2005 05:42:18 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 48638-08 for ; Wed, 23 Feb 2005 05:42:16 +0000 (GMT) Received: from rproxy.gmail.com (rproxy.gmail.com [64.233.170.197]) by svr1.postgresql.org (Postfix) with ESMTP id 0A65E8B9EAB for ; Wed, 23 Feb 2005 05:42:16 +0000 (GMT) Received: by rproxy.gmail.com with SMTP id j1so624656rnf for ; Tue, 22 Feb 2005 21:41:42 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:reply-to:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:references; b=T2/wOW+j9lvVtiM4jEmPBShy+74NeD04J+YlHxd2IMm0n0PFiBsia6wQJwyYMdclven4ZQL2t5aOhFvzV1foYQKpT4DEwkapPKXcIrK/jdCA5eRiab329+iuQYy4E3NU4922aQFgImftvxoLnrCqGJup8OJq8GcGE1qbjIAv+kU= Received: by 10.38.97.7 with SMTP id u7mr109400rnb; Tue, 22 Feb 2005 21:41:41 -0800 (PST) Received: by 10.38.97.43 with HTTP; Tue, 22 Feb 2005 21:41:41 -0800 (PST) Message-ID: <674d1f8a050222214138bc53b9@mail.gmail.com> Date: Wed, 23 Feb 2005 11:11:41 +0530 From: Gourish Singbal Reply-To: Gourish Singbal To: pgsql-admin@postgresql.org Subject: Re: dropdb: database removal failed: ERROR: database "database_name" is being accessed by other users In-Reply-To: <674d1f8a0502210621233cf44e@mail.gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit References: <674d1f8a0502210621233cf44e@mail.gmail.com> X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.071 tagged_above=0 required=5 tests=AWL, RCVD_BY_IP X-Spam-Level: X-Archive-Number: 200502/252 X-Sequence-Number: 16420 Guys, postgres : 7.4.5 Os: linux I need to restore my back up database with production data. the steps i follow on backup database are:- 1) dropdb 2) createdb 3) psql or pg_restore to import data into the backup database. Am i doing the correct steps?. Problems:- If some clients are connected to the backup database during the 1st Step (dropdb) the postmaster throws an error saying clients connected cannot drop database. Any solution to the above problem would be great... regards gourish On Mon, 21 Feb 2005 19:51:10 +0530, Gourish Singbal wrote: > This Error message was given when i was dropping the database. > There are idle connections to the database as seen from ps -ef | grep postgres > > How can i drop the database with out restarting the postgres server.?. > > FYI: i am dropping the database to perform restoration of this backup > database using psql from production. > > -- > Best, > Gourish Singbal > -- Best, Gourish Singbal