Results 1 to 2 of 2
  1. #1
    Join Date
    Mar 2004
    Posts
    99

    Unanswered: Model DB problem..

    attempted to move my Model and msdb database files to a different drive on the server. I did the following:
    * Restarted SQL Server 2K with the -T3608 startup parameter
    * successfully detached msdb and model DBs
    * moved the msdbdata.mdf, msdblog.ldf, model.mdf and modellog.ldf
    files to their new homes
    * successfully reattached model and msdb

    When I take away the -T3808 startup parameter and restart SQL Server, I do not see the model database in the db list in enterprise manager eventhough my 'attach' seemed to work. Now I get the following error when i try and query against the Model database using query analyzer:

    "Could not locate entry in sysdatabases for database 'model'. No entry found with that name. Make sure that the name is entered correctly"

    Also, when I look in the sysaltfiles table in Master, I see no reference whatsoever to the Model DB

    What did I do wrong?

  2. #2
    Join Date
    Dec 2002
    Posts
    1,245
    Quote Originally Posted by jpotucek
    attempted to move my Model and msdb database files to a different drive on the server. I did the following:
    * Restarted SQL Server 2K with the -T3608 startup parameter
    * successfully detached msdb and model DBs
    * moved the msdbdata.mdf, msdblog.ldf, model.mdf and modellog.ldf
    files to their new homes
    * successfully reattached model and msdb


    What did I do wrong?
    Ouch! I HATE it when that happens. Here's a link, you've probably already read it (here).

    I would (in more or less this order):
    1. Look carefully at the SQL Error log
    2. Restart with -T3608 and attempt to re-attach model
    3. Restore model from a backup (you did have a backup, right?)

    I seem to recall from a distant memory that when you moved msdb and model, there was a particular sequence (one HAD to be done before the other). [Edit: here it is, smack in the middle of the link above].

    Quote Originally Posted by Microsoft
    Note If you are using this procedure together with moving the msdb
    and model databases, the order of reattachment must be model first
    and then msdb. If msdb is reattached first, it must be detached and
    not reattached until after model has been attached.
    I can't tell for certain from the steps you outline above which you did first.

    I have used this procedure to move model, master, msdb and tempdb on several different occasions with no trouble at all (sorry, that doesn't help you, but I did want to verify that the steps outlined above DO work). As I recall, I usually make it a point to move msdb and model in separate steps (restarting SQL Server in between moving these two dbs).

    Best of luck,

    hmscott
    Last edited by hmscott; 11-01-05 at 00:30.
    Have you hugged your backup today?

Posting Permissions

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