[gptalk] Re: Set application to run at login via scheduled task

  • From: "Darren Mar-Elia" <darren@xxxxxxxxxx>
  • To: <gptalk@xxxxxxxxxxxxx>
  • Date: Wed, 2 Jul 2008 13:46:34 -0700

Also keep in mind that some processes are not happy if you try to start them
during that nether-time that is logon script execution. Sometimes logon
scripts run before the user environment is fully baked, which means the
process may actually fail to start.

There's always using the Scheduled Tasks feature of GP Preferences. You
don't need Win2008 to implement it. Just one little old Vista, SP1 box to
administer the settings.

Darren

-----Original Message-----
From: gptalk-bounce@xxxxxxxxxxxxx [mailto:gptalk-bounce@xxxxxxxxxxxxx] On
Behalf Of Nelson, Jamie
Sent: Wednesday, July 02, 2008 11:56 AM
To: gptalk@xxxxxxxxxxxxx
Subject: [gptalk] Re: Set application to run at login via scheduled task

Well running it as a logon script won't necessarily hold up the logon
process unless the script is written so that it waits for termination of
the child process.

Don't know how well-versed you are in VBScript, but if you did something
like this it wouldn't be any different than running it as a scheduled
task.

'// Code Start
'--------------------

Dim objShell : Set objShell = WScript.CreateObject("WScript.Shell")
Dim strCmd : strCmd =
objShell.ExpandEnvironmentStrings("%ProgramFiles%\Program\Program.exe")

'Enclose the command to be executed in double quotes to account for
spaces
strCmd = Chr(34) & strCmd & Chr(34)

objShell.Run strCmd, 0, False

Set objShell = Nothing

'--------------------
'// Code End

The "False" argument in the objShell.Run command is telling the script
that it doesn't need to wait for the command to finish before
continuing. This is the default behavior if you don't pass that
argument. Sometimes you want it to be "True" to capture the error code
after the process runs, but in your case you shouldn't care.

Regards,

Jamie Nelson | Infrastructure Consultant | BI&T Operations | Devon
Energy | Work: 405.552.8054 | http://www.dvn.com


-----Original Message-----
From: gptalk-bounce@xxxxxxxxxxxxx [mailto:gptalk-bounce@xxxxxxxxxxxxx]
On Behalf Of WATSON, BEN
Sent: Wednesday, July 02, 2008 1:37 PM
To: gptalk@xxxxxxxxxxxxx
Subject: [gptalk] Set application to run at login via scheduled task

As part of a push to improve security with our laptop users, we are
testing a deployment of EFS Assistant.  This application encrypts
various locations of a user's hard drive and profile and is configured
via group policy.

I already have the policy set via group policy, and a WMI filter set so
only laptop users will be able to read and apply the policy.

The problem I am having now is that the application should be run every
time a user logs in.

I think it would be best if I could configure the application to run at
user login via scheduled tasks, but I don't believe that's possible.
Maybe someone could correct me on that one?

I could add the application as a logon or logoff script, but according
to the documentation, that is not recommended as the encryption process
could take a considerable amount of time depending on the amount of data
the user stores locally.

We are running a Windows 2003 R2 domain.  So any new group policy
functionality from a Windows 2008 domain is not an option.

Thanks,
~Ben
 
***********************
You can unsubscribe from gptalk by sending email to
gptalk-request@xxxxxxxxxxxxx with 'unsubscribe' in the Subject field OR
by logging into the freelists.org Web interface. Archives for the list
are available at //www.freelists.org/archives/gptalk/
************************
Confidentiality Warning: This message and any attachments are intended only
for the use of the intended recipient(s), are confidential, and may be
privileged. 
If you are not the intended recipient, you are hereby notified that any
review, retransmission, conversion to hard copy, copying, circulation or
other use of all or any portion of this message and any attachments is
strictly prohibited. If you are not the intended recipient, please notify
the sender immediately by return e-mail, and delete this message and any
attachments from your system. 
***********************
You can unsubscribe from gptalk by sending email to
gptalk-request@xxxxxxxxxxxxx with 'unsubscribe' in the Subject field OR by
logging into the freelists.org Web interface. Archives for the list are
available at //www.freelists.org/archives/gptalk/
************************

***********************
You can unsubscribe from gptalk by sending email to 
gptalk-request@xxxxxxxxxxxxx with 'unsubscribe' in the Subject field OR by 
logging into the freelists.org Web interface. Archives for the list are 
available at //www.freelists.org/archives/gptalk/
************************

Other related posts: