Freeing Db2 table spaces


Table spaces can be freed from the Inuse Table Space List panel or by using the FREE command. Select the Free up table spaces option from the Operational Assist Menu to display the Inuse Table Space List panel, which lists table spaces being accessed or used on the target Db2 system.

Inuse Table Space List panel

DDTG DBI1 Inuse Table Space List    Row 1 of 42
Command ===> ________________________________________________ Scroll ===> PAGE

 Commands: ZPARMS
FILTER
Select the desired table space(s). Then press Enter.
F=Free S=Stop SF=Stop and free sync U=User list
FS=Free sync SS=Stop Sync SN=Stop and free P=Partition list

Act Target Catalog Database Table Space
.. DBDM ABMDBDM ABMTS00
.. DBDM ABMDBDM ABMTS00C
.. DBDM DSNDB06 DSNKDX01
.. DBDM DSNDB06 DSNKKX02
.. DBDM DSNDB06 DSNPPH01
.. DBDM DSNDB06 SYSPKAGE
.. DBDM DSNDB06 SYSSTATS
.. DBDM DSNDB06 SYSVIEWS
.. DBDM DBDMCAT ABMDBDM ABMTS00X
.. DBDM DBDMCAT DSNDB01 DBD01
.. DBDM DBDMCAT DSNDB06 DSNADH01
.. DBDM DBDMCAT DSNDB06 DSNADX01
.. DBDM DBDMCAT DSNDB06 DSNAGH01

Use this panel to perform the actions that are listed in the following table:

Command

Description

Free (F)

Cancels all users currently accessing the table space

The table space is not stopped and control might be returned to you before all of the canceled threads actually terminate.

Free sync (FS)

Stops a table space and then cancels all users currently accessing the table space

When the table space stops (that is, when all of the threads terminate), the table space restarts and control is returned to you.

Stop (S)

Stops the table space

No threads are canceled and control might be returned to you before the table space actually stops.

Stop sync (SS)

Stops a table space

No users are canceled and control is returned to you after the table space actually stops.

Stop and free sync (SF)

Stops a table space and then cancels all users currently accessing the table space

Control is returned to you after the table space actually stops.

Stop and free (SN)

Stops a table space and then cancels all users currently accessing the table space

Control might be returned to you before all of the canceled threads actually terminate.

User list (U)

Displays a list of the current users of the table space

From the list, you can cancel individual users.

Partition list (P)

Displays a list of table space partitions that are in use

ZPARMS

FILTER

FILTER displays the Table Space Filter Specification panel. Use this panel to restrict the table spaces displayed.

To free table spaces

  1. On the Inuse Table Space List panel, type one of the following commands next to the table space you want to free:
    • F
    • FS)
    • S
    • SS
    • SF
    • SN
  2. Press Enter.
  3. Issue the command from the Command Confirmation panel by typing 1 in the selection field and pressing Enter. To cancel the command, type 2 in the selection field and press Enter.

To cancel a user for a particular table space

  1. On the Inuse Table Space List panel, type U next to the table space whose users you want to cancel.
  2. Press Enter.
  3. From the panel, select a user who you want to cancel, and press Enter.
  4. Issue the command from the Command Confirmation panel by typing 1 in the selection field and pressing Enter. To cancel the command, type 2 in the selection field and press Enter.

To filter table spaces

If the list of table spaces on the Inuse Table Space List panel is too long, you can filter the threads.

  1. Type FILTER on the Command line and press Enter.

    The Table Space Filter Specification Panel allows you to filter the display of threads or connections by the following ways:

    • Catalog name
    • Database name
    • Table space name
    DDTG DBI1 Table Space Filter Specification
    Command ===> _________________________________________________________________

    Update the entries below to specify how the table space list should be filtered. Then press Enter.

    Filter Information
    Catalog name . . . . . . . .________
    Database name . . . . . . . ________
    Table space name . . . . . .________
  2. Type the information you want to use to filter the threads into the appropriate fields, and press Enter. You can use wildcards as follows:
  • ? can be substituted for any single character
  • * can be substituted for one or more characters at the end of a specification

You will be returned to the Inuse Table Space List panel, but the table spaces will be filtered according to your specifications.

To free table spaces using the FREE command

The syntax for the FREE command is as follows:

IN(<DB2ssid@opertuneID>) STOP

Command syntax and parameters

image2018-12-26_13-43-23.png

Value

Description

DB2ssid

Db2 subsystem ID or the name of the Db2 data sharing group to which the command applies.

opertuneID

OPERTUNE system profile name (if OPERTUNE is running as a started task) or the batch job name (if OPERTUNE is running as a batch job).

FREE (without SYNC and
STOP)

All users currently using the table space are canceled. The table space is not stopped. Control might return to the requester before all of the canceled threads actually terminate.

FREE with SYNC

The table space is stopped. All users currently accessing the table space are then canceled. When all of the treads terminate, the table space is started again. Control is then returned to the requester.

FREE with STOP

The table space is stopped. All users currently accessing the table space are then canceled. Control might return to the requester before all of the canceled threads actually terminate.

FREE with SYNC and STOP

The table space is stopped. All users currently accessing the table space are then canceled. Control is not returned to the requester until the table space actually stops.

catalog1

The VCAT name or an alias entry for the table space.

database1

The name of the database that resides in the table space.

tableSpace1

The name of the table space to be freed.

partition

The number of the table space partition to be freed. If this value is not specified, the entire table space is freed.

1 The following wildcards are permitted:

  • ? can be substituted for any single character
  • * can be substituted for one or more characters at the end of the specification

To free table spaces using the STOP command

The syntax for the STOP command is as follows:

IN(<DB2ssid@opertuneID>) STOP

Command syntax and parameters

image2018-12-26_13-50-26.png

Value

Description

DB2ssid

Db2 subsystem ID or the name of the Db2 data sharing group to which the command applies.

opertuneID

OPERTUNE system profile name (if OPERTUNE is running as a started task) or the batch job name (if OPERTUNE is running as a batch job).

STOP (without SYNC)

The table space is stopped. No threads are canceled. Control might return to the requester before the table space actually stops.

STOP with SYNC

The table space is stopped. No threads are canceled. Control is returned to the requester after the table space actually stops.

catalog1

The ICF catalog that contains the entry for the table space.

database1

The name of the database that contains the table space.

tableSpace1

The name of the table space to be stopped.

partition

The number of the table space partition to be stopped. If this value is not specified, the entire table space is freed.

1 Wildcards are not permitted.

 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*