C# script to check SQL server Service Status
Dear,
i want any console application or asp.net web site project which give me sql server services status of my and other local machine which is using same network connect with other machine name.
in other word, i want such asp.net website project or console application when i run it give me status of all sql server service status of other specific machine
plz help me
Asif Mehmood
Just connect to the machines
SCM and query it.
Use the
ServiceController class and especially this
ServiceController constructor (String, String) to connect to remote machines.
You may use the static
ServiceController.GetServices(String) method instead of manually connecting to the remote SCM.
E.g.
namespace Samples
using System;
using System.ServiceProcess;
class Program
static void Main(string[] args)
ServiceController[] serviceControllers;
serviceControllers = ServiceController.GetServices("hoffmann-04");
foreach (ServiceController serviceController in serviceControllers)
Console.WriteLine("{0}", serviceController.ServiceName);
Console.WriteLine("\t{0}\n", serviceController.DisplayName);
Console.WriteLine("Done.");
Console.ReadLine();
When running this code within a ASP.NET application, this means that it will run in the ASP.NET application pool. This pool uses normally a local, restricted account, which does not possess the necessary priveleges to query a remote SCM.
E.g. for SQL Server services:
namespace Samples
using System;
using System.Collections.Generic;
using System.Linq;
using System.ServiceProcess;
class Program
static void Main(string[] args)
List<ServiceController> serviceControllers;
serviceControllers = ServiceController.GetServices(".")
.Where(sc => sc.ServiceName.Contains("SQL")).ToList();
foreach (ServiceController serviceController in serviceControllers)
Console.WriteLine("{0}: {1}", serviceController.ServiceName, serviceController.Status);
Console.WriteLine("\t{0}\n", serviceController.DisplayName);
Console.WriteLine("Done.");
Console.ReadLine();
Similar Messages
-
SQL server services status- powershell
Do anybody have powershell script to monitor listed sqlserver instances services and send an email alert when the services stoped stat? that results should store in database?
Hi RoyalM,
The script can get the sql services on local server, and will sends email when the sql service stops.
Get-Service | where-Object{$_.name -like '*sql*'} | foreach{
if ($_.status -eq "stopped"){
$message = "sql service "+$_.name+" is stopped"
send-mailmessage -to "User01 <[email protected]>" -from "User02 <[email protected]>" -subject $message}
I hope this helps. -
SQL Server services having stop
We're using SQL server 2008 r2 but having lot of issues. My application running on SQL server but it stop everyday. SQL services stop then my application automatic hang then i restart the server then after my application work.
Hi harigaurav,
If SQL Server Services stop regularly every day, then you can check the Start Mode for the services in SQL Server Configuration Manager, check the Windows Scheduler or use some monitor tools to monitor SQL Server services status.
If SQL Server Services always stop unexpectedly, we can configure SQL Server Agent to restart the SQL Server and SQL Server Agent services automatically. To configure automatic service restart:
Open the SQL Server Management Studio Management folder, right-click the SQL Server Agent entry, and select Properties.
On the General page, select the Auto Restart SQL Server If It Stops Unexpectedly check box.
Here, you should also select the Auto Restart SQL Server Agent If It Stops Unexpectedly check box.
Click OK.
Thanks,
Katherine Xiong
Katherine Xiong
TechNet Community Support -
Query to Find what SQL Server services running, what status and with what service account
I need to check what SQL Server services are running(engine,agent,IS,AS,RS,browser and Full text) and what is the present status and what service accounts are been used by them on several servers in a single shot.
Could any one help me in finding a good script for the same.I have been looking for the same thing, the issue I am running into is finding the Actual Service Name. I know this question is old, and I personally do not understand the reply.
so Far I have the following:
DECLARE @ServiceAcount NVARCHAR(128);
SET @Service = 'No Return Value'
--MsDtsServer100 (SSIS)
EXEC master.dbo.xp_regread
'HKEY_LOCAL_MACHINE',
'SYSTEM\CurrentControlSet\services\MsDtsServer100',
'ObjectName',
@ServiceAccount OUTPUT;
SELECT @ServiceAccount;
I am still looking for the correct service naming for Analysis Services, Distributed Replaay Client, Distributed Replay Controller -
Monitor SQL Server service Broker queue status
I need to monitor SQL Server service Broker queue status. If the queue is disabled, send me an email alert.
Can you let me know what's the best way to accomplish it using SCOM?1) create a queue for notification
2) create a service on notification queue
3)Create an event notification for broker queue disable. Associate this with the queue that you are monitoring.
4)Create a procedure that send you and email with this event happens
Example:
---- Notification
CREATE
QUEUENotify_queue
-- Service
CREATE
SERVICE[http://queue_Notify]
ONQUEUENotify_queue([http://schemas.microsoft.com/SQL/Notifications/PostEventNotification]);
--Event
CREATE
EVENTNOTIFICATION[http://queue_Notify_event]
ONQUEUETarget_queue
FORBROKER_QUEUE_DISABLED
TOSERVICE'http://queue_Notify','current
database';
GO
procedure will be something like...
WAITFOR
RECEIVETOP(1)
@RecvReqMsgName=message_type_name,
@RecvReplyMsg=message_body,
@RecvReplyDlgHandle=conversation_handle
FROMNotify_queue),TIMEOUT5000
IF(@RecvReqMsgName='http://schemas.microsoft.com/SQL/Notifications/EventNotification')
BEGIN
DECLARE@cmdNVARCHAR(MAX)
SET@cmd='dbo.sp_send_dbmail
@profile_name="Name XYZ",
@recipients="[email protected]",
@body="CAST(@RecvReplyMsg as NVARCHAR(MAX)",
@subject="Queue Disabled Detected";'
EXEC
(@cmd)
END -
SharePoint 2010 - SQL Server Service Application Server Appears on Server without SSRS Installed
I have SSRS instance installed on Server 2 in integrated mode and reports within SharePoint are working as expected. But, when you go to manage the SQL Server Service Application it throws an 503 error and I believe it is related to the fact that the
service also shows up on another Application Server, Server1, that does not have SSRS installed. The service is disabled and it shows up in the list of Services for the server but I believe SharePoint thinks its the primary service and cannot access
it. Is there any way to remove the Service from Server2? I attempted the below powershell commands to remove but it gives me an error. Any suggestions would be appreciated.
Get-SPRSServiceApplicationServers
Address
Server1
Server2
get-spserviceinstance -all |where {$_.TypeName -like "SQL Server Reporting*"}
TypeName Status Id
SQL Server Reporting Services... Disabled a5179dce-2d6c-476b-a74b-764375d70a94
SQL Server Reporting Services... Online 64a99ed8-d31c-4dd3-b9f7-b6d946e41e16
Remove-SPServiceApplication a5179dce-2d6c-476b-a74b64375d70a94 -RemoveData
Remove-SPServiceApplication : Object not found.
At line:1 char:28
+ Remove-SPServiceApplication <<<< a5179dce-2d6c-476b-a74b-764375d70a94 -Remo
eData
+ CategoryInfo : ObjectNotFound: (Microsoft.Share...viceApplicati
on:SPCmdletRemoveServiceApplication) [Remove-SPServiceApplication], Invali
dOperationException
+ FullyQualifiedErrorId : Microsoft.SharePoint.PowerShell.SPCmdletRemoveSe
rviceApplication
Remove-SPServiceApplication : Object reference not set to an instance of an ob
ect. At line:1 char:28
+ Remove-SPServiceApplication <<<< a5179dce-2d6c-476b-a74b-764375d70a94 -Remo
eData + CategoryInfo : InvalidData: (Microsoft.Share...viceApplication:
SPCmdletRemoveServiceApplication) [Remove-SPServiceApplication], NullRefer
enceException + FullyQualifiedErrorId : Microsoft.SharePoint.PowerShell.SPCmdletRemoveSe
rviceApplicationYou're getting a Service Instance object and trying to remove it with a Service Application cmdlet... This won't quite work :) Can you double check to validate that SSRS 2008 R2 or higher bits were not accidentally laid down on the problem host?
Trevor Seward, MCC
Follow or contact me at...
  
This post is my own opinion and does not necessarily reflect the opinion or view of Microsoft, its employees, or other MVPs. -
Hi
I get this warning running through powershell_ise but through sql agent it just errors out.
The code does everything it is supposed to and I tried everything to completely resolve the warning to no avail.
How do I supress it so sql agent wont error out running powershell code?
Thanks!
WARNING: Could not obtain SQL Server Service information. An attempt to connect to WMI on 'server_name' failed with the following error: Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED))
Warning only present when it connects to remote servers, it doesn't produce it for local server. And it does get all info from the remote servers.
PaulaHi paulata,
According to your description, when you run powershell scripts about the remote machine
in SQL Server Agent job, the warning error will occur. “The common error message is Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED)).” This suggests that your credentials aren't sufficient for accessing the
remote system. If you have an account that has sufficient permissions for the query, there's a simple workaround for this problem in the form of PowerShell's Get-Credential command and the script's Credential parameter. I recommend you check if your account
has permission on remote machine and it can execute the powershell scripts.
In addition, if you want to run query statement on the remote machine , I recommend you create Linked Server, then do some related operations. There is a similar issue about access denied, you can review the following article.
http://social.msdn.microsoft.com/Forums/sqlserver/en-US/157f536d-6716-4547-bdb4-9e3c8451cb95/sql-agent-service-account-permissions-sql-server-2008?forum=sqlgetstarted
Regards,
Sofiya Li
Sofiya Li
TechNet Community Support -
SQL Server Service Account - Domain Account - WMI Provider Error - 0x80092004
Hi,
if I try to use an domain account for SQL service start using SQL configuration Manager I receive the error
WMI Provider Error - 0x80092004
in Popup Window and in Eventlog 5 Error Events from Source MSSQLSERVER:
26014:
Unable to load user-specified certificate [Cert Hash(sha1) "BA78B5DBF93CCD7EFA1860C99B0D6141D480199A"]. The server will not accept a connection. You should verify that the certificate is correctly installed. See "Configuring Certificate for
Use by SSL" in Books Online.
17182:
TDSSNIClient initialization failed with error 0x80092004, status code 0x80. Reason: Unable to initialize SSL support. Cannot find object or property. "
17182:
TDSSNIClient initialization failed with error 0x80092004, status code 0x1. Reason: Initialization failed with an infrastructure error. Check for previous errors. Cannot find object or property.
17826:
Could not start the network library because of an internal error in the network library. To determine the cause, review the errors immediately preceding this one in the error log.
17120:
SQL Server could not spawn FRunCommunicationsManager thread. Check the SQL Server error log and the Windows event logs for information about possible related problems.
After I put the account in local administrator group the service starts up.
I want to use the lowest privileges. Do I really need the SQL server service account in local administrator group? How to fix the error?
thanksHi baschuel,
It is recommended to run SQL Server service by using the lowest possible user rights and it is supported to use a domain account instead of an account from local Administrators group to configure SQL Server service. According to your error messages, the
issue could be due to that the incorrect certificate is used, or the domain account has no access to the Crypto folder(C:\ProgramData\Microsoft\Crypto). To troubleshoot the issue, you could follow the two solutions below.
1.Import the correct certificate following the steps in the article:
http://windows.microsoft.com/en-hk/windows/import-export-certificates-private-keys#1TC=windows-7
2.Grant the domain account full access to the Crypto folder.
Regards,
Michelle Li
If you have any feedback on our support, please click
here. -
Email alert if SQL Server Services stop abruptly
Hi,
I am a SQL Server DBA and I am currently working on setting up email alerts in case if SQL Server services stop abruptly.I have currently written a VB script which runs every 1 hr and checks if a SQL Server Service is running or not. This VB Script runs
with the help of Windows Task Scheduler.In case if a SQL Server service has stopped, this VB script immediately sends an email via. SMTP Server.
Please let me know if this is a good solution or is there any other better solution or is there any feature available in SQL/windows using which the same can be achieved.
Environment:
SQL 2008 R2
OS: Windows Server 2008
Thanks a lot in advance :)
Regards,
Tauhid S ShaikhHi Tauhid,
I do have same requirement, please could you share the code.
Regards
Siraj Ahmed -
Install Fails With SQL Server Version - Status: Incorrect
Hi. I am working to install BPC 7 in a single server environment. During installation the setup diangostic detects a problem with [[Microsoft and 3rd Party Software]], below is what appears:
X - SQL Server Version
____ OK - Required: 10.0.1600.22 or higher
____ OK - Currently: Not Installed
____ X - Status: Incorrect
X - SQL Reporting Services Server Version
____ OK - Required: 10.0.1600.22 or higher
____ OK - Currently: Not Installed
____ X - Status: Incorrect
X - OLAP Server Version
____ OK - Required: 10.0.1600.22 or higher
____ OK - Currently: Not Installed
____ X - Status: Incorrect
Under [[Computer Services Status]] SQL Server is alright:
OK - MS SQL Server Service
____ OK - Required: Running
____ OK - Currently: Running
____ OK - Status: OK
OK - MS SQL Server Agent Service
____ OK - Required: Running
____ OK - Currently: Running
____ OK - Status: OK
OK - SQL Integrated Service
____ OK - Required: Running
____ OK - Currently: Running
____ OK - Status: OK
OK - SQL Report Service
____ OK - Required: Running
____ OK - Currently: Running
____ OK - Status: OK
OK - MS SQL Server OLAP Service
____ OK - Required: Running
____ OK - Currently: Running
____ OK - Status: OK
What I've Checked so far:
- Collation
- Account for installation is SQL SysAdmin and a Windows account
- Mixed mode authentication
I should mention, this is a single server install on a 64 bit version of Windows, with 64 bit version of SQL.
Any experience, ideas or suggestions are welcome.
Joe
Edited by: jwainz on Mar 29, 2010 5:55 PMI think the clearest statement about this is on page 11 of the Master Guide (SAP BPC 7.0 M Master Guide at [http://service.sap.com/instguidesEPM-BPC]).
Look at the rows for OLAP Server and Microsoft SQL Server. In each of those, you wil find this statement:
"Can be 64‒bit when separate from Application/web services"
On page 10 in the Installation Guide, for look at the rows for Application server Web Server. The prerequisites are as follow:
App Server:
Windows Server 2003 or Windows Server 2003 R2 Standard or Enterprise Edition SP2 (32-bit) configured with NTFS, set to English (United States)
Web Server:
Windows Server 2003 or Windows Server 2003 R2 Standard or Enterprise Edition SP2 (32-bit) configured with NTFS
Finally, the PAM is a bit confusing. For product SAP BPC 7.0 FOR MICROSOFT, click on the tab Operating Systems and then click on the tab BPC Server. That is the software that you install for the Application Server and the Web Server server types. The Operating System Version listed is WINDOWS SERVER 2003/IA32 32BIT -
I know this question has been asked before, but never for R2, that I can tell, and the posted fixes aren't working. I have just installed SCVMM 2008 R2 on a Windows Server 2008 R2 server, using a remote SQL 2008 SP1 database. When I attempt to connect to SCVMM, I get the following error:
"The SQL Server service account does not have permission to access Active Directory Domain Services (AD DS).
Ensure that the SQL Server service is running under a domain account or a computer account that has permission to access AD DS. For more information, see "Some applications and APIs require access to authorization information on account objects" in the Microsoft Knowledge Base at http://go.microsoft.com/fwlink/?LinkId=121054.
ID: 2607"
What I've seen online is that this is usually becuase the domain account SCVMM is running as does not have the proper permissions on the SQL database. Here's what I've confirmed:
1) My SCVMM service account is a local admin on the SCVMM server
2) My SCVMM service account is a dbowner on the SCVMM database in SQL
3) My SQL service account is a dbowner on the SCVMM database in SQL
4) My SQL service account is a domain user (even made it a domain admin, just in case, and it still "doesn't have access to AD DS," which is obviously untrue)
5) Neither service account is locked out
Has anyone run in to this? It says in Technet that remote SQL 2008 is supported, as long as the SQL management studio is installed to the SCVMM server, and I installed and patched before I began the SCVMM installation. I just don't know what else to try - I have no errors in event logs, no issues during the installation itself...
Andrew ToppThat answer was very unhelpful fr33m4n. The individual mentions that they've received the error that points to the KB article. I currently receive the same error -- there seems to be no resolution. I've run the Microsoft VBS script to add TAUG to the WAAG
as suggested by 331951, and that made absolutely no difference.
1) My SCVMM service account is a local admin on the SCVMM server
2) My SCVMM service account is a dbowner on the SCVMM database in SQL
3) My SQL service account is a dbowner on the SCVMM database in SQL
4) My SQL service account is a domain user (even made it a domain admin, just in case, and it still
"doesn't have access to AD DS," which is obviously untrue)
The user is also a member of WAAG, the machines have delegated authority to each other. Is there any other solution? -
SQL Server Service won't start on SQL Server 2008
Hi everyone,
I'm having trouble starting SQL Server service after stopping and starting the service. Before this happened, I created a Stored Procedure for marking all tables at once along with a maintenance plan for differential backup on all my databases based on the
recommendation from this link, http://msdn.microsoft.com/en-us/library/ms253070.aspx.
When I realized that the differential backup failed with some databases displaying (Restoring...) post-fix to the database name, I decided to stop SQL Server service and start it up. That is when I won't be able to start the service again.
Is there a fix for starting the SQL Server service? Any help is very much appreciated.
Additional information:
- With administrator permission granted.
- Service Pack 1 for SQL Server 2008 installed.
- Using default database instance.
- Tried C:\Program Files\Microsoft SQL Server\MSSQL.....\Binn>net start MSSQLSERVER /T3608 ( return msg: System error 5 has occurred. Access is denied.
- When I start SQL Server service, I keep getting this dialog msg:
"Windowns could not start the SQL Server (MSSQLSERVER) on Local Computer. For more information, review the System Event Log. If this is a non-Microsoft service, contact the service vendor, and refer to service-specific error code 1814."
The event log does not explain or provide any hint on how to fix the problem.
- Log msg:
2010-07-22 10:30:25.09 Server (c) 2005 Microsoft Corporation.
2010-07-22 10:30:25.09 Server All rights reserved.
2010-07-22 10:30:25.09 Server Server process ID is 6076.
2010-07-22 10:30:25.10 Server Authentication mode is MIXED.
2010-07-22 10:30:25.10 Server Logging SQL Server messages in file 'C:\Program Files\Microsoft SQL Server\MSSQL10.MSSQLSERVER\MSSQL\Log\ERRORLOG'.
2010-07-22 10:30:25.11 Server This instance of SQL Server last reported using a process ID of 5708 at 7/21/2010 3:27:01 PM (local) 7/21/2010 10:27:01 PM (UTC). This is an informational message only; no user action is required.
2010-07-22 10:30:25.11 Server Registry startup parameters:
-d C:\Program Files\Microsoft SQL Server\MSSQL10.MSSQLSERVER\MSSQL\DATA\master.mdf
-e C:\Program Files\Microsoft SQL Server\MSSQL10.MSSQLSERVER\MSSQL\Log\ERRORLOG
-l C:\Program Files\Microsoft SQL Server\MSSQL10.MSSQLSERVER\MSSQL\DATA\mastlog.ldf
2010-07-22 10:30:25.14 Server SQL Server is starting at normal priority base (=7). This is an informational message only. No user action is required.
2010-07-22 10:30:25.14 Server Detected 4 CPUs. This is an informational message; no user action is required.
2010-07-22 10:30:25.23 Server Using locked pages for buffer pool.
2010-07-22 10:30:25.43 Server Using dynamic lock allocation. Initial allocation of 2500 Lock blocks and 5000 Lock Owner blocks per node. This is an informational message only. No user action is required.
2010-07-22 10:30:25.73 Server Node configuration: node 0: CPU mask: 0x000000000000000f Active CPU mask: 0x000000000000000f. This message provides a description of the NUMA configuration for this computer. This is an informational
message only. No user action is required.
2010-07-22 10:30:25.81 spid7s Starting up database 'master'.
2010-07-22 10:30:26.14 spid7s CHECKDB for database 'master' finished without errors on 2010-07-19 21:15:02.823 (local time). This is an informational message only; no user action is required.
2010-07-22 10:30:26.18 spid7s Resource governor reconfiguration succeeded.
2010-07-22 10:30:26.18 spid7s SQL Server Audit is starting the audits. This is an informational message. No user action is required.
2010-07-22 10:30:26.18 spid7s SQL Server Audit has started the audits. This is an informational message. No user action is required.
2010-07-22 10:30:26.19 spid7s FILESTREAM: effective level = 0, configured level = 0, file system access share name = 'MSSQLSERVER'.
2010-07-22 10:30:26.28 spid7s SQL Trace ID 1 was started by login "sa".
2010-07-22 10:30:26.29 spid7s Starting up database 'mssqlsystemresource'.
2010-07-22 10:30:26.31 spid7s The resource database build version is 10.00.2531. This is an informational message only. No user action is required.
2010-07-22 10:30:26.43 spid10s Starting up database 'model'.
2010-07-22 10:30:26.43 spid7s Server name is 'XXXXXXXXXXXXXX'. This is an informational message only. No user action is required.
2010-07-22 10:30:26.47 spid10s The database 'model' is marked RESTORING and is in a state that does not allow recovery to be run.
2010-07-22 10:30:26.47 spid10s Error: 927, Severity: 14, State: 2.
2010-07-22 10:30:26.47 spid10s Database 'model' cannot be opened. It is in the middle of a restore.
2010-07-22 10:30:26.59 spid10s Could not create tempdb. You may not have enough disk space available. Free additional disk space by deleting other files on the tempdb drive and then restart SQL Server. Check for additional errors in
the event log that may indicate why the tempdb files could not be initialized.
2010-07-22 10:30:26.59 spid10s SQL Trace was stopped due to server shutdown. Trace ID = '1'. This is an informational message only; no user action is required.Hello,
Could you please copy the model.mdf and modellog.ldf from
C:\Program Files\Microsoft SQL Server\MSSQL10.MSSQLSERVER\MSSQL\Binn\Templates
To
C:\Program Files\Microsoft SQL Server\MSSQL10.MSSQLSERVER\MSSQL\DATA
Rebuilding the system databases you will lose lose logins, jobs, SSIS packages. You may have to restore or attach user databases.
Hope this helps.
Regards,
Alberto Morillo
SQLCoffee.com -
Hi
i have a sharepoint deployment with one SQL Server (running on VM) hosting the config DB and another SQL Server (Physical Host because VM was running out of space) to host the huge Content DBs. I need to schedule automatic backups of the Content DBs to a
network share. For that i need to run the SQL Server Service with an account having permissions to the share as suggested in https://support.microsoft.com/kb/207187?wa=wsignin1.0
I tried changing the logon as a service account to a domain
account which has permissions to the Network Share and is also in local Administrators group of SQL Server and has "public and sysadmin" roles in SQL Server but that caused an issue. the SharePoint Web Application started showing a White Screen so
I had to revert back to the default accounts i.e. NT Service\SQLSERVERAGENT and NT Service\MSSQLSERVER. I viewed the event logs . These are the types of error i got after changing the logon as a service account to a domain account
1) Information Rights Management (IRM): Retried too many times to initialize IRM client. Cannot retry more. Retried times is:0x5.
System
Provider
[ Name]
Microsoft-SharePoint Products-SharePoint Foundation
[ Guid]
{6FB7E0CD-52E7-47DD-997A-241563931FC2}
EventID
5148
Version
15
Level
2
Task
9
Opcode
0
Keywords
0x4000000000000000
TimeCreated
[ SystemTime]
2015-02-02T04:46:04.750899500Z
EventRecordID
176477
Correlation
[ ActivityID]
{8FACE59C-1E17-50D0-7135-25FDB824CDBE}
Execution
[ ProcessID]
6912
[ ThreadID]
8872
Channel
Application
Computer
Security
[ UserID]
S-1-5-21-876248814-3204482948-604612597-111753
EventData
hex0
0x5
2)
Unknown SQL Exception 0 occurred. Additional error information from SQL Server is included below.
The target principal name is incorrect. Cannot generate SSPI context.
System
Provider
[ Name]
Microsoft-SharePoint Products-SharePoint Foundation
[ Guid]
{6FB7E0CD-52E7-47DD-997A-241563931FC2}
EventID
5586
Version
15
Level
2
Task
3
Opcode
0
Keywords
0x4000000000000000
TimeCreated
[ SystemTime]
2015-02-02T07:01:35.843757700Z
EventRecordID
176490
Correlation
[ ActivityID]
{50B4E59C-5E3A-50D0-7135-22AD91909F02}
Execution
[ ProcessID]
6912
[ ThreadID]
5452
Channel
Application
Computer
Security
[ UserID]
S-1-5-17
EventData
int0
0
string1
The target principal name is incorrect. Cannot generate SSPI context.Hi Aparna,
According to your description, you get the above two errors when scheduling backups of Content DB. Right?
Based on those two error messages, they are related to the service principal name(SPN) for SQL Server service. Please verify the if the SPN is registered successfully. You can view it in ADSI Edit or use command line. Please see:
http://blogs.msdn.com/b/psssql/archive/2010/03/09/what-spn-do-i-use-and-how-does-it-get-there.aspx
When installing SQL Server, those two services below should be registered:
MSSQLSvc/servername:1433
MSSQLSvc/servername
Please check if those SPNs or duplicated SPNs exist. You can use command to reset SPN or remove duplicated SPN and add new one. See:
Setspn.
We have also met this issue when this SPN is registered under Administrator. Please try to register it under Computer. You can add it in ADSI Edit.
If you have any question, please feel free to ask.
Simon Hou
TechNet Community Support -
After changing 'MS SQL server' service's user name SDAC doesn't work properly
I've changed 'MS SQL Server' service user name
from .\admin (have had such already) to network_services
and now my oracle linked servers to Oracle instance stopped to work.
Namely, 'Cannot create an instance of OLE DB provider "OraOLEDB.Oracle" for linked server Ora_RO'.
In event log i see next:
The machine-default permission settings do not grant Local Activation permission for the COM Server application with CLSID
{2206CDB0-19C1-11D1-89E0-00C04FD7A829}
and APPID
{2206CDB0-19C1-11D1-89E0-00C04FD7A829}
to the user NT AUTHORITY\NETWORK SERVICE SID (S-1-5-20) from address LocalHost (Using LRPC). This security permission can be modified using the Component Services administrative tool.
So, MSDAINITIALIZE Class fails to start. I cannot locate this service under dcomcnfg. Could you help me?The error seems to be clear what is causing the issue, check this link to fix this issue
Here the scenario is with SharePoint instead oracle so you can make out:-
http://www.wictorwilen.se/Post/Fix-the-SharePoint-DCOM-10016-error-on-Windows-Server-2008-R2.aspx
http://social.technet.microsoft.com/Forums/en-US/696204d5-b07e-46db-a785-737ea57b8da2/distributed-com-error-message
Mark ANSWER if this reply resolves your query, If helpful then VOTE HELPFUL
INSQLSERVER.COM
Mohammad Nizamuddin -
SQL Server Service is stoping with an Error Code : 1814
Hi,
I have an SCCM Server in My organization. Where we have installed Microsoft SQL Server 2008 R2 for the database of SCCM Application.
Now I am not able to Start the SCCM console due to some dependent Services are not starting. 3 services has to be started for the perfect working of SCCM.
1)SQL Server
2) SQL Server Agent
3) SQL Server Reporting Services
Out of three the first two services are not starting at all. I am getting an error while trying to start SQL Server Services.
" Windows Could not start the SQL Server (MSSQLSERVER) on Local Computer. For more information, review the system event Log, If this is a non-Microsoft Service, contact the service vender , and refer to service-specific error code
1814."
Please help me to start the services and resolve the SCCM Server issue.
Thanks,
Henoy TM
+918888631370Hi Xing,
I have check the Error Log : Please find the logfile details:
2013-04-11 11:11:57.54 Server Microsoft SQL Server 2008 R2 (SP1) - 10.50.2811.0 (X64)
Apr 6 2012 01:59:29
Copyright (c) Microsoft Corporation
Enterprise Edition (64-bit) on Windows NT 6.1 <X64> (Build 7601: Service Pack 1)
2013-04-11 11:11:57.54 Server (c) Microsoft Corporation.
2013-04-11 11:11:57.54 Server All rights reserved.
2013-04-11 11:11:57.54 Server Server process ID is 10348.
2013-04-11 11:11:57.54 Server System Manufacturer: 'HP', System Model: 'ProLiant DL380 G6'.
2013-04-11 11:11:57.54 Server Authentication mode is WINDOWS-ONLY.
2013-04-11 11:11:57.54 Server Logging SQL Server messages in file 'H:\Program Files\Microsoft SQL Server\MSSQL10_50.MSSQLSERVER\MSSQL\Log\ERRORLOG'.
2013-04-11 11:11:57.54 Server This instance of SQL Server last reported using a process ID of 4428 at 4/11/2013 10:41:54 AM (local) 4/11/2013 5:11:54 AM (UTC). This is an informational message only; no user action is required.
2013-04-11 11:11:57.54 Server Registry startup parameters:
-d H:\Program Files\Microsoft SQL Server\MSSQL10_50.MSSQLSERVER\MSSQL\DATA\master.mdf
-e H:\Program Files\Microsoft SQL Server\MSSQL10_50.MSSQLSERVER\MSSQL\Log\ERRORLOG
-l H:\Program Files\Microsoft SQL Server\MSSQL10_50.MSSQLSERVER\MSSQL\DATA\mastlog.ldf
-T 8295
-T 4199
2013-04-11 11:11:57.56 Server SQL Server is starting at normal priority base (=7). This is an informational message only. No user action is required.
2013-04-11 11:11:57.56 Server Detected 8 CPUs. This is an informational message; no user action is required.
2013-04-11 11:11:57.59 Server Using dynamic lock allocation. Initial allocation of 2500 Lock blocks and 5000 Lock Owner blocks per node. This is an informational message only. No user action is required.
2013-04-11 11:11:57.61 Server Node configuration: node 0: CPU mask: 0x00000000000000f0:0 Active CPU mask: 0x00000000000000f0:0. This message provides a description of the NUMA configuration for this computer. This is an informational
message only. No user action is required.
2013-04-11 11:11:57.61 Server Node configuration: node 1: CPU mask: 0x000000000000000f:0 Active CPU mask: 0x000000000000000f:0. This message provides a description of the NUMA configuration for this computer. This is an informational
message only. No user action is required.
2013-04-11 11:11:57.66 spid9s Starting up database 'master'.
2013-04-11 11:11:58.24 spid9s Resource governor reconfiguration succeeded.
2013-04-11 11:11:58.24 spid9s SQL Server Audit is starting the audits. This is an informational message. No user action is required.
2013-04-11 11:11:58.24 spid9s SQL Server Audit has started the audits. This is an informational message. No user action is required.
2013-04-11 11:11:58.24 spid9s FILESTREAM: effective level = 0, configured level = 0, file system access share name = 'MSSQLSERVER'.
2013-04-11 11:11:58.27 spid9s SQL Trace ID 1 was started by login "sa".
2013-04-11 11:11:58.27 spid9s Starting up database 'mssqlsystemresource'.
2013-04-11 11:11:58.29 spid9s The resource database build version is 10.50.2811. This is an informational message only. No user action is required.
2013-04-11 11:11:58.38 spid9s Server name is 'SGL-PANJ-SCCM'. This is an informational message only. No user action is required.
2013-04-11 11:11:58.39 spid12s Starting up database 'model'.
2013-04-11 11:11:58.39 Server The certificate [Cert Hash(sha1) "6E37DB5BAE65C704EF7C1BA0DE6587F34B5E8A53"] was successfully loaded for encryption.
2013-04-11 11:11:58.40 Server Server is listening on [ 'any' <ipv6> 1433].
2013-04-11 11:11:58.40 Server Server is listening on [ 'any' <ipv4> 1433].
2013-04-11 11:11:58.40 Server Server local connection provider is ready to accept connection on [
\\ . \pipe \SQLLocal \ MSSQLSERVER].
2013-04-11 11:11:58.40 Server Server named pipe provider is ready to accept connection on [ \\. \ pipe\ sql \ query].
2013-04-11 11:11:58.40 Server Server is listening on [ ::1 <ipv6> 1434].
2013-04-11 11:11:58.40 Server Server is listening on [ 127.0.0.1 <ipv4> 1434].
2013-04-11 11:11:58.40 Server Dedicated admin connection support was established for listening locally on port 1434.
2013-04-11 11:11:58.41 Logon Error: 17187, Severity: 16, State: 1.
2013-04-11 11:11:58.41 Logon SQL Server is not ready to accept new client connections. Wait a few minutes before trying again. If you have access to the error log, look for the informational message that indicates that SQL
Server is ready before trying to connect again. [CLIENT: 172.17.5.20]
2013-04-11 11:11:58.42 spid12s The database 'model' is marked RESTORING and is in a state that does not allow recovery to be run.
2013-04-11 11:11:58.42 spid12s Error: 927, Severity: 14, State: 2.
2013-04-11 11:11:58.42 spid12s Database 'model' cannot be opened. It is in the middle of a restore.
2013-04-11 11:11:58.42 spid12s Could not create tempdb. You may not have enough disk space available. Free additional disk space by deleting other files on the tempdb drive and then restart SQL Server. Check for additional errors in
the event log that may indicate why the tempdb files could not be initialized.
2013-04-11 11:11:58.42 spid12s SQL Trace was stopped due to server shutdown. Trace ID = '1'. This is an informational message only; no user action is required.
2013-04-11 11:11:58.43 Server The SQL Server Network Interface library could not register the Service Principal Name (SPN) for the SQL Server service. Error: 0x2098, state: 15. Failure to register an SPN may cause integrated authentication
to fall back to NTLM instead of Kerberos. This is an informational message. Further action is only required if Kerberos authentication is required by authentication policies.
2013-04-11 11:11:58.43 Server SQL Server is now ready for client connections. This is an informational message; no user action is required.
2013-04-11 11:11:58.52 Logon Error: 17188, Severity: 16, State: 1.
2013-04-11 11:11:58.52 Logon SQL Server cannot accept new connections, because it is shutting down. The connection has been closed. [CLIENT: ::1]
2013-04-11 11:11:58.54 Logon Error: 17188, Severity: 16, State: 1.
2013-04-11 11:11:58.54 Logon SQL Server cannot accept new connections, because it is shutting down. The connection has been closed. [CLIENT: 192.168.6.2]
2013-04-11 11:11:58.57 spid15s A new instance of the full-text filter daemon host process has been successfully started.
2013-04-11 11:11:58.60 spid16s Starting up database 'ReportServer'.
2013-04-11 11:11:58.60 spid17s Starting up database 'ReportServerTempDB'.
2013-04-11 11:11:58.60 spid18s Starting up database 'CM_P01'.
2013-04-11 11:11:58.60 spid15s Starting up database 'msdb'.
Cannot close event log because there are still event handle users active.
Regards,
Henoy
Maybe you are looking for
-
Industrial hygiene safety scenario
Hi Team, Please write me steps involved in "Industrial hygiene safety scenario". What are the T-Codes. What master data is required. Thanks
-
hi, At the time of recociclitation of challan ,after execution when i save the document system give run time error. Runtime Errors CALL_FUNCTION_CONFLICT_LENG Except. CX_SY_DYN_CALL_ILLEGAL_TYPE Date and Time 10.03.20
-
when opening my webmail page on talktalk it tells me I have undifined mail and will not open it! In internet explorer I can access it with no problems but as I prefer firefox I am now stuck!
-
Using a 4x3 iMovie '09 Project in iMovie 2013
I have come to the conclusion that there is no way to create a new iMovie 2013 project in anything else but widescreen <sigh>, and since I need a 4x3 project without black sidebars for display on a 4x3 projection screen, I thought I was smart to crea
-
not really but it says something like... This accessory is not compatible with the iphone... blah blah blah would you like to switch to airplane mode to avoid audio interference. And after i restore it it lets me unlock it with sound then it pops bac