LearnItFirst User Forum

New SQL Server 2008 DBA Course
Welcome Guest Search | New Posts | Members | Log In | Register

Is there anyway to keep these users permissions when the server is rebooted? Options
hpradhan
Posted: Wednesday, January 07, 2009 8:47:44 PM

Rank: Fledgling

Joined: 10/24/2008
Posts: 17
Points: 51
Where do you live?: Denver
Hi Scott,
I have given the users db_owner rights to tempdb. The rights are removed when the server is rebooted. I have checked the SQL logs and Event logs and there is nothing there to suggest why this is happening. I am supporting the systems that need to allow users to have access to TempDB. Every time, when server is rebooted, I need to go manually and grant to permission to all users who needs the temp db access. It's very daunting task... Is there anyway to keep these users permissions when the server is rebooted? As always, I appreciate your response.

HPradhan
Scott Whigham
Posted: Friday, January 09, 2009 4:49:28 PM


Rank: Super Mod

Joined: 3/20/2006
Posts: 460
Points: 1,002
Where do you live?: Dallas, TX
Whoa - really? I won't even ask why you need to do that. I'll just assume you have a good reason. I will say that I've not heard of that anywhere, ever. It's unusual let's just say. If you care to elaborate the "why" in a separate post, feel free Smile

It theoretically would be easy to have it do this. The easiest thing to do would be to create a job to run the TSQL you need and then have it "Start Automatically When SQL Server starts". The other option would be to create a stored proc to run the TSQL script to give them access and then to mark that as a startup proc using sp_procoption
hpradhan
Posted: Monday, January 26, 2009 7:48:41 PM

Rank: Fledgling

Joined: 10/24/2008
Posts: 17
Points: 51
Where do you live?: Denver
Scott,
Yes, I understand that everytime the server reboots it drops and recreates the temp db. That's why it loses it's permissions. To keep it, I'm going to have to do as you said in your post.

By the way, do you have video on this? if you don't, can I request one? That would greatly help. Thank you very much.

Hpradhan
Scott Whigham
Posted: Tuesday, January 27, 2009 5:01:35 AM


Rank: Super Mod

Joined: 3/20/2006
Posts: 460
Points: 1,002
Where do you live?: Dallas, TX
I don't have a video on that exact thing, per se, but one of the videos on how to create a job is all you need. I don't think I want to make a video on this topic because it would imply that I recommend doing things this way (which I don't!).

Step 1: Create a job
Step 2: Add a job step to execute your SQL
Step 3: Schedule the job to start automatically when SQL Server starts

That's really all there is to it!
hpradhan
Posted: Friday, February 13, 2009 4:24:21 PM

Rank: Fledgling

Joined: 10/24/2008
Posts: 17
Points: 51
Where do you live?: Denver
Scott,
That sounds easy. Thanks.

PS: By the way, How I earn the star? I saw one on mineSmile
Users browsing this topic
Guest


Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.