Standby-file location in log-shipping

  • Is there a query I can use to find the location (path) of the standby file in a log-shipping configuration?

    __________________________________________________________________________________
    SQL Server 2016 Columnstore Index Enhancements - System Views for Disk-Based Tables[/url]
    Persisting SQL Server Index-Usage Statistics with MERGE[/url]
    Turbocharge Your Database Maintenance With Service Broker: Part 2[/url]

  • Usually its set to the secondary destination directory which you can get from the following

    exec sp_help_log_shipping_secondary_database 'yourdb'

    -----------------------------------------------------------------------------------------------------------

    "Ya can't make an omelette without breaking just a few eggs" 😉

  • Perry Whittle (9/4/2012)


    Usually its set to the secondary destination directory which you can get from the following

    exec sp_help_log_shipping_secondary_database 'yourdb'

    Thanks, I tried that but did not see the information displayed in any of the columns returned;

    there is no column named "secondary destination directory" or close to it.

    I ran the above command on the standby server.

    __________________________________________________________________________________
    SQL Server 2016 Columnstore Index Enhancements - System Views for Disk-Based Tables[/url]
    Persisting SQL Server Index-Usage Statistics with MERGE[/url]
    Turbocharge Your Database Maintenance With Service Broker: Part 2[/url]

  • the column is called 'backup_destination_directory'

    -----------------------------------------------------------------------------------------------------------

    "Ya can't make an omelette without breaking just a few eggs" 😉

  • Perry Whittle (9/4/2012)


    the column is called 'backup_destination_directory'

    That location contains the log backups copied to the standby from the principal. There is no standby file there.

    __________________________________________________________________________________
    SQL Server 2016 Columnstore Index Enhancements - System Views for Disk-Based Tables[/url]
    Persisting SQL Server Index-Usage Statistics with MERGE[/url]
    Turbocharge Your Database Maintenance With Service Broker: Part 2[/url]

  • Marios Philippopoulos (9/4/2012)


    Perry Whittle (9/4/2012)


    the column is called 'backup_destination_directory'

    That location contains the log backups copied to the standby from the principal. There is no standby file there.

    yes it does and by default will have the TUF file too unless someone has deleted it 😉

    When the log shipping plan was created did the wizard backup and restore the database for you or was the database already initialised?

    -----------------------------------------------------------------------------------------------------------

    "Ya can't make an omelette without breaking just a few eggs" 😉

  • Perry Whittle (9/4/2012)


    Marios Philippopoulos (9/4/2012)


    Perry Whittle (9/4/2012)


    the column is called 'backup_destination_directory'

    That location contains the log backups copied to the standby from the principal. There is no standby file there.

    yes it does and by default will have the TUF file too unless someone has deleted it 😉

    When the log shipping plan was created did the wizard backup and restore the database for you or was the database already initialised?

    I had initialized it previously using a manual "RESTORE DATABASE ... WITH STANDBY ..." command.

    Is that why it is not showing up?

    __________________________________________________________________________________
    SQL Server 2016 Columnstore Index Enhancements - System Views for Disk-Based Tables[/url]
    Persisting SQL Server Index-Usage Statistics with MERGE[/url]
    Turbocharge Your Database Maintenance With Service Broker: Part 2[/url]

  • Marios Philippopoulos (9/5/2012)


    I had initialized it previously using a manual "RESTORE DATABASE ... WITH STANDBY ..." command.

    Is that why it is not showing up?

    So what path\filename did you specify for

    WITH STANDBY = 'path\filename'

    -----------------------------------------------------------------------------------------------------------

    "Ya can't make an omelette without breaking just a few eggs" 😉

  • Perry Whittle (9/5/2012)


    Marios Philippopoulos (9/5/2012)


    I had initialized it previously using a manual "RESTORE DATABASE ... WITH STANDBY ..." command.

    Is that why it is not showing up?

    So what path\filename did you specify for

    WITH STANDBY = 'path\filename'

    It was definitely different (even different LUN) than what is recorded in that column.

    __________________________________________________________________________________
    SQL Server 2016 Columnstore Index Enhancements - System Views for Disk-Based Tables[/url]
    Persisting SQL Server Index-Usage Statistics with MERGE[/url]
    Turbocharge Your Database Maintenance With Service Broker: Part 2[/url]

  • I realise that this question was raised a long time ago, but I thought I'd address it.

    In my experience the .TUF file is put into the same directory as the database data files. Not the the directory where the transaction log backups are copied to.

    Tom

    In SQL there are no absolutes, it always depends...

  • It's that way starting from SQL 2008 onwards. But SQL 2005 it's copied to the TLog Backup location ..

    --

    SQLBuddy

Viewing 11 posts - 1 through 10 (of 10 total)

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