database restore file name

  • I tried to use SQL management studio to restore database from one server to another server. They are both sql server 2005.

    When I restore I want to check if the file path is correct, so I click option tab, then I can see database file logical names, and the file path. The thing I noticed different is the log file name. I remember sometime before when I did restore the default log file name is mydb_log.ldf, but now it is something like mydb_1.ldf. I can certainly change the name to _log. But I remember it used to be default like that. Is this anything new? Or I missed something.

    Thanks

  • The logical file name should not change unless explicitly changed by someone. Is it just yourself who run this server?

  • It's not logical name.

    What I mean is the physical file name.

  • is it possible that your database has more than one file to it.. or a file in the past that was deleted and then readded? By default you are correct it should be _log.

    Good Luck

    DHeath

    DHeath

  • Thank you.

    I can see in the original server we only have one ldf file for that database, it is called mydb.ldf. we never deleted or added before.

    But on the new server, when I move/restore, on the option tab, the file path is database default location, the file name one is mydb.mdf, the log file is mydb_1.ldf.

    I think it may try to create the same name, only extensions are different. Since there is already a file with the same name, it tried to create _1 file, instead of _log.

    I didn't see this before. The only difference is the new server is a windows 2008, the old OS is windows 2003.

    The sql server version are the same though.

    I think I will just have to manually change the name to _log. Thanks

  • But why does it matter to you though whether is it _log or _1??

    Why don't you restore using the TSQL?

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

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