?
Solved

solve error please

Posted on 2004-08-23
12
Medium Priority
?
747 Views
Last Modified: 2010-08-05
i have got some piece of code online

<%
sComputer        = "QIXSOL-9"
sSQLServer      = "QIXSOL-9"
Set oInstance = GetObject("winmgmts:{impersonationLevel=impersonate}//" & sComputer & "/" & "root/MicrosoftSQLServer:MSSQL_SQLServer.Name=" & Chr(34) & sSQLServer & Chr(34))
Set oOutParam = oInstance.Stop()
If oOutParam.ReturnValue = 0 Then
Response.Write sSQLServer & " SQL Server Stopped Successfully"
Else
            Response.Write "Stopping of " & sSQLServer & " SQL Server Failed with error " & _
            oOutParam.Description
End If
set oInstance=nothing
set oOutParam=nothing
%>

i am log in as an administrator with full rights and its giving me this error

(0x8004100E)
/hostcont/zextra/untitled.asp, line 6

0
Comment
Question by:bkniazi
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 4
  • 3
12 Comments
 
LVL 3

Expert Comment

by:JagC
ID: 11869313
Service Pack 1 for Windows 2000 has been known to cause this error as it updates the WMI Service.

Try overwriting the winmgmt.exe file with the original (this should be here: C:\WINNT\$NtServicePackUninstall$). You will have to stop the WMI Service first.

I would suggest renaming the winmgmt.exe file to winmgmt.exe.org so if it doesn't help you can switch back easily by deleting the file and renaming the original file back to .exe.
0
 

Author Comment

by:bkniazi
ID: 11869435
from where can i get the orginall copy of winmgmt.exe or you mean the same to be overright.
0
 
LVL 3

Accepted Solution

by:
JagC earned 300 total points
ID: 11869745
When installing the service pack it creates backups of all files it overwrites

the backups are in the windows directory and have $ at the beginning and the end. I installed direct x 9b the other day and so there's a folder called $NtUninstallKB839643-DirectX9$. This contains the original files that were replaced.
The files that were replaced when applying the service pack should be in a folder called $NtServicePackUninstall$ or similar.

Alternatively you can do a search in the windows folder for winmgmt.exe and look for the one in a folder that has a $ at the beginning and end. If doing a search for the file make sure that hidden folders and system folders are included (as standard the backup folders are hidden).

Once you've found the file do this:

1. Stop the WMI service (Windows Management Instrumentation)
2. rename the winmgmt.exe file in c:\windows\system32\wbem to winmgmt.exe.org
3. Find the original winmgmt.exe file. Copy it then paste it into the c:\windows\system32\wbem folder
4. Start the WMI service

note: your windows folder may be called winnt.
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Expert Comment

by:wonderdementic
ID: 11869804
To resolve this issue, reregister the Exchange 2000 namespace or the Exchange 2003 namespace with WMI:
Insert the Exchange 2000 CD-ROM, the Microsoft Small Business Server 2000 CD-ROM that contains Exchange 2000, or the Exchange 2003 CD-ROM, and then locate the Exwmi.mof file.
If you use the Exchange 2000 CD-ROM, run the following command, where cd-rom is the drive letter of the CD-ROM drive:
%systemroot%\system32\wbem\mofcomp.exe cd-rom:\setup\i386\exchange\exwmi.mof

this is it if your using exchange on the computer.... ;)
0
 

Assisted Solution

by:wonderdementic
wonderdementic earned 300 total points
ID: 11869815
this is the solution if you do not use exchange , and just installed sp1...

WMI Namespace Error: When you install Service Pack 1 you may find that you get the following error: "WMI ADAP failed to connect to namespace \\.\root\cimv2\MS_809 with the following error: 0x8004100e". This appears to be a bug in SP1. You can resolve the problem by uninstalling SP1, or by replacing all the updated versions of the file winmgmt.exe on your system with the original version in the C:\WINNT\$NtServicePackUninstall$ folder and rebooting. If you have the WMI service running, you will have to stop it first in order to be able to overwrite the file. You may also wish to simply rename the original files, to avoid overwriting them: you can then reverse the operation easily if you encounter any problems.

0
 
LVL 3

Expert Comment

by:JagC
ID: 11869826
echo?
0
 

Expert Comment

by:wonderdementic
ID: 11869883
echo off.
two answers, diffrent aproaches, whats wrong ? worried from some competition ? ;)
0
 
LVL 3

Expert Comment

by:JagC
ID: 11870235
Your first response I have no problem with - I didn't know it could be caused by Exchange.
The second is just repeating what I said in my first reply then clarified in my second.

I don't look at EE as a competition ergo I don't get worried about competition. I use it to ask questions, and while waiting for answers I help others.

But speaking as someone who both answers and asks questions I am sure I am not the only one who finds it annoying getting an email about another reply, reading the thread to find someone has just reposted the same as someone else. It wastes everyone's time.

Also, it tends to be poor etiquette if someone is guiding someone through something and someone else steamrollers in - many people are new to using EE and often the points may not be given to those that deserve them. (Although this happens regularly through accident - this is when several people hit reply and type their answers in at the same time. This can be seen as similar posts with posting times within a few minutes of each other).

Please don't get me wrong, I'm not bitching, if you're new to EE I appologise for my curt, sarcastic response. I've just seen a lot of questions disolve into arguments over points to the point an admin has to step in.

Oh yeah, I know the second post is the same as mine because I came accross that exact same paragraph when I was searching for the answer ;)
0
 

Expert Comment

by:wonderdementic
ID: 11870409
check yourself.

1. do you want the points ?
since i do not care about them, just trying to feel usefull.
2. the second post is from the wmi FAQ didnt changed it a bit for better reference.
3. i wont bother you in this post anymore, but be aware, that if it will not be resolved,
it just becoase you missunderstood my intention : HELP THIS POOR GUY.

sometimes you can understand when someone says how the machine work,
some will need the technical sheets to understand how the machine work,
some will need the logic behind,
some will just look at it and know how it works.

supplying all the approaches is what gives the user the answer,
its a pitty you do not think the same.

p.s
next time, post the first answer in the question saying :
" I AM THE ONLY PROFFESIONAL HERE, LEAVE THIS POST SINCE IM SURELY SOLVING IT ALONE!"

have a great day.
0
 
LVL 3

Expert Comment

by:JagC
ID: 11870479
/me sighs
0
 

Author Comment

by:bkniazi
ID: 11878146
when i rename the winmgmt.exe file to winmgmt.exe.org then it will automatically create the winmgmt.exe file on the same location although i also stop the wmi services.
0
 

Author Comment

by:bkniazi
ID: 11878331
i rename the file as for your instruction but i found an error message that is:
Error type: 0x80041002
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Hello, all! I just recently started using Microsoft's IIS 7.5 within Windows 7, as I just downloaded and installed the 90 day trial of Windows 7. (Got to love Microsoft for allowing 90 days) The main reason for downloading and testing Windows 7 is t…
This demonstration started out as a follow up to some recently posted questions on the subject of logging in: http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Q_28634665.html and http://www.experts-exchange.com/Programming/…
If you’ve ever visited a web page and noticed a cool font that you really liked the look of, but couldn’t figure out which font it was so that you could use it for your own work, then this video is for you! In this Micro Tutorial, you'll learn yo…
In this video, Percona Solution Engineer Dimitri Vanoverbeke discusses why you want to use at least three nodes in a database cluster. To discuss how Percona Consulting can help with your design and architecture needs for your database and infras…

762 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