Showing posts with label service. Show all posts
Showing posts with label service. Show all posts

Monday, March 19, 2012

GOT IT...Re: Enabling service broker

Used the SET NEW_BROKER
Although, I DID follow procedure on this db. msdb was backed up from one
server and restored on this one. This is proper as I was told.
"Tim Greenwood" <tim_greenwood AT yahoo DOT com> wrote in message
news:%23v8kw18FHHA.2464@.TK2MSFTNGP06.phx.gbl...
> Hmm...tried that and got this error:
> Msg 9776, Level 16, State 1, Line 1
> Cannot enable the Service Broker in database "msdb" because the Service
> Broker GUID in the database (3861FC2B-EFB6-4213-A5DC-864A3F21A018) does
> not match the one in sys.databases (A1AEBD82-B5CE-4B27-88CC-E465AA90F9E1).
> Msg 5069, Level 16, State 1, Line 1
> ALTER DATABASE statement failed.
> How can I force this GUID to match?
>
> "Roger Wolter[MSFT]" <rwolter@.online.microsoft.com> wrote in message
> news:%23tN%23mv8FHHA.1064@.TK2MSFTNGP04.phx.gbl...
>Moving system datbases ([master], [model], [temp] and [msdb]
) between
instances of the is never proper, no matter the steps involved.
This posting is provided "AS IS" with no warranties, and confers no rights.
HTH,
~ Remus Rusanu
SQL Service Broker
http://msdn2.microsoft.com/en-us/library/ms166043(en-US,SQL.90).aspx
"Tim Greenwood" <tim_greenwood AT yahoo DOT com> wrote in message
news:OFQHXD9FHHA.1232@.TK2MSFTNGP05.phx.gbl...
> Used the SET NEW_BROKER
> Although, I DID follow procedure on this db. msdb was backed up from one
> server and restored on this one. This is proper as I was told.
>
> "Tim Greenwood" <tim_greenwood AT yahoo DOT com> wrote in message
> news:%23v8kw18FHHA.2464@.TK2MSFTNGP06.phx.gbl...
>|||But this is supposedly the only way to move maintenance plans from one
server to the other WHILE RETAINING the ability to modify them graphically.
If you import/export through integration services it never allows you to
use the designer on the resulting package.
Is there some other way around this restriction? I need to design these
backup plans on my development machine and then deploy them. But they
should still be maintainable from the server no?
"Remus Rusanu [MSFT]" <Remus.Rusanu.NoSpam@.microsoft.com.nowhere.moon> w
rote
in message news:O$p$cU%23FHHA.5104@.TK2MSFTNGP03.phx.gbl...
> Moving system datbases ([master], [model], [temp] and [msd
b]) between
> instances of the is never proper, no matter the steps involved.
> --
> This posting is provided "AS IS" with no warranties, and confers no
> rights.
> HTH,
> ~ Remus Rusanu
> SQL Service Broker
> http://msdn2.microsoft.com/en-us/library/ms166043(en-US,SQL.90).aspx
>
> "Tim Greenwood" <tim_greenwood AT yahoo DOT com> wrote in message
> news:OFQHXD9FHHA.1232@.TK2MSFTNGP05.phx.gbl...
>|||I know KB224071 gives steps on how to move system databases, but those steps
ignore new functionality, like server level event notifications, dbMail and
Service Broker. Not to mention any usage of the secret storage facilities
(keys, certificates, encrypted data)...
What you did (NEW_BROKER) will solve the issue of starting up the broker in
msdb after a move, but at the cost of loosing any active dialog in in the
database, thus loosing any pending mail sent through dbMail and any pending
servel level notifications. I understand that is highly questionable if you
would have such active items and still move the database...
You have to be aware that when moving the msdb you are moving and
ovewrwritting way more than just your maintenance plan graphical designer
state. By overwriting the other's server msdb with yours, you are
overwriting the state of any feature that relies on msdb, and there are
plenty (I just mentioned server level event notifications and dbMail).
You could use the SQL Feedback at
https://connect.microsoft.com/SQLServer/Feedback to mention the issue that
the graphical designer uses a system database to store it's state, thus
tying it to a specific instance.
This posting is provided "AS IS" with no warranties, and confers no rights.
HTH,
~ Remus Rusanu
SQL Service Broker
http://msdn2.microsoft.com/en-us/library/ms166043(en-US,SQL.90).aspx
"Tim Greenwood" <tim_greenwood AT yahoo DOT com> wrote in message
news:OABOpZ%23FHHA.3976@.TK2MSFTNGP05.phx.gbl...
> But this is supposedly the only way to move maintenance plans from one
> server to the other WHILE RETAINING the ability to modify them
> graphically. If you import/export through integration services it never
> allows you to use the designer on the resulting package.
> Is there some other way around this restriction? I need to design these
> backup plans on my development machine and then deploy them. But they
> should still be maintainable from the server no?
>
> "Remus Rusanu [MSFT]" <Remus.Rusanu.NoSpam@.microsoft.com.nowhere.moon>
> wrote in message news:O$p$cU%23FHHA.5104@.TK2MSFTNGP03.phx.gbl...
>

