SQLServer 7 Errorlog

  • Hi guys,

    Probably a very naive question you may be able to answer here, but in an new implementation of SQLServer 7, I have seen the following messages in the Errorlog :

    2003-02-28 13:32:23.12 spid12 Starting up database 'Main'.

    2003-02-28 13:32:23.12 spid12 Opening file D:\MSSQL7\data\'Main_Data.MDF.

    2003-02-28 13:32:23.14 spid12 Opening file D:\MSSQL7\data\'Main_Log.LDF.

    2003-02-28 13:32:23.24 spid12 Closing file D:\MSSQL7\data\'Main_Data.MDF.

    2003-02-28 13:32:23.26 spid12 Closing file D:\MSSQL7\data\'Main_Log.LDF.

    200

    Has this got anything to do with Auto close ? If so, I have just turned this off, so should I just see the "Starting" and "Opening", and if so when should it "Close" ? At server shutdown ?

    Is it an interface logging in and out ?

    Thanks

    Dave

  • Yes, that is because of the Auto Close option. If it is set, SQL server automatically closes the database when the last user connected to the database disconnets.

    Normally, all databases are open and ready for access. And when you stop the sql service, all databases are closed before shittng down.

  • Thanks for the quick response !

    I have heard that switching off Auto close will enhance performance during a working day.

    What is the general recommendation for Auto close - on or off ?

    Dave

  • Well if you are acceding your databases frecuently, then you should live them opened all time. Imagine that if you live auto close on, then every time a users want to connects (and the db is closed) SQL has to mount and open the db. There are a lot of process that runs when SQL opens databases, so you should live then open.

    You could use the autoclose on, for example if you (and only you) use the pubs database for testing. If you one day wnat to try a new script or what ever, then use it that they, and then live it close.

    But remember that SQL is intended to be used will the databases fully operational.

  • Thanks for the tip.

    Dave

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

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