Increasing Database Size

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • sandyboy
    New Member
    • May 2007
    • 16

    Increasing Database Size

    Hi,

    Please help me to solve this problem. My database size is 8 GB , 5GB of data file and 3GB of log file. I increased the size of datafile to 10GB and log file to 3.5 GB with 11GB and 4GB by 20 MB autogrowth. After increasing i checked the data file using sp_spaceused and it was 10 GB.But after 30-45 minutes, when i check the database size, it has reduced to 5GB and 3GB. But the autogrowth is 11GB and 4GB.I am not able to increase the intial size.I dont know what is wrong. I have disk space of more than 25GB.

    Can anybody please suggest me what is going wrong here.
  • Purple
    Recognized Expert Contributor
    • May 2007
    • 404

    #2
    Hi sandyboy,

    What version of MSSQL server are you running ?

    Answer for SQL 2000 - If you have autoshrink set on for the database, all of the database files are candidates for periodic shrinking. This applies to both data and log files. The log files will shrink at the point the log is backed up or trucated.

    I am assuming the same behavior under 2005 but would need to check..

    Purple

    Comment

    • Purple
      Recognized Expert Contributor
      • May 2007
      • 404

      #3
      Hi Sandyboy,

      to preempt the next question, in enterprise manager, rightclick on the database, select the options tab and untick autoshrink.

      Let us know if this does the trick

      Kind Regards

      Purple

      Comment

      • sandyboy
        New Member
        • May 2007
        • 16

        #4
        Thanks Purple for replying. Let me try this and get back to you.

        This is unusual. My server machine is SQL 2000 and the client machine is SQL 2005.I hope thats why i have problem.

        Comment

        • Purple
          Recognized Expert Contributor
          • May 2007
          • 404

          #5
          Hi Sandyboy,

          I have just checked my SQL2005 server and :

          right click database => properties => options vertical tab => auto shrink

          options are now true or false, appears to be false by default..

          Regards Purple

          Comment

          • sandyboy
            New Member
            • May 2007
            • 16

            #6
            Hi Purple,

            Thanks for your advice. I had once changed autoshrink to true. But now i changed to false and increased the size.Its been more than 2 hours and i think its has not changed to 8gb again. Its 11GB. So i think it worked. But i am planning to observe the whole day. If it does not roll back to 8GB, then it is solved. Once again thanks for your sincere follow-up.

            Comment

            • Purple
              Recognized Expert Contributor
              • May 2007
              • 404

              #7
              Hey Sandyboy,

              We are here to help - am pleased you appear to have solved the problem, I look forward to seeing you around in the future.

              Regards Purple

              Comment

              Working...