Monday, March 12, 2012

Good Reporting Service Books

I'm wondering if anyone has any good Reporting Services books they recommend.
I'm a DBA so I don't actually do or need to know the report development and
deployment but need to know the back-end of RS - the security - etc. Many of
the books I've seen so far concentrate on report creation. If anyone has any
good suggestions they would be appreciated.http://www.sqlreportingservices.net/
Hitchhiker's Guide to SQL Server 2000 Reporting Services
--
Adrian M.
MCP
"tsorv" <tsorv@.discussions.microsoft.com> wrote in message
news:8FAD8E6A-8CDF-44A7-B82F-53D50A1585A4@.microsoft.com...
> I'm wondering if anyone has any good Reporting Services books they
> recommend.
> I'm a DBA so I don't actually do or need to know the report development
> and
> deployment but need to know the back-end of RS - the security - etc. Many
> of
> the books I've seen so far concentrate on report creation. If anyone has
> any
> good suggestions they would be appreciated.|||I own 6 books - as a DBA I find them all to offer different ways of
explaining things.
I reccommend the following 4 - ranking them from highest to lowest for what
you want:
Hitchhikers Guide To SQL Server 2000 ISBN: 0-321-26828-8
Microsoft Reporting Services In Action ISBN: 1-932394-22-2
Professional SQL Server Reporting Services ISBN: 0-7645-6878-7
Microsoft SQL Server 2000 Reporting Services ISBN: 0-07-223216-1
Of course, each book offers information on report creation - but tucked away
in each is information on report security that every DBA should know, in
addition to installation issues, solutions, installing SSL, etc that have
nothing to do with report creation.
Good luck.
=-Chris
"tsorv" <tsorv@.discussions.microsoft.com> wrote in message
news:8FAD8E6A-8CDF-44A7-B82F-53D50A1585A4@.microsoft.com...
> I'm wondering if anyone has any good Reporting Services books they
> recommend.
> I'm a DBA so I don't actually do or need to know the report development
> and
> deployment but need to know the back-end of RS - the security - etc. Many
> of
> the books I've seen so far concentrate on report creation. If anyone has
> any
> good suggestions they would be appreciated.|||I'd definately recommend the Hitchhikers Guide. As yet another DBA I found
it very useful and it has a good focus on security. It also got me
interested in the SOAP side of things and I've ben having lots of fun/pain
writing some scripting utilities for environment migrations. I haven't read
the others but I have ordered Reporting Services in Action based on
recommendations from others.
--
HTH
Jasper Smith (SQL Server MVP)
http://www.sqldbatips.com
I support PASS - the definitive, global
community for SQL Server professionals -
http://www.sqlpass.org
"Christopher Conner" <someone@.someplace.com> wrote in message
news:u6uyONGFFHA.1836@.tk2msftngp13.phx.gbl...
>I own 6 books - as a DBA I find them all to offer different ways of
>explaining things.
> I reccommend the following 4 - ranking them from highest to lowest for
> what you want:
> Hitchhikers Guide To SQL Server 2000 ISBN: 0-321-26828-8
> Microsoft Reporting Services In Action ISBN: 1-932394-22-2
> Professional SQL Server Reporting Services ISBN: 0-7645-6878-7
> Microsoft SQL Server 2000 Reporting Services ISBN: 0-07-223216-1
> Of course, each book offers information on report creation - but tucked
> away in each is information on report security that every DBA should know,
> in addition to installation issues, solutions, installing SSL, etc that
> have nothing to do with report creation.
> Good luck.
> =-Chris
>
> "tsorv" <tsorv@.discussions.microsoft.com> wrote in message
> news:8FAD8E6A-8CDF-44A7-B82F-53D50A1585A4@.microsoft.com...
>> I'm wondering if anyone has any good Reporting Services books they
>> recommend.
>> I'm a DBA so I don't actually do or need to know the report development
>> and
>> deployment but need to know the back-end of RS - the security - etc.
>> Many of
>> the books I've seen so far concentrate on report creation. If anyone has
>> any
>> good suggestions they would be appreciated.
>|||hi
I studied differnt books on security.
Among all those books I felt " Microsoft SQL server 2000 Reporting Services"
is the best fit for DBA.
Allthebest
"Adrian M." wrote:
> http://www.sqlreportingservices.net/
> Hitchhiker's Guide to SQL Server 2000 Reporting Services
> --
> Adrian M.
> MCP
> "tsorv" <tsorv@.discussions.microsoft.com> wrote in message
> news:8FAD8E6A-8CDF-44A7-B82F-53D50A1585A4@.microsoft.com...
> > I'm wondering if anyone has any good Reporting Services books they
> > recommend.
> > I'm a DBA so I don't actually do or need to know the report development
> > and
> > deployment but need to know the back-end of RS - the security - etc. Many
> > of
> > the books I've seen so far concentrate on report creation. If anyone has
> > any
> > good suggestions they would be appreciated.
>
>|||tsorv wrote:
> I'm wondering if anyone has any good Reporting Services books they recommend.
> I'm a DBA so I don't actually do or need to know the report development and
> deployment but need to know the back-end of RS - the security - etc. Many of
> the books I've seen so far concentrate on report creation. If anyone has any
> good suggestions they would be appreciated.
Unfortunately, I have read several and they all stink and contain
errors. The worst Crystal reports book is better than the best RS books.|||Bryon wrote:
> tsorv wrote:
>> I'm wondering if anyone has any good Reporting Services books they
>> recommend. I'm a DBA so I don't actually do or need to know the
>> report development and deployment but need to know the back-end of RS
>> - the security - etc. Many of the books I've seen so far concentrate
>> on report creation. If anyone has any good suggestions they would be
>> appreciated.
>
> Unfortunately, I have read several and they all stink and contain
> errors. The worst Crystal reports book is better than the best RS books.
Although after reading the other posts I need to checkout the Hitchhiker
book.|||I definitely recommend the Hitchhiker's Guide, but beware that it seems
to be targeted more at the administrator, DBA, or lead developer,
rather than the average report developer. By this, I mean that it
contains a wealth of knowledge on installation, configuration,
security, and programability, but the chapters on Report Design are
limited to solving some higher level problems rather than focusing on
the basics. IMHO it isnt comprehensive enough to teach someone how to
write reports if they have never used the Report Designer.
This is fine for the "one man show" approach to using Sql Reporting
Services, but any large implementation will likely have one or two
admins/leads, and at least 3-4 people who are pure "report authors".
The latter group isnt always interested in many of the advanced topics
and may need more "bread and butter" tutorials on how to create various
styles of reports.
Can anyone recommend a RS book targeted more at the report
designer/author?
Thank you,
Lance Hunt
http://weblogs.asp.net/lhunt/

