solving sql server problems for millions of dbas and developers since 2006



SQL Server DBA Tips SQL Server Developer Tips SQL Server Business Intelligence Tips SQL Server Career Tips SQL Server Tip Categories SQL Server Tutorials SQL Server Webcasts SQL Server Whitepapers SQL Server Tools SQL Server Questions and Answers MSSQLTips Authors About MSSQLTips SQL Server User Groups MSSLQTips Giveaways MSSQLTips Advertising Options

MSSQLTips Facebook Page MSSQLTips LinkedIn Page MSSQLTips RSS Feed MSSQLTips Twitter Page MSSQLTips Google+ Page





SQL Server Agent Fixed Database Roles

By: | Read Comments | Print

Jeremy is the CTO @ Edgewood Solutions, co-founder of MSSQLTips.com and SQL Server MVP since 2009.



Related Tips: More

Problem
One mantra across the industry is the need to fine tune security for all infrastructure components.  In SQL Server 2005, Microsoft responded with an almost overwhelming number of granular security rights which in some respects requires DBAs and Developers to think about SQL Server security in a brand new way.  One key area that we are going to look at today is a few of the new security options for SQL Server Agent.  SQL Server 2000 had some semi granular fixed server roles for the database engine but no roles specifically for SQL Server Agent.  With SQL Server 2005 some of those same server role principals have been applied to the SQL Server Agent giving this portion of the architecture a big step forward.

Solution
SQL Server Agent now has 3 roles which reside in MSDB database offering a new set of opportunities to fine tune access to working with Jobs.  Job management is certainly one area where security improvements are a much welcomed addition.

What are the differences in the SQL Server Agent roles?

ID Role Description
1 SQLAgentUserRole
  • Ability to manage Jobs that they own
2 SQLAgentReaderRole
  • All of the SQLAgentUserRole rights
  • The ability to review multiserver jobs, their configurations and history
3 SQLAgentOperatorRole
  • All of the SQLAgentReaderRole rights
  • The ability to review operators, proxies and alerts
  • Execute, stop or start all local jobs
  • Delete the job history for any local job
  • Enable or disable all local jobs and schedules

Source - SQL Server Agent Fixed Database Roles

What types of users should be granted these rights?

Although production DBAs will have System Administrator rights, the new SQL Server Agent Fixed Database Roles would be considerations for:

  • Junior DBAs
  • Developers
  • Data Warehouse Developers
  • IT Operations
  • Management

How do I grant these rights?

The rights are granted at the MSDB database level.  To grant rights the follow these steps:

  1. Open SQL Server 2005 Management Studio
  2. Navigate to Databases | System Databases | msdb | Security | Roles | Database Roles
  3. Double click on 1 of the roles to add members to the role
  4. Use the Database Role Properties window to manage the users

Are any additional resources available?

Check out these SQL Server 2005 Books Online articles:

Next Steps

  • Take advantage of these new granular security privileges to best secure your Jobs.  There will no longer be an excuse for having to grant a great deal of privileges, these roles have filled that void.
  • The SQL Server Agent roles are just the tip of the iceberg when it comes to SQL Server 2005's granular security model.  With SQL Server 2000, granting security left a bad feeling pit in your stomach, but SQL Server 2005 has squashed those security concerns.
  • As you begin to deploy the SQL Server 2005 platform, question the privileges asked for by users and IT personnel.  Once you have a clear understanding of their needs, not wants, dig into the new security features with SQL Server 2005 to grant the appropriate privileges.


Related Tips: More | Become a paid author


Last Update: 8/16/2006

Share: Share 






Comments and Feedback:


Post a Comment or Question

Keep it clean and stay on the subject or we may delete your comment.
Your email address is not published. Required fields are marked with an asterisk (*)

*Name   *Email   Notify for updates
Comments
*Enter Code refresh code


 

Sponsor Information
"SQL doctor is the best SQL product on the market, by far. All of Idera's tools are great, but this is the icing on the cake!"

The 10 tools in the SQL Developer Bundle cut the time spent in dull and tedious tasks. Learn more.

Need SQL Server help and not sure where to turn? Reach out to the Edgewood experts for a Health Check starting at $995.

Get SQL Server Tips Straight from Kevin Kline.

Join the over million SQL Server Professionals who get their issues resolved daily.

The SQL Server Security THREAT - It’s Closer Than You Think


Copyright (c) 2006-2012 Edgewood Solutions, LLC All rights reserved
privacy | disclaimer | copyright | advertise | about
authors | contribute | feedback | giveaways | user groups
Some names and products listed are the registered trademarks of their respective owners.


Edgewood Solutions LLC | MSSharePointTips.com | MSSQLTips.com