What are the challenges you face when working across database platforms? Take the survey

Log Shipping for Multiple Databases

codeskicodeski Posts: 2
edited August 10, 2011 11:55AM in SQL Backup Previous Versions
When using log shipping for multiple databases is it necessary to have the transaction log backups created in different directories? Or can I have all the backups exist in one directory and the SQL Backup software will know which log exists for each database?



  • Options
    peteypetey Posts: 2,358 New member
    When SQL Backup restores the t-logs, it uses a search pattern to determine which files to process, so something like this:
    EXEC master..sqlbackup '-sql "RESTORE LOG adventureworks FROM DISK = [e:\backups\adventureworks_log_*.sqb] WITH NORECOVERY"'
    will only pick up all files matching the adventureworks_log_*.sqb pattern.

    So yes, you can place all the t-logs in a single directory, just as long as the pattern you are using to identify the t-log backup files are unique to each database in each restore task.
    Peter Yeoh
    SQL Backup Consultant Developer
    Associate, Yohz Software
    Beyond compression - SQL Backup goodies under the hood, updated for version 8
Sign In or Register to comment.