Results 1 to 8 of 8
  1. #1
    Join Date
    Dec 2003
    Posts
    14

    Unanswered: database devices

    I've added a device for the tempdb log file and I assigned the full amount to that database. Now I want to reduce the amount I have allocated to that database so I can share the device. Is there a way to reduce what I have allocated or is there a way that I can delete the device and start over. I have tried removing it but I can't get it to release from the tempdb.

    Cheers,
    ColdFire

  2. #2
    Join Date
    Feb 2002
    Location
    Willy is on vacation
    Posts
    1,208
    Just ensure that that the tempdb fragment on master device is still available for allocation and also that it is >= model database size.

    If the above condition matches, then you can safely delete the new tempdb fragment that you have created, then stop and restart ASE. Now do you changes however you like.

  3. #3
    Join Date
    Dec 2003
    Posts
    14
    I'm still kind of new with some fuctions of sybase so can you give me a some instructions on how to go about checking if the tempdb fragment on master device is still available for allocation and also how to check that it is >= model database size.
    COLDFIRE

  4. #4
    Join Date
    Nov 2002
    Location
    Switzerland
    Posts
    524
    Provide us the output of

    Code:
    select db_name(dbid) DB, segmap, size/512 MB, name 
    from master..sysusages, master..sysdevices 
    where dbid=db_id("tempdb") -- should be 2
    and lstart between low and high

  5. #5
    Join Date
    Dec 2003
    Posts
    14
    1> select db_name(dbid) DB, segmap, size/512 MB, name
    2> from master..sysusages, master..sysdevices
    3> where dbid=db_id("tempdb") -- should be 2
    4> and lstart between low and high
    5> go
    DB segmap MB
    name
    ------------------------------ ----------- -----------
    ------------------------------
    tempdb 7 3
    master
    tempdb 7 3
    tapedump1
    tempdb 7 3
    tapedump2
    tempdb 0 200
    master
    tempdb 0 200
    tapedump1
    tempdb 0 200
    tapedump2

    (6 rows affected)

  6. #6
    Join Date
    Nov 2002
    Location
    Switzerland
    Posts
    524
    Sorry, I forgot to request the sort order

    Code:
    select convert(char(10),db_name(dbid)) DB, 
             convert(char(15), name) DEV,
             segmap, 
             size/512 MB
    from master..sysusages, master..sysdevices
    where dbid=db_id("tempdb") -- should be 2
    and lstart between low and high
    order by lstart
    go

  7. #7
    Join Date
    Dec 2003
    Posts
    14
    1> select convert(char(10),db_name(dbid)) DB,
    2> convert(char(15), name) DEV,
    3> segmap,
    4> size/512 MB
    5> from master..sysusages, master..sysdevices
    6> where dbid=db_id("tempdb") -- should be 2
    7> and lstart between low and high
    8> order by lstart
    9> go
    DB ----- DEV --------- segmap --- MB
    ---------- ------ ----------- -----------
    tempdb master ------ 7 ------- 3
    tempdb tapedump1 -- 7 ------- 3
    tempdb tapedump2 -- 7 ------- 3
    tempdb master ------ 4 ------- 500
    tempdb tapedump1 -- 4 ------- 500
    tempdb tapedump2 -- 4 ------- 500

    (6 rows affected)

  8. #8
    Join Date
    Dec 2003
    Posts
    14
    Can anybody help me with this issue or refere me to a good site or book?
    COLDFIRE

Posting Permissions

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