July 1, 2008 at 5:31 am
hi
i have restore the database use .TRN file in sheduling to one hour . the database is read only and stand by mode. i have shrink log file . but in read only mode the dbcc shrink file is not posible.
1) how can i use the dbcc shrink file to minimize the size of .ldf file .
2) i have remove the read only mode of database then i can posible to restore the database use in .TRN File
i should expect user experience
July 1, 2008 at 5:36 am
Why do you want to shrink the log?
If you bring the database online, you will not be able to restore more log backups.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
July 1, 2008 at 5:44 am
1) how can i use the dbcc shrink file to minimize the size of .ldf file
I'm not sure about this, I hope the source servers log file is copied to destination!
2) i have remove the read only mode of database then i can posible to restore the database use in .TRN File
If you bring the database out of read only mode, then you won't be able to restore transaction logs in future.
Regards..Vidhya Sagar
SQL-Articles
July 1, 2008 at 5:49 am
thanks to reply all
i have shrink the .ldf log file of database. becouse increse the size of log file
July 1, 2008 at 5:57 am
You cannot without recovering the database and making it impossible to apply more log file backups.
November 23, 2011 at 5:48 pm
Use Databse name
ALTER DATABASE database-name SET READ_WRITE
and then run the DBCC Shrinkfile('Logfilename', Size)
Take the Full backup.
And then
ALTER DATABASE database-name SET READ_ONLY
there is only option if you want to shrink the readonly Log File
November 24, 2011 at 2:06 am
Please note: 3 year old thread. And the DB is not read-only, it's in STANDBY.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
Viewing 7 posts - 1 through 6 (of 6 total)
You must be logged in to reply to this topic. Login to reply