Ransomware attackers specifically target and attempt to destroy backup systems to increase the probability of payment. Hardening your system is critical. Please ensure you have reviewed your platform security using the Security Hardening Checklist
Cohesity

COHESITY Documentation

Explore our documentation to get started, discover products & new features, access troubleshooting guides, register sources, platforms support.

Products
Data Security Alliance
Visit Cohesity.com
Demos
Support
Blogs
Developers
Partner Portals
Cohesity Community
© 2026 Cohesity, Inc. All Rights Reserved.
Terms of Use|
Privacy Policy|
Legal|
  1. Home
  2. Veritas NetBackup™ for Microsoft SQL Server Administrator's Guide
  3. Performance and troubleshooting
  4. A restore of a SQL Server database fails with Status Code 5, or Error (-1), when the host name of the SQL Server or the SQL Server database name has trailing spaces
Veritas NetBackup™ for Microsoft SQL Server Administrator's Guide

A restore of a SQL Server database fails with Status Code 5, or Error (-1), when the host name of the SQL Server or the SQL Server database name has trailing spaces

When the host name of a SQL Server or a SQL Server database name has one or more trailing spaces, NetBackup does not generate the restore script correctly. The trailing spaces in the SQL Server host name or the database name are truncated in the script. To successfully perform a restore, you must create and edit a restore script in the NetBackup MS SQL Client.

In the script, edit the DATABASE and the NBIMAGE lines to include the correct SQL Server host name or SQL Server database name. For example, assume that the server host name is "ACCT ", you use the default instance, and that the database name is "DatabaseA ". Notice the trailing spaces after the server host name and the database name.

Change the following lines:

DATABASE "DatabaseA"
NBIMAGE "ACCT.MSSQL7.ACCT.db.DatabaseA.~.7.001of001.20151118121736..C"

To:

DATABASE "DatabaseA   "
NBIMAGE "ACCT.MSSQL7.ACCT   .db.DatabaseA   .~.7.001of001.20151118121736..C"

Feedback

Was this page helpful?
Previous

Incorrect backup images are displayed for availability group clusters

Next

A move operation fails with Status Code 5, or Error (-1), when the SQL Server host name, the database name, or the database logical name has trailing spaces

Feedback

Was this page helpful?