Good reasons for 'sa' and service accounts passwords to be control

By other than the DBA. We have a security group with our org that wants to
control sa and system accounts for SQL Servers. We're desparately trying to
hold on to our control of these, but need to justify with the business unit.
Anyone got a really great reason not to let a non-DBA control these?
"David T." <DavidT@.discussions.microsoft.com> wrote in message
news:2A6FC7A8-EE65-4DBA-86A2-78C1DD836333@.microsoft.com...
> By other than the DBA. We have a security group with our org that wants
> to
> control sa and system accounts for SQL Servers. We're desparately trying
> to
> hold on to our control of these, but need to justify with the business
> unit.
> Anyone got a really great reason not to let a non-DBA control these?
No, I mostly agree. Accounts and passwords which are shared among groups of
people are inherently insecure. SA should be disabled, and the passwords
for fixed service accounts should be centrally and closely controlled. In
the normal course of things, people should connect with windows integrated
authentication and service accounts should be managed centrally.
But, and this is a _big_ but, a DBA should be a local administrator of any
database server and have sysadmin fixed server role. This will give a DBA
the ability, in a pinch, to reset passwords change service accounts and do
whatever is necessary to react in a "data emergency".
David

Good reasons for 'sa' and service accounts passwords to be control

By other than the DBA. We have a security group with our org that wants to
control sa and system accounts for SQL Servers. We're desparately trying to
hold on to our control of these, but need to justify with the business unit.
Anyone got a really great reason not to let a non-DBA control these?"David T." <DavidT@.discussions.microsoft.com> wrote in message
news:2A6FC7A8-EE65-4DBA-86A2-78C1DD836333@.microsoft.com...
> By other than the DBA. We have a security group with our org that wants
> to
> control sa and system accounts for SQL Servers. We're desparately trying
> to
> hold on to our control of these, but need to justify with the business
> unit.
> Anyone got a really great reason not to let a non-DBA control these?
No, I mostly agree. Accounts and passwords which are shared among groups of
people are inherently insecure. SA should be disabled, and the passwords
for fixed service accounts should be centrally and closely controlled. In
the normal course of things, people should connect with windows integrated
authentication and service accounts should be managed centrally.
But, and this is a _big_ but, a DBA should be a local administrator of any
database server and have sysadmin fixed server role. This will give a DBA
the ability, in a pinch, to reset passwords change service accounts and do
whatever is necessary to react in a "data emergency".
David

