Restore database with no log



I'm trying to restore a database backed up a production machine onto
my development machine. I don't want to restore the transaction logs
(there are two) because they are far too large and are unnecessary for
what I'm doing. I would be happy to simply create one new log in my
development environment. Therefore, I backed up the database using
the No_Log option as in

backup database CPTS to disk = 'd:\backups\cpts_backup_billeh.bak'
with no_log

I took the backup file and I'm able to restore it on my development
machine with

RESTORE DATABASE [CPTS] FILE = N'CPTS_Data' FROM DISK = N'D:\archives
\Citrix\CPTS\SupportingMaterials\cpts_backup_billeh.bak' WITH MOVE
'CPTS_Data' TO 'd:\databases\CPTS.mdf', MOVE 'CPTS_Log' TO 'd:
\databases\CPTS_log.ldf', MOVE 'CPTS_1_Log' TO 'd:\databases
\CPTS_1_log.ldf'

Note that I cannot additionally specify FILE = N'CPTS_Log' or FILE =
N'CPTS_1_Log' because I get an error.

The restore created the CPTS_Data file only and returned the message

Processed 415664 pages for database 'CPTS', file 'CPTS_Data' on file 1.
The database cannot be recovered because the log was not restored.<<

What additional step should I take to create a log file? I thought
that No_Log was supposed to give me a truncated log file but it didn't
seem to do so.

Is there another way around this problem? I tried taking the the
resulting mdf file and attaching it using sp_attach_single_file_db but
this didn't work either.

Thanks,

Bill E.
Hollywood, FL

.



Relevant Pages

  • Re: Fehler 1018
    ... Also nicht die Transaktionslogs auf der Festplatte ... When the No loss Restore option is selected, the existing transaction logs on the Exchange 2000 server are preserved. ... Transaction logs from the storage media are then restored and added to the existing set of transaction logs on the Exchange 2000 server. ...
    (microsoft.public.de.german.exchange2000.general)
  • Re: database restored to reporting server--why are trans. logs so big?
    ... You will only gain some disk during the day and the following night the "full" amount of disk need to be available for the restore to succeed. ... You have to have the space available to perform the restore in the first place and the file is going to get created again at the larger size the following night. ... On reporting server, no data gets added or changed. ... p.s. I've read everything I could find about transaction logs in the ...
    (microsoft.public.sqlserver.programming)
  • Re: merging transaction log files
    ... After the restore....nothing would ... >transaction log files out of the mdbdata folder to a backup folder and than ... The transaction logs you have would have been committed to the ... database, just not the old database you have. ...
    (microsoft.public.exchange.admin)
  • Re: Did backing up the tail create another transaction log?
    ... RESTORE HEADERONLY shows that there are only 3 transaction logs. ... Now the database needs to be recovered. ... Links for SQL Server Books Online: ...
    (microsoft.public.sqlserver.server)
  • Trouble moving db to another sql2005
    ... error that the on disk structure was 611 and the production machine ... But that is the console, ... I don't even know if a restore will actually accomplish my goal of ... machine and a test server, but apparently the production server is a ...
    (microsoft.public.sqlserver)

Loading