cancel
Showing results for 
Search instead for 
Did you mean: 

SQL Backup fails on SQL 2012

Grant_Brunton
Level 3

We have a SQL 2012 environment set up with AlwaysON HA Availability Groups and are currently transferring the backups over to NetBackup. Our SQL 2008 environment has already been configured and is working.

The difference with the SQL 2012 servers is that the backup client does not connect to the SQL instance locally unless you run the client "As Administrator". I have configured the backup policy and scripts but the backup job when launched from the NetBackup policy fails with the error "Error: Failed to query database metadata for <xxxxx>".

If I launch the backup client (which must be run "as administrator") and kick off the backup script from there the backup job completes successfully.

So I'm pretty sure the problem is because the job needs to run as administrator which it doesn't do when launched from NetBackup.

The Netbackup services have been configured to use the backup service account which has full access to SQL and is a domain admin, and UAC is also disabled.

Is there a way to make NetBackup execute the job "as administrator" or do I need to set things up differently?

8 REPLIES 8

NBU35
Level 6

Hi 

Account which you are using for backups, get it following permissions:

1) add it to bulit in administrator group of windows 2012.

2) Provide it SYSADMIN privilages in MSSQL.

Run Netbackup CLient & netbackup legacy network service with this user.

Restart your netbackup services and then test your backup.

It should work. :)

Grant_Brunton
Level 3

The account already has sysadmin role and is a member of domain admins which is in the local administrator group by default.

I have just tried adding it directly to make sure but it did not make any difference. The same issue still exists.

D_Flood
Level 6

I second this part:

*****************************************

Run Netbackup CLient & netbackup legacy network service with this user.

******************************************

I've actually had to change all the NetBackup services on a client to use a specific account to get it to work...

Hopefully NetBackup 8.whatever will force this change since generic System Accounts have been defined as "evil"...

Marianne
Moderator
Moderator
Partner    VIP    Accredited Certified
Please enable logging to see what the problem is with server-initiated backups. Create dbclient folder under netbackup\logs. Use Host Properties to increase logging level to 3. Run the backup from the client. When completed, rename the log file in dbclient folder. Call it something like good.txt. Run the backup from the server. After the failure, rename the log to fail.txt. Compare the 2 logs. You may also upload the logs here for fellow users to try and assist.

Grant_Brunton
Level 3

Thanks Marianne, I have enabled the logging and completed a successful and failed job but the logs don't really tell me much more than what I was already seeing in the activity log in netbackup.

Ultimately, all it tells me is that it is unable to connect to the database.

The logs are attached. Maybe you can find something useful.

Marianne
Moderator
Moderator
Partner    VIP    Accredited Certified
Seems NBU services are still running as LocalSystem. Failed backup: NT user is System Successful backup: NT user is s-backup Change logon account on SQL server for NBU Client service and Legacy client service to s-backup and restart the services.

Grant_Brunton
Level 3

They already are...

services.JPG

And they've definitely been restarted since they were changed too.

Will_Restore
Level 6

other nodes?