1.How can i run a Batch file so that it would ping the service in remote machine every hour and if the service is down it would automatically restart the service.Both machines OS is windows XP. 2. Is there any way where i can run the batch file in linux for the same purpose. Please guide me as am not sure where to start. would really appreciate your help.
Which service do you want to monitor?
Something like this should get you going:
There's also this:
Use scheduled tasks to run it on whichever XP machine you want. IF you need one machine to monitor the other you can use PSEXEC from the PSTools pack.
Actually, scratch that, PSTools has a PSService command that might be better than hacking together something with PSEXEC and SC.
I don't know how easy it would be to do from a linux machine but I suspect not very..