Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
264 views
in Technique[技术] by (71.8m points)

sql server - Backup Permissions

I created a new user on the server that will access certain databases.

But when I go to backup or restore the database I get the error:

C:Program FilesMicrosoft SQL ServerMSSQL10.MSSQLSERVERMSSQLBackup
Cannot access the specified path or file on the server. Verify that you have the necessary security privileges and that the path or file exists.....................

The error shows for any other path in my system. Even those where the user and the Service Account has full control permissions.

BUT, if I type the full path and click ok, it complains that it can't show, BUT it does backup or restore the database. Just doesn't show the tree view for the path.

If I do the operation using the sa account, the dialog shows all paths without complaint.

PS: Already added user to the db_backoperator role.

What permissions are required?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

db_backupoperator is a Database Role, not a Server Role or a Windows permission. It only grants the user necessary access to the database to make a backup. It does not grant any rights to the server's file structure, which are needed to actually make the backup file.

IIRC, to access the file structure to make a backup, the user must either already have windows/domain rights to access it, or have the Server Role sysadmin to pick-up the SQL Server's own Windows access rights.

Also, to actually Restore a database the user will need the Server Role dbcreator.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...