I'm trying to backup to a network drive, but I keep getting the message below:
Cannot open backup device '\\Server\Projects\Exodus\Backup_Banco'. Operating system error 5(Access is denied.).
The weird thing is that if I use xp_cmdshell on the same folder, I can dir, copy files, etc... Why is that?
Below is by backup command code that I get the Access Denied:
BACKUP DATABASE Exodus
TO DISK = '\\Server\Projects\Exodus\Backup_Banco'
And both xp_cmdshell commands below works without a glitch:
exec xp_cmdshell 'dir \\Server\Projects\Exodus\Backup_Banco'
exec xp_cmdshell 'copy \\Server\Projects\Exodus\Backup_Banco\text.txt \\Server\Projects\Exodus\Backup_Banco\text4.txt'
Both SQL Server and SQL Agent are running on domain accounts, and I gave Modify rights on the \\Server\Projects\Exodus\Backup_Banco folder to the Domain Local Group that holds both accounts, as the copy commands shows.
Both commands use SQL Server's service account rights, so I should get the same treatment for both commands. But that's not what is happening.
Any ideas why?