PC Review


Reply
Thread Tools Rate Thread

GPO Scripts Startup/Shutdown

 
 
2006Dave2007
Guest
Posts: n/a
 
      20th Jan 2009
We have created a script that basically cleans/defrags the PC and placed it
in the shutdown scripts in our OU GPO.

However, this scripts runs on restarts and shutdowns. Is there any way to
have this script run only when a user specifies shutdown? Sometimes during
the day, people for various reasons restart their pc...this script takes a
long time, thus causing frustration...

Thanks
 
Reply With Quote
 
 
 
 
Florian Frommherz [MVP]
Guest
Posts: n/a
 
      20th Jan 2009
Howdie!

2006Dave2007 wrote:
> We have created a script that basically cleans/defrags the PC and placed it
> in the shutdown scripts in our OU GPO.
>
> However, this scripts runs on restarts and shutdowns. Is there any way to
> have this script run only when a user specifies shutdown? Sometimes during
> the day, people for various reasons restart their pc...this script takes a
> long time, thus causing frustration...


You would have to query Windows' state and the kind of shutdown it
undertakes in the script. That's the kind of approach you need to take.
You won't be able to tweak that in GP really. Not sure if you can do
that with Batch either.

An alternative would be looking at the time during script execution. If
it's after 3pm, execute the defrag things - if it's prior to 3pm, the
user most likely wants to just reboot.

cheers,

Florian
--
Microsoft MVP - Group Policy
eMail: prename [at] frickelsoft [dot] net.
blog: http://www.frickelsoft.net/blog.
Maillist (german): http://frickelsoft.net/cms/index.php?page=mailingliste
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: For a website, are Excel scripts better than other programming language scripts? Tim Williams Microsoft Excel Programming 10 31st May 2009 05:11 AM
GP Logon Scripts vs Legacy Logon Scripts? Gerry Hickman Microsoft Windows 2000 Group Policy 0 10th Jul 2006 09:41 PM
logon scripts :- i can't seem to be able to define logon scripts =?Utf-8?B?bWljaGFlbC5u?= Windows XP Security 1 23rd Mar 2005 02:53 PM
Prevent changes made by VBA scripts from triggering "ON CHANGE" scripts E. Jordan Microsoft Access VBA Modules 1 29th Oct 2003 08:25 PM
can't view scripts (i.e. credit card scripts, javascripts, etc.) Mikey Windows XP Internet Explorer 1 15th Aug 2003 12:54 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 09:11 PM.