Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 SQL Server Administration (2005)
 what permissions required to run DBCC

Author  Topic 

newsqlbee
Starting Member

3 Posts

Posted - 2009-07-01 : 09:13:52
Hi Guru !!

When i run a DBCC shrinkfile command i got an error that
"User 'public' does not have permission to run DBCC shrinkfile for database"
can someone please tell me what all the permission one should required to run the dbcc command? and why i am getting this msg?

thanks in advance

Regards
Chander

rajdaksha
Aged Yak Warrior

595 Posts

Posted - 2009-07-01 : 09:32:51
Because you are not connected as a sysadmin role member
Go to Top of Page

newsqlbee
Starting Member

3 Posts

Posted - 2009-07-06 : 03:11:07
quote:
Originally posted by rajdaksha

Because you are not connected as a sysadmin role member



I cant add the user into system admin role, can u please advice which else role can be appropriate for this specific task ?

regards
shekhar
Go to Top of Page

GilaMonster
Master Smack Fu Yak Hacker

4507 Posts

Posted - 2009-07-06 : 03:35:09
According to Books Online, DBCC Shrinkfile requires membership in the sysadmin fixed server role or the db_owner fixed database role. So, either connect as a member of sysadmin or as a member of db_owner for that database.


--
Gail Shaw
SQL Server MVP
Go to Top of Page
   

- Advertisement -