Solved

Force logoff after certain hours through group policy

Posted on 2009-07-03
2
472 Views
Last Modified: 2012-05-07
Hi,

Is there a way through group policy to add a scheduled task that forces users to logoff at a certain time each night? I was able to create a .cmd script and put that in group policy. It is in the code section of this question. It didn't work. In event viewer there is an error that reads: The At2.job command failed to start due to the following error:
The system cannot find the file specified.

Any ideas?
at 22:00 /EVERY:M,T,W,Th,F,S,Su "shutdown -r -f -t 60 -c "Please close all programs - this PC will now restart"

Open in new window

0
Comment
Question by:trent_shane
2 Comments
 
LVL 30

Accepted Solution

by:
Britt Thompson earned 250 total points
ID: 24772668
set the group policy: Network security: Force logoff when logon hours expire under Computer Configuration\Windows Settings\Security Settings\Local Policies\Security Options\

Then, in AD user properties goto Account >> Logon Hours and set the time the user is allowed to be logged in...

GPUPDATE /force afterwards and you should be all set.
0

Featured Post

Webinar: Aligning, Automating, Winning

Join Dan Russo, Senior Manager of Operations Intelligence, for an in-depth discussion on how Dealertrack, leading provider of integrated digital solutions for the automotive industry, transformed their DevOps processes to increase collaboration and move with greater velocity.

Question has a verified solution.

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

This article describes how to set permissions to allow a limited-permissions user to start and stop a particular System Service.   It is always best to give users only the permissions that they need to perform their job, so tweaking particular permi…
It’s been over a month into 2017, and there is already a sophisticated Gmail phishing email making it rounds. New techniques and tactics, have given hackers a way to authentically impersonate your contacts.How it Works The attack works by targeti…
In this video, we discuss why the need for additional vertical screen space has become more important in recent years, namely, due to the transition in the marketplace of 4x3 computer screens to 16x9 and 16x10 screens (so-called widescreen format). …
Windows 8 came with a dramatically different user interface known as Metro. Notably missing from that interface was a Start button and Start Menu. Microsoft responded to negative user feedback of the Metro interface, bringing back the Start button a…

730 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