Good reasons for 'sa' and service accounts passwords to be control

By other than the DBA. We have a security group with our org that wants to
control sa and system accounts for SQL Servers. We're desparately trying to
hold on to our control of these, but need to justify with the business unit.
Anyone got a really great reason not to let a non-DBA control these?"David T." <DavidT@.discussions.microsoft.com> wrote in message
news:2A6FC7A8-EE65-4DBA-86A2-78C1DD836333@.microsoft.com...
> By other than the DBA. We have a security group with our org that wants
> to
> control sa and system accounts for SQL Servers. We're desparately trying
> to
> hold on to our control of these, but need to justify with the business
> unit.
> Anyone got a really great reason not to let a non-DBA control these?
No, I mostly agree. Accounts and passwords which are shared among groups of
people are inherently insecure. SA should be disabled, and the passwords
for fixed service accounts should be centrally and closely controlled. In
the normal course of things, people should connect with windows integrated
authentication and service accounts should be managed centrally.
But, and this is a _big_ but, a DBA should be a local administrator of any
database server and have sysadmin fixed server role. This will give a DBA
the ability, in a pinch, to reset passwords change service accounts and do
whatever is necessary to react in a "data emergency".
David

Friday, March 9, 2012

Good Old Event ID: 18456 - Can't figure this one out!

Hi everyone,

I've got a clean SQL Server 2005 Enterprise Edition installation, with a domain account configured as the service account. My application log is now flooded with the following error message:

