Page 1 of 1 1
Topic Options
#189670 - 2008-09-15 06:35 PM Logon Script Running exe
D3V1Li5H Offline
Just in Town

Registered: 2008-09-15
Posts: 1
Hi All,

We have quite a big KIX logon script being run for our users as part of group policy. I have been trying to get it to run an exe using the "Run" command which will execute our PC auditing software. When the exe is run, it sits in memory for 10mins before it begins to audit the machine.

What appears to be happening at logon is that the kix script runs and executes the auditing .exe fine, and continues through the rest of the script., but when it completes it closes and then shortly afterwards the audit .exe terminates also before it has ran the audit.

Running the same script manually after logon runs and executes perfectly, i.e. the kix script terminates but the audit exe continues to stay in memory and runs its audit.

Has anyone come across this before? Is it to do with some type of difference with the run environment when running through Group Policy or at logon? Any help would be greatly appreciated.

Thanks in advance,
Jay

Top
#189672 - 2008-09-15 07:16 PM Re: Logon Script Running exe [Re: D3V1Li5H]
NTDOC Administrator Offline
Administrator
*****

Registered: 2000-07-28
Posts: 11623
Loc: CA
Can we see some code for this please.

Also not sure if it applies but as I recall the startup script has a 10 minute completion period, meaning that if what you're trying to do is not done then it will quit on it's own. I'd have to locate that exact setting but I think it was even posted here a while ago.

Top
#189680 - 2008-09-15 10:49 PM Re: Logon Script Running exe [Re: NTDOC]
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22346
Loc: OK
 Quote:

Maximum wait time for Group Policy scripts

Computer Configuration\Administrative Templates\System\Logon

This policy setting allows you to change the default script timeout period. (By default, scripts time out after 600 seconds). The range is 0 sconds to 32000 seconds.
_________________________
!

download KiXnet

Top
#189688 - 2008-09-16 12:10 PM Re: Logon Script Running exe [Re: Lonkero]
BradV Online   content
Seasoned Scripter
****

Registered: 2006-08-16
Posts: 686
Loc: Maryland, USA
Instead of putting this in a login script, wouldn't it make more sense to make two GPOs? One, a system startup script simply checks if the audit software is installed on the system. If not, it installs it. A second GPO would tell each system to run the audit at some certain time during the day.
Top
#189690 - 2008-09-16 01:20 PM Re: Logon Script Running exe [Re: BradV]
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22346
Loc: OK
hmm... scheduled programs have the problem of needing the system be up and running at that very moment.
for my programs I've used simple run-key approach for laptops and such.
_________________________
!

download KiXnet

Top
#189693 - 2008-09-16 01:41 PM Re: Logon Script Running exe [Re: BradV]
Glenn Barnas Administrator Offline
KiX Supporter
*****

Registered: 2003-01-28
Posts: 4396
Loc: New Jersey
Brad's pretty much on target, but with a scheduled task.. You can control what runs, the account used to run the task, and when it will run. WHEN is the real issue, so rather than taking a chance that the system is up at a certain time, create an AT STARTUP task. Task events can even be configured to run at low priority, and delete themselves when done.

I'd script in a 3-5 minute delay when the script launches, since there are lots of things going on at system startup that compete for processor resources. AT STARTUP runs tasks after the system is initialized, but at the same time that the Run and RunOnce reg keys are processed, so a short delay would make the system appear more responsive, minimizing user complaints about slowness.

Run and RunOnce reg keys are OK if the task should/can run in the user's security context. You have less control over how the task runs than through the scheduler. BTW - Win2K8 makes heavy use of the AT STARTUP capability in the scheduler.

Glenn
_________________________
Actually I am a Rocket Scientist! \:D

Top
Page 1 of 1 1


Moderator:  Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Arend_, Mart 
Hop to:
Shout Box

Who's Online
1 registered (Allen) and 382 anonymous users online.
Newest Members
gespanntleuchten, DaveatAdvanced, Paulo_Alves, UsTaaa, xxJJxx
17864 Registered Users

Generated in 0.057 seconds in which 0.024 seconds were spent on a total of 13 queries. Zlib compression enabled.

Search the board with:
superb Board Search
or try with google:
Google
Web kixtart.org