|
|
|
Old Hand
      
Group: General Forum Members
Last Login: Yesterday @ 6:36 AM
Points: 306,
Visits: 1,015
|
|
|
|
|
|
SSC-Enthusiastic
      
Group: General Forum Members
Last Login: Yesterday @ 7:34 AM
Points: 154,
Visits: 1,281
|
|
Useful utility, thanks Rudy
Cheers,
JohnA
|
|
|
|
|
Old Hand
      
Group: General Forum Members
Last Login: Yesterday @ 6:36 AM
Points: 306,
Visits: 1,015
|
|
I hope to bring more utilities soon.
Thanks for your comments
|
|
|
|
|
Grasshopper
      
Group: General Forum Members
Last Login: Thursday, May 09, 2013 7:51 AM
Points: 12,
Visits: 252
|
|
For SQL 2008, the following will return a "specified service does not exist as an installed service" error:
EXEC master.dbo.xp_servicecontrol N'QUERYSTATE',N'MsDtsServer' I changed the service name to MsDtsServer100 and it returned "Running.":
EXEC master.dbo.xp_servicecontrol N'QUERYSTATE',N'MsDtsServer100'
|
|
|
|
|
Old Hand
      
Group: General Forum Members
Last Login: Yesterday @ 6:36 AM
Points: 306,
Visits: 1,015
|
|
Thanks for the update.
Do you know if this change will work on SQL 2005 installation? i don't think this will. Guess there may need to be a version of SQL '05 and '08
Thanks for take the time to look into this.
Rudy
|
|
|
|
|
Grasshopper
      
Group: General Forum Members
Last Login: Thursday, May 09, 2013 7:51 AM
Points: 12,
Visits: 252
|
|
|
|
|
|
Grasshopper
      
Group: General Forum Members
Last Login: Thursday, May 09, 2013 7:51 AM
Points: 12,
Visits: 252
|
|
Also, the registry keys are different:
Had to change:
SET @REGKEY = 'System\CurrentControlSet\Services\MsDtsServer' to
SET @REGKEY = 'System\CurrentControlSet\Services\MsDtsServer100'
|
|
|
|
|
SSC Journeyman
      
Group: General Forum Members
Last Login: Yesterday @ 3:27 PM
Points: 77,
Visits: 535
|
|
WOW, excellent script. However, this only give you the information for a single instance.
These script could be modified to loop though all the instances.
My addition: To get a list of the instances on that machine, use the following:
------------------------------------ create table #instances (c1 varchar (100), c2 varchar (100))
insert into #instances EXEC master..xp_regenumvalues 'HKEY_LOCAL_MACHINE','SOFTWARE\Microsoft\Microsoft SQL Server\Instance Names\SQL'
select c1 from #instances
drop table #instances. ------------------------------------
|
|
|
|
|
Old Hand
      
Group: General Forum Members
Last Login: Yesterday @ 6:36 AM
Points: 306,
Visits: 1,015
|
|
Good idea about looking at all the instances. When I wrote this code, I was using it as a subset for another code that would allow me to collect all SQL server information on a per instance bases. This code (still working on it) will create information that will allow you to rebuild a server exactly like it was originally.
Glad to see that others are finding this useful.
Thanks for all the comments!
Rudy
|
|
|
|
|
SSC-Enthusiastic
      
Group: General Forum Members
Last Login: Yesterday @ 7:34 AM
Points: 154,
Visits: 1,281
|
|
A useful addition might be the option to display the service account.
Rudy, I've got a script that returns the SQLService and SQLAgent accounts for an instance, but it would be really nice if it could be incorporated in your code returning all service accounts.
Lots of people have SQL instances running under the wrong accounts without realising it. If a test instance (for example) runs under the same service account as a live instance, then test jobs may have (accidentally) too much potential access to Live
Cheers,
JohnA
|
|
|
|