Solved

give sysadmin previledge back to BUILTIN\Administrators

Posted on 2010-09-17
4
465 Views
Last Modified: 2012-05-10
If sysadmin role was removed from BUILTIN\Administrators a while back,and needed to give it back, how can it be done?

0
Comment
Question by:anushahanna
  • 2
  • 2
4 Comments
 
LVL 7

Expert Comment

by:Cboudroz
ID: 33704016
You need to be sysadmin and run:

-- Run this if User has been drop from Server Login
CREATE LOGIN [BUILTIN\Administrators] FROM WINDOWS WITH DEFAULT_DATABASE=[master]

-- Run this to add it back to sysadmin roles
EXEC master..sp_addsrvrolemember @loginame = N'BUILTIN\Administrators', @rolename = N'sysadmin'
0
 
LVL 6

Author Comment

by:anushahanna
ID: 33704062
can this done through the OS?
0
 
LVL 7

Accepted Solution

by:
Cboudroz earned 500 total points
ID: 33704315
it's a SQL security so you need to connect to SQL server and run these command.  

You can used sqlcmd Utility to run the command if you don't want to use  management studio.

http://msdn.microsoft.com/en-us/library/ms162773.aspx


but make sure you connect as sysadmin.



 
0
 
LVL 6

Author Comment

by:anushahanna
ID: 33704328
thanks.
0

Featured Post

Use Case: Protecting a Hybrid Cloud Infrastructure

Microsoft Azure is rapidly becoming the norm in dynamic IT environments. This document describes the challenges that organizations face when protecting data in a hybrid cloud IT environment and presents a use case to demonstrate how Acronis Backup protects all data.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Load balancing is the method of dividing the total amount of work performed by one computer between two or more computers. Its aim is to get more work done in the same amount of time, ensuring that all the users get served faster.
Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.
Using examples as well as descriptions, and references to Books Online, show the documentation available for datatypes, explain the available data types and show how data can be passed into and out of variables.

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question