Skip site navigation (1) Skip section navigation (2)

Re: Cannot DROP while process running

From: Steve Horn <steve(at)stevehorn(dot)cc>
To: pgsql-novice(at)postgresql(dot)org
Subject: Re: Cannot DROP while process running
Date: 2012-04-09 19:46:24
Message-ID: CAFLkBaW6KpCXGnL64621AJP3H7DdzSELNbnorVbwe6Jnvyt6cA@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-novice
That should have said " The only table with a lock or any activity is
'public. vertices_tmp'.

On Mon, Apr 9, 2012 at 3:38 PM, Steve Horn <steve(at)stevehorn(dot)cc> wrote:

> I am on Postgres 9.1 and running into a problem when trying to drop a
> table in my public schema.
>
> When I issue the drop command for a table, the server doesn't respond -
> not even with increased disk activity or CPU usage. I am wondering if a
> lock is blocking it? When I select from pg_stat_activity the table I am
> intending on dropping is not listed as having anything actively using it.
>
> The only table with a lock or any activity is 'public.raw_tomtom'.
>
> mapping=# select datname, procpid, current_query from pg_stat_activity;
>  datname  | procpid |                                  current_query
>
> ----------+---------+----------------------------------------------------------------------------------
>  postgres |    3944 | <IDLE>
>  mapping  |    3945 | <IDLE>
>  mapping  |   16193 | SELECT * FROM public.assign_vertex_id('raw_tomtom',
> 0.00001, 'the_geom', 'gid');
>  mapping  |   25456 | <IDLE>
>  mapping  |   20897 | autovacuum: VACUUM ANALYZE public.raw_tomtom
>  mapping  |   20405 | LOCK TABLE public.vertices_tmp IN ACCESS SHARE MODE
>  mapping  |   19461 | LOCK TABLE public.vertices_tmp IN ACCESS SHARE MODE
>  mapping  |   17570 | <IDLE>
>  mapping  |   20466 | LOCK TABLE public.vertices_tmp IN ACCESS SHARE MODE
>  postgres |   20874 | <IDLE>
>  mapping  |   20976 | select datname, procpid, current_query from
> pg_stat_activity;
>  mapping  |   20609 | <IDLE>
>  mapping  |   20876 | <IDLE>
>
> *procpid 16193 "SELECT * FROM ..." is a long running process that would
> not be touching the table I am trying to drop.
>
> Thanks for any help!
>
> --
> Steve Horn
>
>


-- 
Steve Horn

In response to

pgsql-novice by date

Next:From: Tom LaneDate: 2012-04-09 20:08:55
Subject: Re: Cannot DROP while process running
Previous:From: Steve HornDate: 2012-04-09 19:38:27
Subject: Cannot DROP while process running

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group