Solved

The service did not start due to a logon failure.

Posted on 2011-03-06
16
3,692 Views
Last Modified: 2012-06-27
I created a domain user as the logon user in SQL server configuration manager. The user works when I type the password in the Windows MSQL service, but not in the SQL configuration manager services. Evertime the computer rebbts I have to reenter the password in the Windows MSQL services and start the service.

Here is the error when I reboot

EVENT ID: 7001
The SQL Server Agent (MSSQLSERVER) service depends on the SQL Server (MSSQLSERVER) service which failed to start because of the following error:
The service did not start due to a logon failure.

Like I said if I reenter the password in services it works and then I just start the service

Can anyone help please?
0
Comment
Question by:rjackmanwyn
  • 8
  • 5
  • 3
16 Comments
 
LVL 18

Expert Comment

by:Matthew Kelly
ID: 35047924
You may have already done this, but does the domain account have the "Log On As Service" permission?

See the "Windows Domain Account Permissions" section for permissions required for SQL to run under a domain account: http://msdn.microsoft.com/en-us/library/ms191543.aspx

Step to add the Log on as service permission: http://technet.microsoft.com/en-us/library/cc739424(WS.10).aspx


0
 
LVL 18

Expert Comment

by:Matthew Kelly
ID: 35047933
Also see this: http://technet.microsoft.com/en-us/library/ms143504.aspx

"Always use SQL Server tools such as SQL Server Configuration Manager to change the account used by the SQL Server or SQL Server Agent services, or to change the password for the account. In addition to changing the account name, SQL Server Configuration Manager performs additional configuration such as setting permissions in the Windows Registry so that the new account can read the SQL Server settings. Other tools such as the Windows Services Control Manager can change the account name but do not change associated settings. If the service cannot access the SQL Server portion of the registry, the service may not start properly."
0
 

Author Comment

by:rjackmanwyn
ID: 35048116
If I change the login password for the user in SQL configuation is does not let me. I can only change it in Windows services then go back and change it in SQL config. But when I restart it doesn't hold it. I have read that this is a Microsoft bug, but haven't read a real good work around.
0
PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

 
LVL 18

Expert Comment

by:Matthew Kelly
ID: 35048158
Does it give you an error when you try to change the login password for the user in SQL configuration?

That may be your problem, perhaps the account doesn't have all of the required permissions to be able to run the service. Without setting it through the configuration, it won't get set in other required places.
0
 

Author Comment

by:rjackmanwyn
ID: 35048190
But once I set it through Windows it I can go back in SQL config and set it. What permissions does it need?
0
 
LVL 18

Expert Comment

by:Matthew Kelly
ID: 35048245
It needs at least the five permissions listed here: http://msdn.microsoft.com/en-us/library/ms191543.aspx

If this isn't a production machine, or you are OK just testing this, you could add the domain account to the local administrators group. That isn't a secure way of running the service, as if the sql server was hacked the hacker would have local admin rights, but just to eliminate permissions as the reason.

After setting the account as local admin, reboot and try setting password through sql config.

0
 

Author Comment

by:rjackmanwyn
ID: 35048305
OK I gave it domain admin in and it worked. I will look at the permissions in your link and try it with them. Thank You
0
 

Author Comment

by:rjackmanwyn
ID: 35048360
I take it back. When I restarted the second time it lost the credentials in SQL again. If I try to set the password through sql config it doesn't error, but when I try to start the service sql config I get a "the request failed or the service did not respond in a timely fashion" error
0
 
LVL 18

Accepted Solution

by:
Matthew Kelly earned 500 total points
ID: 35048436
The Application event log will usually have more information as to why the service failed to respond.
0
 

Author Comment

by:rjackmanwyn
ID: 35048514
I changed the username and password back to administrator in the Windows services and then changed it to what I wanted in the sql config and it took it. I will see if I have any problems again. Here is the error I have always gotten in the applications event log. Thanks

EVENT ID: 7001
The SQL Server Agent (MSSQLSERVER) service depends on the SQL Server (MSSQLSERVER) service which failed to start because of the following error:
The service did not start due to a logon failure.
0
 

Author Closing Comment

by:rjackmanwyn
ID: 35073762
Thanks Matthew

It worked for about 4 reboots, but began having the problem again. Your info was very helpfull, but I think I have other problems. I will close this so thank you
0
 

Expert Comment

by:Jayhawk05
ID: 35437736
I have been running into the same issue.  Open the server manager window (right click on computer --> Manage).  On the left navigation panel, go to Local Users and Groups and open Groups (see screenshot).  There you'll see several groups for SQL server accounts.  Try adding your respective sql accounts to each of these groups.  I did that and everything came back up on reboot (only tried once though). Server Manager Window
0
 

Author Comment

by:rjackmanwyn
ID: 35439938
Thanks Jayhawk

I have a 2003 server and I don't see server manager. I did add that account in administrator Tools/services, but that didn't work.
0
 

Expert Comment

by:Jayhawk05
ID: 35442134
Go to START --> Right click on MY COMPUTER --> MANAGE.  It's called "Computer Management" in Server 2003.  In the left pane you'll see System Tools --> Local Users and Groups --> Groups.  You'll see the group accounts there. (I verified on our Server 2003 machine.)  
0
 

Author Comment

by:rjackmanwyn
ID: 35442784
Thanks jayhawk

I will restart it tonght and see what happens. Is there a way to give you points for this if it is closed?
0
 

Expert Comment

by:Jayhawk05
ID: 35443004
I'm not worried about the points.  Mostly, I'm just hoping it fixes both of our problems!
0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

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

Everyone has problem when going to load data into Data warehouse (EDW). They all need to confirm that data quality is good but they don't no how to proceed. Microsoft has provided new task within SSIS 2008 called "Data Profiler Task". It solve th…
Ever wondered why sometimes your SQL Server is slow or unresponsive with connections spiking up but by the time you go in, all is well? The following article will show you how to install and configure a SQL job that will send you email alerts includ…
Familiarize people with the process of utilizing SQL Server functions from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Ac…
Viewers will learn how to use the SELECT statement in SQL to return specific rows and columns, with various degrees of sorting and limits in place.

815 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

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now