Unable to access the desired machine or service

Hello experts-

I am trying to run a .bat file and retrieve stats speicific to sql servers performanace; however when I execute the .bat job, I continue to get the below error message.

I have enterprise admin, and local admin permissions on the machine.

Error:
Unable to access the desired machine or service. Check the permissions and authentication of the log service or the interactive user session against those on the machine or service being monitored.


Any help would be greatly appreciated.
nitayalevetteAsked:
Who is Participating?
 
wantabe2Connect With a Mentor Commented:
Try adding this to your batch file:

runas /user:<domain_name>\<user_name> <program_name>

Of cource you'll have to edit it for your info. I'm not sure if you enter the path in the <program name> area or just the batch file name.
0
 
nitayalevetteAuthor Commented:
Should I add this at the beginning?  Below is the syntax in the batch file:


for %%a in (MMCorpBaseline) do (logman.exe create counter SQLBaseLine%%a  -s %%a -si 00:00:30 -f csv -o "C:\sqlsat\4 Logman\%%a.csv" -v mmddhhmm -cf "C:\sqlsat\4 Logman\BaselineCountSQL.config")
REM
REM for %%a in (MMCorpBaseline) do (logman.exe start counter SQLBaseLine%%a -s %%a)
REM
REM for %%a in (MMCorpBaseline) do (logman.exe stop counter SQLBaseLine%%a -s %%a)

pause
0
 
ChiefITConnect With a Mentor Commented:
Ahh, looks like another victim of Internet Explorer Enhanced Security:

It looks just like this:
http://www.experts-exchange.com/OS/Microsoft_Operating_Systems/Server/2003_Server/Q_23351830.html
0
 
nitayalevetteAuthor Commented:
Experts, I've attempted both potential solutions, and neither work.  I am attempting to run this .bat on the local machine...the code within the .bat file


for %%a in (MMCorpBaseline) do (logman.exe create counter SQLBaseLine%%a  -s %%a -si 00:00:30 -f csv -o "C:\sqlsat\4 Logman\%%a.csv" -v mmddhhmm -cf "C:\sqlsat\4 Logman\BaselineCountSQL.config")
REM
REM for %%a in (MMCorpBaseline) do (logman.exe start counter SQLBaseLine%%a -s %%a)
REM
REM for %%a in (MMCorpBaseline) do (logman.exe stop counter SQLBaseLine%%a -s %%a)
0
All Courses

From novice to tech pro — start learning today.