I recently moved a set of Windows Sharepoint Services 3.0 site collections from SQL Server 2005 to SQL Server 2008. Everything seemed to work just fine, except my old script for full backups didn't go through as expected. I was using the command:
STSADM.EXE -o backup -directory c:\backup\wss_full -backupmethod full
It would give me the following error on one of the databases:
Verbose: [wssserver1_AdminContent] SQL Server Command: BACKUP DATABASE [wssserver1_AdminContent] TO DISK=@db_loc WITH NAME=@db_name, STATS=5, NOINIT, NOSKIP, NOFORMAT, NOREWIND @db_name=wssserver1_AdminContent, @db_loc=c:\backup\wss_full\spbr0005\0000000F.bakError: Object wssserver1_AdminContent failed in event OnBackup. For more information, see the error log located in the backup directory.SqlException: BACKUP DATABASE permission denied in database 'wssserver1_AdminContent'.BACKUP DATABASE is terminating abnormally.
For once the error message really says it all - it is a permission issue. Even tough I was running the job as a domain admin this account was not member of the sysadmin server role on the SQL 2008 server (necessary for SQL2k8 as domain admins do not have sa-privileges like they did in earlier versions of SQL Server), nor did it have the appropriate permissions on the w2k3admin-kp_AdminContent database. I added the domain user to the db_owner database role and the backup went through.
Ahh. So obvious. Thanks!
ReplyDelete