Results 1 to 12 of 12
  1. #1
    Join Date
    Aug 2008
    Location
    Toronto, Canada
    Posts
    2,367

    Unanswered: tablespace with multiple containers

    I will be migrating (via a restore) and changing the FS for db2 (placing the instance home, tablespaces, active and archive logs, backups... on separate mount points). Currently, one tablespace is setup with 4 containers on the same FS/mount point/hdisk. I don't think this hdisk is a single disk (RAID ?), but IF it's really only one spindle, does it make sense to have more than one container? Is there a way to tell how many spindles a FS/mount point is spread over without asking SA/SAN admin?

  2. #2
    Join Date
    Jun 2003
    Location
    Toronto, Canada
    Posts
    5,516
    Provided Answers: 1
    Quote Originally Posted by db2girl View Post
    IF it's really only one spindle, does it make sense to have more than one container?
    It's basically an alternative to specifying DB2_PARALLEL_IO. When DB2 sees 4 containers, it is inclined to issue 4 parallel I/O requests, so it depends on the physical storage ability to handle parallel I/O.

    Quote Originally Posted by db2girl View Post
    Is there a way to tell how many spindles a FS/mount point is spread over without asking SA/SAN admin?
    Not likely, unless you're using the server internal drives.

  3. #3
    Join Date
    Aug 2008
    Location
    Toronto, Canada
    Posts
    2,367
    Quote Originally Posted by n_i View Post
    It's basically an alternative to specifying DB2_PARALLEL_IO. When DB2 sees 4 containers, it is inclined to issue 4 parallel I/O requests, so it depends on the physical storage ability to handle parallel I/O.
    Does it make sense to issue 4 parallel I/O requests if it's only one spindle?

  4. #4
    Join Date
    Jun 2003
    Location
    Toronto, Canada
    Posts
    5,516
    Provided Answers: 1
    Quote Originally Posted by db2girl View Post
    Does it make sense to issue 4 parallel I/O requests if it's only one spindle?
    If it's an internal disk, probably not. If it's a more intelligent storage system, it might.

  5. #5
    Join Date
    Nov 2011
    Posts
    334
    I am not sure . But if the container is read/write frequently,
    There might be some io contention on the disk for putting 4 containers on one physical disk。

  6. #6
    Join Date
    Aug 2008
    Location
    Toronto, Canada
    Posts
    2,367
    I got some info from our storage guy:
    Storage is DS8000, RAID type is RAID 5. In a rank of 8 disks, RAID 5 is 6 + 1 (parity) + 1 (spare). LUNs are created in a RAID rank and spread over 6 disks.



    Does this mean each hdisk I see in iostat output = 6 active spindles?

    So, each AIX filesystem/mount point (ie. tablespace FS) maps to a single hdisk (I can see this from lsvg/lspv output) which is backed by a array/LUN of 6 spindles?

  7. #7
    Join Date
    Jun 2003
    Location
    Toronto, Canada
    Posts
    5,516
    Provided Answers: 1
    Yes and yes.

  8. #8
    Join Date
    Nov 2011
    Posts
    334
    According to the ibm document, you can set DB2_PARALLEL_IO=*:6 to let db2 splitting one prefetch request into 6 to fetch data from per disk parallelly。
    But because of your container located on the same raid group。I think maybe it will not improve io performance
    you can do testing on it.....
    Last edited by fengsun2; 03-27-12 at 22:49.

  9. #9
    Join Date
    Aug 2008
    Location
    Toronto, Canada
    Posts
    2,367
    It depends on which ibm doc you read, some suggest to include and some to exclude the parity disk. See: http://www.dbforums.com/db2/1662061-...rallel_io.html

    DB2_PARALLEL_IO is not set so it will default to 6, which is fine for our env.


    I'm still trying to understand why they created multiple containers for this tablespace (the only db I've seen so far that has a tablespace with multiple containers). This is the largest db/tablespace, but it's still relatively small. Is there any advantage in using multiple containers if all are on the same array/LUN?

  10. #10
    Join Date
    Jun 2003
    Location
    Toronto, Canada
    Posts
    5,516
    Provided Answers: 1
    Quote Originally Posted by db2girl View Post

    DB2_PARALLEL_IO is not set so it will default to 6, which is fine for our env.

    I don't think that's how it works. If DB2_PARALLEL_IO is not set at all, parallelism will be determined by the number of containers. If DB2_PARALLEL_IO=*, that is, the parallelism degree is not specified, it is assumed to be 6.

  11. #11
    Join Date
    Aug 2008
    Location
    Toronto, Canada
    Posts
    2,367
    Quote Originally Posted by n_i View Post
    I don't think that's how it works. If DB2_PARALLEL_IO is not set at all, parallelism will be determined by the number of containers. If DB2_PARALLEL_IO=*, that is, the parallelism degree is not specified, it is assumed to be 6.
    You're correct, Nick. Thx

  12. #12
    Join Date
    Nov 2011
    Posts
    334
    Maybe the best way is to create one container cross the 6 physical disks and set DB2_PARALLEL_IO=*:6 in your case。

    Under the present circumstances(4 containers), if DB2_PARALLEL_IO is not set, then prefech request will be splitted into 4 to fetch data from each container parallely, but because of each contanier span cross the whole raid group ,maybe these 4 prefechs are read data from one physical disk。if setting DB2_PARALLEL_IO =*:6, then each prefetch will be splitted into 24(4*6) to fetch data, There must be io contetion for we just have 6 physical disk ( each disk will service 4 prefetch request concurrently) 。
    My English is not so good, hope you can understand what i said above

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •