Page 1 of 1 1
Topic Options
#147866 - 2005-09-15 01:58 AM Finding out if a particular service is running WIN98
Shaba1 Offline
Fresh Scripter

Registered: 2005-08-20
Posts: 44
I need to find out in the log on script that I use for my windows 98 machine IF the my antivirus network communication program is running.From what I can tell it runs as a "service" on windows 98. If so I want to skip the part of the script that copies it from the netlogon share and starts it running. I know that I could probably do that on an 2000 or xp machine easily but since 98 machines have not active services manager how would I get kix to sense if the service is running
Top
#147867 - 2005-09-15 02:48 AM Re: Finding out if a particular service is running WIN98
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22343
Loc: OK
well, I'm not sure if there even is such concept as service in win9x.

but you could look for running process, I think.
_________________________
!

download KiXnet

Top
#147868 - 2005-09-15 01:37 PM Re: Finding out if a particular service is running WIN98
Roberto_Koempel Offline
Fresh Scripter

Registered: 2005-07-05
Posts: 34
Loc: Germany
I'd check on files on the target computer and presume that if the files are there that the "service" is running too.
You could also put a batch-file into the autostart-folder of the machine in question, if you're sure that the program is not running and don't want to run there personally.
In that case the job would start the next time the user logs on.

Another, more complicated, way is to check on the registry if a certain run-key is set and, if not, copy the files and write the registry keys in question.
_________________________
Serenity: You can't stop the Signal!

Top
#147869 - 2005-09-19 11:33 AM Re: Finding out if a particular service is running WIN98
zxcv Offline
Lurker

Registered: 2005-09-19
Posts: 1
wut does kix exact mean?
Top
#147870 - 2005-09-19 11:36 AM Re: Finding out if a particular service is running WIN98
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22343
Loc: OK
kix exact?
why you ask?
_________________________
!

download KiXnet

Top
#147871 - 2005-09-19 09:09 PM Re: Finding out if a particular service is running WIN98
Shaba1 Offline
Fresh Scripter

Registered: 2005-08-20
Posts: 44
Quote:

well, I'm not sure if there even is such concept as service in win9x.

but you could look for running process, I think.




How would you check for running processes. I looked in the manual and did not see a function or macro that seems to do that. The closest I can come is checking for the resistry key and after that the next closest is checking for the file.

Top
#147872 - 2005-09-19 09:34 PM Re: Finding out if a particular service is running WIN98
NTDOC Administrator Offline
Administrator
*****

Registered: 2000-07-28
Posts: 11577
Loc: CA
Do the Windows 9x systems have WMI installed on them? If not then you'll have to use a 3rd party tool.

One that supports Windows 9x and is free can be found here.
http://www.teamcti.com/pview/

If they have WMI installed then you can write a script or check out one of the UDFs on the board here to check out if the application is running or not.

Top
#147873 - 2005-09-19 09:35 PM Re: Finding out if a particular service is running WIN98
Mart Moderator Offline
KiX Supporter
*****

Registered: 2002-03-27
Posts: 4648
Loc: The Netherlands
Maybe this will help. Not tested it cause I don't have 9x running.
EnumProcess() - enum specific process PIDs and/or terminate them
You will need WMI for this.
_________________________
Mart

- Chuck Norris once sold ebay to ebay on ebay.

Top
#147874 - 2005-09-20 11:55 PM Re: Finding out if a particular service is running WIN98
Shaba1 Offline
Fresh Scripter

Registered: 2005-08-20
Posts: 44
I went to technet and could not make heads or tails of their WMI page. Mostly the page talked about if one wanted to PROGRAM the API for wmi. Nothing about a simple install of it on 98 machines. I assume that my machines do have WMI,because I just did a search and found wmiexe.exe and wmi.dll as well as several other files in the C:\windows\systems directory. I do have pview. I downloaded it onto the machine at my desk just to see what was running. I can do a push of pview out to all the other 98 machines via the logon.kix script if I have to.
Top
#147875 - 2005-09-21 12:07 AM Re: Finding out if a particular service is running WIN98
NTDOC Administrator Offline
Administrator
*****

Registered: 2000-07-28
Posts: 11577
Loc: CA
Well writing WMI scripts is not too difficult thanks to tools like scripto-matic and UDFs here on the board.

Basically find what you're wanting to find and using a UDF plug in the parameter the UDF wants.

Take a look here for ideas/methods to confirm WMI installation. There should be a WBEM folder if it's installed. Something like this: C:\WINDOWS\SYSTEM\WBEM with some files in the folder.

If they don't have WMI then PV.EXE and extracting it's output could work as well. One could also do some checking with stuff like If Exist and check that the file and program are on the system, check that their is an entry in the Registry or in the Startup group to run the application and from there on a Windows 9x one could "assume" it's working. Not as solid a method as WMI/PV but depends on how much coding skill you have and time to put into this.

ConfirmWMI
http://www.kixtart.org/ubbthreads/showflat.php?Cat=0&Number=114011

Top
#147876 - 2005-09-24 07:24 AM Re: Finding out if a particular service is running WIN98
2manyhats Offline
Fresh Scripter

Registered: 2005-09-07
Posts: 33
From my 9x experience there will always be an entry in the registry under one of the run keys to start this pseudo service in a 9x environment. VNC is good example. Remove it and it won't start. Period.
Top
#147877 - 2005-09-25 08:53 PM Re: Finding out if a particular service is running WIN98
2manyhats Offline
Fresh Scripter

Registered: 2005-09-07
Posts: 33
Go to this link and download the WMI core 1.5. I was just there and downloaded it.

MS WMI Download Site

Good luck!

Kevin

Top
#147878 - 2005-09-25 08:59 PM Re: Finding out if a particular service is running WIN98
2manyhats Offline
Fresh Scripter

Registered: 2005-09-07
Posts: 33
In your opinion whats better and why. WMI or PV?

Kevin

Top
#147879 - 2005-09-26 02:47 AM Re: Finding out if a particular service is running WIN98
Sealeopard Offline
KiX Master
*****

Registered: 2001-04-25
Posts: 11162
Loc: Boston, MA, USA
Option #3: Getting rid of a non-supported operating system. Otherwise, WMI and a Win98 system properly set up for remote WMI access.
_________________________
There are two types of vessels, submarines and targets.

Top
#147880 - 2005-09-26 06:31 AM Re: Finding out if a particular service is running WIN98
2manyhats Offline
Fresh Scripter

Registered: 2005-09-07
Posts: 33
Yeah, I guess in a perfect world . Politics, politics, politics, oh... and money and politics, politics, politics & politics

PS. I've seen some insane hostility on the board looking at some other posts. So just to let you know at least one of us has a sense of humor until you start the mother jokes

Top
#147881 - 2005-09-26 01:23 PM Re: Finding out if a particular service is running WIN98
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22343
Loc: OK
hmm...
good to know.
so I just skip the mother part and ...
_________________________
!

download KiXnet

Top
#147882 - 2005-09-26 06:20 PM Re: Finding out if a particular service is running WIN98
2manyhats Offline
Fresh Scripter

Registered: 2005-09-07
Posts: 33
Ok, it sounds like you've done this before. Do you know what the switches are and can it be installed silently. Don't see that info on the MS site. Haven't tried connecting remotely yet but the documentation sure makes this out to be a hassle. I see why 9x is a huge waste developmental resources.

K


Edited by 2manyhats (2005-09-26 06:31 PM)

Top
#147883 - 2005-09-26 06:46 PM Re: Finding out if a particular service is running WIN98
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22343
Loc: OK
and btw.
the politics you should take is that win9x is a huge security risk and unpossible to maintain with current resources.
that's how many of us got rid of them.
try the proven tactics
_________________________
!

download KiXnet

Top
#147884 - 2005-09-30 12:16 AM Re: Finding out if a particular service is running WIN98
Shaba1 Offline
Fresh Scripter

Registered: 2005-08-20
Posts: 44
Quote:

Do the Windows 9x systems have WMI installed on them? If not then you'll have to use a 3rd party tool.

One that supports Windows 9x and is free can be found here.
http://www.teamcti.com/pview/

If they have WMI installed then you can write a script or check out one of the UDFs on the board here to check out if the application is running or not.




Thanks NTDOC. I already have PVEIW on my server just to be able to check out some things. I can copy it from the netlog directory to each 98 machine then use it also to kill whatever spyware processes are running before I run spybot on the machine. I read the readme for it. It has a pretty robust commandline interface. Now I just have to figure out how to do the same things on the XP machines without having to add them to my domain. I have password protected the built-in local administrator account on those XP machines, but that's not actively logged in on any of those XP machines. Right now they are on my network but not added to the domain that I have the 98 machines on. The just use the network router(NAT) and firewall to access the INTERNET. But for security reasons and to stop all the damn spyware and adware that the users are downloading unknowingly and to be able to implement software restrictions they are going to be added to the domain really soon.

Top
Page 1 of 1 1


Moderator:  Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Arend_, Mart 
Hop to:
Shout Box

Who's Online
0 registered and 145 anonymous users online.
Newest Members
Jodey, Hiker, GTRoberts, KatieQuinn, Brennnnn
17684 Registered Users

Generated in 0.042 seconds in which 0.012 seconds were spent on a total of 12 queries. Zlib compression enabled.

Search the board with:
superb Board Search
or try with google:
Google
Web kixtart.org