Event Type: Failure Audit
Event Source: MSSQLSERVER
Event Category: (4)
Event ID: 18456
Date: 5/25/2007
Time: 1:57:00 AM
User: TNG\TNG-SQL_Service
Computer: TNG-MOSSDB01
Description:
Login failed for user 'TNG\TNG-SQL_Service'. [CLIENT: <local machine>]

For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.
Data:
0000: 18 48 00 00 0e 00 00 00 .H......
0008: 0d 00 00 00 54 00 4e 00 ....T.N.
0010: 47 00 2d 00 4d 00 4f 00 G.-.M.O.
0018: 53 00 53 00 44 00 42 00 S.S.D.B.
0020: 30 00 31 00 00 00 07 00 0.1.....
0028: 00 00 6d 00 61 00 73 00 ..m.a.s.
0030: 74 00 65 00 72 00 00 00 t.e.r...

And when I open up the SQL logs, I'm getting two errors - one is essentially the same as the above, and the other is:

Date 5/25/2007 1:51:00 AM
Log SQL Server (Current - 5/25/2007 1:51:00 AM)

Source Logon

Message
Error: 18456, Severity: 14, State: 16.

Now I've seen all kinds of posts about granting rights to master and such - and I have, but these errors are not going away. I've gone so far as to create new service accounts and even switch over to the local system account - and the error still occurs. Does anyone have any insight into other routes / approaches I can take with this?

Thank you,

Chris

From BOL topic Troubleshooting: Login failed for user 'x'

Additional Error Information

To increase security, the error message that is returned to the client deliberately hides the nature of the authentication error. However, in the SQL Server error log, a corresponding error contains an error state that maps to an authentication failure condition. Compare the error state to the following list to determine the reason for the login failure.

State Description

2

User ID is not valid.

5

User ID is not valid.

6

An attempt was made to use a Windows login name with SQL Server Authentication.

7

Login is disabled, and the password is incorrect.

8

The password is incorrect.

9

Password is not valid.

11

Login is valid, but server access failed.

12

Login is valid login, but server access failed.

18

Password must be changed.

Other error states exist and signify an unexpected internal processing error.

You may need to contact Support for this.

HTH,

-Steven Gott

SDE/T

SQL Server

|||

Hi Steve,

Do you by chance have any information on State = 16?

Thanks,
Chris

|||

It is related to not being able to establish a database session.

Check the default_database for your account and make sure it is master.

How are you changing the service account? Please make sure you use the tools provided in sql server because usinging windows scm will not do the whole job.

HTH,

-Steven Gott

SDE/T

SQL Server

|||

Steve,

The default_database for the account is master, and the service accounts were set through the SQL Server Configuration Manager. I went back into it and reset all of them just in case - but still getting the error. Just doesn't make any sense. In fact, I'm also seeing the same error for another account - the service account I use with SharePoint (residing on another server). Same exact errors in the Event Log for the Server & the SQL Logs.

Are there any statements I can run against the master to see if maybe an entry is missing? I'm drawing at straws with this.

Thanks,
Chris

|||

You can try the following statements to see if there is anything unexpected:

SELECT name, principal_id, type_desc, is_disabled, default_database_name, default_language_name

FROM sys.server_principals

WHERE name = 'login_name'

go

SELECT name, database_id, user_access_desc, state_desc, is_in_standby

FROM sys.databases

WHERE name = 'default_db_name'

go

SELECT suser_name(role_principal_id), suser_name(member_principal_id)

FROM sys.server_role_members

WHERE member_principal_id = suser_id( 'login_name' )

go

SELECT class_desc, suser_name(grantee_principal_id), permission_name, state_desc

FROM sys.server_permissions

WHERE grantee_principal_id = suser_id( 'login_name' )

Go

Pay attention to the default database, if the login is disabled and if it has at least CONNECT SERVER permission.

I hope this helps,

-Raul Garcia

SDE/T

SQL Server Engine

Sunday, February 26, 2012

gmaniz service failed

