[rc5] rc5 nicness

dan carter daniel.carter at stonebow.otago.ac.nz
Fri Oct 10 20:21:33 EDT 1997


Christian Holmqvist wrote:
> 
> At 15:24 1997-10-10 +1300, you wrote:
> Hi!
> 
> >dan carter wrote:
> >If he is running it as an NT service then he can stop start it using the
> >net pause and net resume commands, with a script much the same as that
> >unix one.
> 
> If you  know, can you tell me how this is done?
> I can see it with a mashine that is not on a modem and some one is logged
> in to.
> I can't see it be done on a server where no logged on...
> 
> Well if you know how please tell me...

Tim Lacys' eMail pretty much says it all.

You want to do
NET PAUSE RC5WIN32
wait a min
NET RESUME RC5WIN32
wait a while and do it again

The script is launched at startup and pauses and restarts the service
every while.
I could whip up a script for you in 30secs if you were using OS/2. I
only play with NT a little, and unfortuantly NT doesnt seem to have
anything like syssleep to pause a script.
\*  pause rc5 for GC *\
do forever
	net pause rc5win32
	call syssleep 600
	net resume rc5win32
	call syssleep 3600
end

So without downloading a sleep util what you can do instead is have a
scheduler (such as the AT scheduler bundled with NT) issue the pause and
resume command 

To implement the second approach, insure the at scheduler is loaded as a
service and then type something like:
at \\my_machine 12:00 /every:M,T,W,Th,F,S,Su "cmd /c net pause rc5win32"
at \\my_machine 12:01 /every:M,T,W,Th,F,S,Su "cmd /c net resume
rc5win32"

This will get pretty messy if you want it running every hour, eg.
at \\my_machine 13:00 /every:M,T,W,Th,F,S,Su "cmd /c net pause rc5win32"
at \\my_machine 13:01 /every:M,T,W,Th,F,S,Su "cmd /c net resume
rc5win32"
at \\my_machine 14:00 /every:M,T,W,Th,F,S,Su "cmd /c net pause rc5win32"
at \\my_machine 14:01 /every:M,T,W,Th,F,S,Su "cmd /c net resume
rc5win32"
at \\my_machine 15:00 /every:M,T,W,Th,F,S,Su "cmd /c net pause rc5win32"
at \\my_machine 15:01 /every:M,T,W,Th,F,S,Su "cmd /c net resume
rc5win32"
but then you expect that with NT <G>

Either way it will all run automatically.

Hope this helps

-dan (who should be writing his philosophy essay not reading his email)
----
To unsubscribe, send email to majordomo at llamas.net with 'unsubscribe rc5' in the body.



More information about the rc5 mailing list