Re: fragmentation of a tablespace

From: Sean Kubovcik <sean.kubovcik_at_worldnet.att.net>
Date: 1996/11/25
Message-ID: <3299BD5B.1DC2_at_worldnet.att.net>#1/1


Kevin Loney wrote:
>
> ythorne_at_acs.neu.edu wrote:
> >
> > Is it possible to defrag a tablespace without exporting/importing the
> > entire database?
> >
>
> Sure:
> 1. Export the database (alternatively, perform User exports of the
> users who own objects in the Harvest tablespace - see DBA_SEGMENTS).
> 2a. Drop the tablespace, including contents, then re-create the tablespace.
> or
> 2b. Drop the objects in the tablespace. force the space to be coalesced
> by creating a single large table in the tabelspace.
> 3. Import the objects back into the tablespace. If you performed a
> full system export, you'll need to specify FROMUSER and TOUSER in your
> IMP command so that you only bring back objects from the users who
> owned objects in Harvest.
>
> If your users are segregated by tablespace, this process is simpler.
>
> KevinI'm a new DBA, but I was looking at our defrag process and the prior DBA
created a batch script that runs once a week and exports the entire database, drops all tables and imports the database. This seems to work, but it takes about 7 hours. Is this effective? Thanks,
Sean Received on Mon Nov 25 1996 - 00:00:00 CET

Original text of this message