Dear all,
please help me to find error about 'the gmaniz service failed to start
due to the following error'
Thanks
This is not a SQL Server service. In fact, I didn't get one single hit (except this post) on Google.
My guess is that this is some in-house developed software, so you need to find what it is and talk
to the people responsible for it.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"ekodian" <ekodian@.gmail.com> wrote in message news:e8beptSUFHA.3944@.tk2msftngp13.phx.gbl...
> Dear all,
> please help me to find error about 'the gmaniz service failed to start due to the following error'
> Thanks

gmaniz service failed

Dear all,
please help me to find error about 'the gmaniz service failed to start
due to the following error'
ThanksThis is not a SQL Server service. In fact, I didn't get one single hit (except this post) on Google.
My guess is that this is some in-house developed software, so you need to find what it is and talk
to the people responsible for it.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"ekodian" <ekodian@.gmail.com> wrote in message news:e8beptSUFHA.3944@.tk2msftngp13.phx.gbl...
> Dear all,
> please help me to find error about 'the gmaniz service failed to start due to the following error'
> Thanks

gmaniz service failed

Dear all,
please help me to find error about 'the gmaniz service failed to start
due to the following error'
ThanksThis is not a SQL Server service. In fact, I didn't get one single hit (exce
pt this post) on Google.
My guess is that this is some in-house developed software, so you need to fi
nd what it is and talk
to the people responsible for it.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"ekodian" <ekodian@.gmail.com> wrote in message news:e8beptSUFHA.3944@.tk2msftngp13.phx.gbl...

> Dear all,
> please help me to find error about 'the gmaniz service failed to start due
to the following error'
> Thanks

Globally Change SQL Svc Account passwords

