Creating a database on sql 2005 taking longer time

  • I am creating a database using Management Studio with two filegroups with 600GB and 300 GB each and it is still running for more than two hr. There is no error but it is showing Exeuting.

    I ran the sp_who2 command and found that there is no CPUtime and DISKIO is increasing.

    Should I stop it?

  • I did a quick test, and created a 20 GB database, took about 4-5 minutes, and ran completely. I'm on a developper machine, not too quick.

    Few things:

    1. Sp_who2 returned about no IO or CPU usage for the database, so I think this is not logged.

    2. Maybe you don't have enough disk space, or need a defrag for the file to fit correctly?

    3. Maybe you have a Mirror disk that is sooooo slow, like our prod server, which runs 10 times slower then my dev machine?

    In any case, I would let the command run for a while, still, and see what happens. Do you see the files growing slowly in the data directory?

    Cheers,

    J-F

  • Initializing files that size will take a while, even on a blazing fast machine. Give it some time.

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • Thanks guys, It's done, It took little time though

  • Now you can validate whether or not instant initialization has been set up. If SQL Server is running under a domain service account that is not a part of the local Administrator's group - then you probably do not have it enabled for that user.

    If it is enabled, then it took as long as it needed to create the files.

    Jeffrey Williams
    “We are all faced with a series of great opportunities brilliantly disguised as impossible situations.”

    ― Charles R. Swindoll

    How to post questions to get better answers faster
    Managing Transaction Logs

Viewing 5 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic. Login to reply