19 replies
by wancona Accepted solution
by scott_heath Accepted solution
Check out this article:
http://technet2.microsoft.com/WindowsServer/en/library/d911f5f4-7469-4f44-8fde-ff8b1ed87ab61033.mspx?mfr=true
by wancona Accepted solution
by wancona Accepted solution
by scott_heath Accepted solution
by wancona Accepted solution
by scott_heath Accepted solution
The suggestions by Paul and CG IT should do. I was hoping to find a way you could do it without scheduling a script, but oh well.
I would try to build in some logic that verifies the user has actually been logged off. Try it a few times and see how it goes. If you don't need 100% compliance every single night the shutdown command should work fine.
If you need 100% compliance let me know. Maybe we can work up a vbscript that uses WMI to check for logged on users and then only executes if they are logged on, checks to make sure it logged the user off, then takes more drastic measures if it isn't working.
by wancona Accepted solution
by paul.cook Accepted solution
set a scheduled task on the workstations to run "shutdown -l -f -t 30" at a specific time
You can use the AT command to set scheduled tasks on remote computers.
Or create a batch file on the server and run it at 5:30pm or whenever:
shutdown -l -f -t 30 -m \\computer1
shutdown -l -f -t 30 -m \\computer2
....
or even better use the For command in a batch file to run another batch file on a text file list of computers.
complist.txt:
comp1
comp2.domain.com
logoffcomp.cmd:
shutdown -l -f -t 30 -m \\%1
logoffallcomps.cmd (this file is one line)
For /f %%a In (complist.txt) Do Call logoffcomp.cmd %%a
by cg it Accepted solution
that will close all applications, then shutdown the workstations.
there is also a command for providing a net message to users about a forced shutdown.
by wancona Accepted solution
Okay, if that is to shutdown the computers, is there a way to restart instead of shutdown. Because I really only need them to log off of the workstation so that Scheduled tasks can run in the middle of the night. If it shuts down, then it would defeat the purpose of the log off, and I would still have to go around and turn them back on by hand.
Don't want to seem unappreciative, That is very helpful information, but can it be tweaked to restart instead of shutdown, or just straight logg off?
by cmarcus Accepted solution
by rahouseholder Accepted solution
You can do this with the screensaver. You will have to enforce the screensaver through the policy.
Take a look here...
http://support.microsoft.com/kb/314999
by wancona Accepted solution
I've considered that. But the problem arises with the screen saver. If I set it too far off, it will not lock the computer during the working hours when they walk away from their systems. Because we deal with patient information, it has to lock during the day when they are idle, so as not to allow someone to walk up to the workstation and obtain patient information. Yet, if i set the screen saver, it will log them off throughout the day, and they could lose unsaved patient information.
Is there a way to schedule the screensavers to switch to different screensavers at different times? Similar to the way you can program cell phones to be set on a particular ringing theme at certain hours of the day.
by cg it Accepted solution
magic packet... or solar winds makes a whole suite of tools which shuts down and then restarts.
there's many tools on the web...
might ask another question on what are the best freeware or low cost tools for remote/force shutdown and restart.
by wancona Accepted solution
by cg it Accepted solution
Windows Scripting web site.
here's a link:
http://www.microsoft.com/technet/scriptcenter/default.mspx
note: I use the term scripting which to me is the same as making batch files. They are all excutable files.
here's a web site on how to use Windows Batch files [scripts]
by churdoo Accepted solution
by wancona Accepted solution
I was able to create this script which will log off the computer workstation. I tired to post it before for others to use after tweaking it a little bit. But every time I tried, after I submitted it. It said thread unavailable, (on TechRepublics part). So I'll try again.
And thank you for the help.
strComputer = "."
Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root\cimv2")
Set colItems = objWMIService. _
ExecNotificationQuery("Select * From __InstanceDeletionEvent " _
& "Within 1 Where TargetInstance ISA 'Win32_Process'")
Set objWMIService = GetObject("winmgmts:{(Shutdown)}\\" & _
strComputer & "\root\cimv2")
Set colItems = objWMIService.ExecQuery _
("Select * from Win32_OperatingSystem")
For Each objItem in colItems
objItem.Win32Shutdown(0)
Next
This discussion is closed to new replies.
Trending Networks posts
Sort by Trending