Hello. Is there any batch method to do a mass change of
multiple server's SQL Server Service account and/or
passwords? Just looking for any tips on changing MANY SQL
boxes' Service startup accounts. Is there any batch
commands to set a service account logon? THanks, BruceBelow is a VBScript to change service passwords. It will change the
password for all of the services on the specified servers running under
the account.
'begin script
Option Explicit
Dim oWin32_Services, oWin32_Service
Dim ServerName, StartName, NewPassword, Messages
' *** specify Windows account and new password here ***
StartName = "Domain\Account" 'Windows service account name
NewPassword = "NewAccountPassword"
' **************************
' *** specify server list here ***
Call ChangeServerServicePasswords("ServerName1", _
StartName, _
NewPassword, _
Messages)
Call ChangeServerServicePasswords("ServerName2", _
StartName, _
NewPassword, _
Messages)
' **************************
WScript.Echo Messages
Sub ChangeServerServicePasswords(ServerName, _
StartName, _
NewPassword, _
Messages)
Dim SQL
'select all services running under this account
SQL = "SELECT * FROM Win32_Service WHERE StartName = '" & _
Replace(StartName, "\", "\\") & "'"
Set oWin32_Services =GetObject("winmgmts:{impersonationLevel=impersonate}!//" & _
ServerName & _
"/root/cimv2").ExecQuery(SQL, , 48)
For Each oWin32_Service In oWin32_Services
Call ChangeServicePassword(oWin32_Service, _
NewPassword, _
Messages)
Next
End Sub
Sub ChangeServicePassword(oWin32_Service, _
NewPassword, _
Messages)
Dim intResult
intResult = oWin32_Service.Change(,,,,,,,NewPassword)
If intResult = 0 Then
Messages = Messages & _
oWin32_Service.SystemName & " " & _
oWin32_Service.Caption & _
" service account password changed for account " & _
oWin32_Service.StartName & vbcrlf
Else
Messages = Messages & _
oWin32_Service.SystemName & " " & _
oWin32_Service.Caption & _
" service account password change failed for account " & _
oWin32_Service.StartName & _
". Win32_Service.Change result is " & _
CStr(intResult) & vbcrlf
End If
End Sub
'end scrpt
Hope this helps.
Dan Guzman
SQL Server MVP
--
SQL FAQ links (courtesy Neil Pike):
http://www.ntfaq.com/Articles/Index.cfm?DepartmentID=800
http://www.sqlserverfaq.com
http://www.mssqlserver.com/faq
--
"Bruce de Freitas" <bruce@.defreitas.com> wrote in message
news:056a01c3addf$98198f30$a001280a@.phx.gbl...
> Hello. Is there any batch method to do a mass change of
> multiple server's SQL Server Service account and/or
> passwords? Just looking for any tips on changing MANY SQL
> boxes' Service startup accounts. Is there any batch
> commands to set a service account logon? THanks, Bruce|||Maybe if you code something through WMI or something
similar, but there is no way I know of.
And if you're on a cluster, you have to do it through
Enterprise Manager anyway, so it wouldn't take care of
failover clustering installations of SQL Server.
>--Original Message--
>Hello. Is there any batch method to do a mass change of
>multiple server's SQL Server Service account and/or
>passwords? Just looking for any tips on changing MANY
SQL
>boxes' Service startup accounts. Is there any batch
>commands to set a service account logon? THanks, Bruce
>.
>|||wow... Great stuff Dan, thanks! Bruce
>--Original Message--
>Below is a VBScript to change service passwords. It will
change the
>password for all of the services on the specified servers
running under
>the account.
>
>'begin script
>Option Explicit
>Dim oWin32_Services, oWin32_Service
>Dim ServerName, StartName, NewPassword, Messages
>' *** specify Windows account and new password here ***
>StartName = "Domain\Account" 'Windows service account
name
>NewPassword = "NewAccountPassword"
>' **************************
>' *** specify server list here ***
>Call ChangeServerServicePasswords("ServerName1", _
> StartName, _
> NewPassword, _
> Messages)
>Call ChangeServerServicePasswords("ServerName2", _
> StartName, _
> NewPassword, _
> Messages)
>' **************************
>WScript.Echo Messages
>Sub ChangeServerServicePasswords(ServerName, _
> StartName, _
> NewPassword, _
> Messages)
> Dim SQL
> 'select all services running under this account
> SQL = "SELECT * FROM Win32_Service WHERE StartName
= '" & _
> Replace(StartName, "\", "\\") & "'"
> Set oWin32_Services =>GetObject("winmgmts:{impersonationLevel=impersonate}!//"
& _
> ServerName & _
> "/root/cimv2").ExecQuery(SQL, , 48)
> For Each oWin32_Service In oWin32_Services
> Call ChangeServicePassword(oWin32_Service, _
> NewPassword, _
> Messages)
> Next
>End Sub
>Sub ChangeServicePassword(oWin32_Service, _
> NewPassword, _
> Messages)
> Dim intResult
> intResult = oWin32_Service.Change(,,,,,,,NewPassword)
> If intResult = 0 Then
> Messages = Messages & _
> oWin32_Service.SystemName & " " & _
> oWin32_Service.Caption & _
> " service account password changed for
account " & _
> oWin32_Service.StartName & vbcrlf
> Else
> Messages = Messages & _
> oWin32_Service.SystemName & " " & _
> oWin32_Service.Caption & _
> " service account password change failed for
account " & _
> oWin32_Service.StartName & _
> ". Win32_Service.Change result is " & _
> CStr(intResult) & vbcrlf
> End If
>End Sub
>'end scrpt
>
>--
>Hope this helps.
>Dan Guzman
>SQL Server MVP
>--
>SQL FAQ links (courtesy Neil Pike):
>http://www.ntfaq.com/Articles/Index.cfm?DepartmentID=800
>http://www.sqlserverfaq.com
>http://www.mssqlserver.com/faq
>--
>"Bruce de Freitas" <bruce@.defreitas.com> wrote in message
>news:056a01c3addf$98198f30$a001280a@.phx.gbl...
>> Hello. Is there any batch method to do a mass change of
>> multiple server's SQL Server Service account and/or
>> passwords? Just looking for any tips on changing MANY
SQL
>> boxes' Service startup accounts. Is there any batch
>> commands to set a service account logon? THanks, Bruce
>
>.
>