Alexandre Takacs
asked on
SQL server backup to CIFS share - syntax issue ?
I am trying to perform an SQL server "built-in" backup (part of a maintenance plan that was working so far) to a file share.
I understand that I have to use UNC in my file path and that the user running the SQL service should have access to the share - as such I have changed the DSQL service user to a domain user.
Checking my logs I see
Seems that it is actually an issue in finding the network share. This is how I have defined my destination :
Isn't that the correct way of doing it ?
I understand that I have to use UNC in my file path and that the user running the SQL service should have access to the share - as such I have changed the DSQL service user to a domain user.
Checking my logs I see
Failed:(-1073548784) Executing the query "BACKUP DATABASE [model] TO DISK = N'\\\\172.16.200...." failed with the following error: "Cannot open backup device '\\\\172.16.200.253\\Backup\\SQLDB\\model\\model_backup_2019_11_25_220003_1049249.bak'. Operating system error 67(The network name cannot be found.).
BACKUP DATABASE is terminating abnormally.". Possible failure reasons: Problems with the query, "ResultSet" property not set correctly, parameters not set correctly, or connection not established correctly.
Seems that it is actually an issue in finding the network share. This is how I have defined my destination :
Isn't that the correct way of doing it ?
ASKER
hmm problem is that the mapped path will not be available to the user running the backup (unless I do a scripted map before I run it). Is that the best practice ?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
>> problem is that the mapped path will not be available to the user running the backup
As mentioned by lcohan, just ensure that the startup account of SQL Server Agent service is having access to the share folder.
And use net use option if SSMS can't see the shared folder while configuring backups
As mentioned by lcohan, just ensure that the startup account of SQL Server Agent service is having access to the share folder.
And use net use option if SSMS can't see the shared folder while configuring backups
ASKER
Thanks - mapped the drive within the SQL service account and all works fine now
https://www.mssqltips.com/sqlservertip/3499/make-network-path-visible-for-sql-server-backup-and-restore-in-ssms/