MSFN Forum: Reboot then RunOnceEX - MSFN Forum

Jump to content



Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Reboot then RunOnceEX Having trouble getting an additional application to run after reboot Rate Topic: -----

#1 User is offline   imthemp3king 

  • Newbie
  • Group: Members
  • Posts: 41
  • Joined: 30-March 04

Posted 15 March 2006 - 02:23 PM

Hello,

I am trying to install GFI LanGuard Network Security Scanner via WPI. I had to repackage the installer because I couldn't get it to go silently and didn't want to use autoit. It installs fine, except that it needs a reboot to create a service. I have a .cmd file that accomplishes this via RunOnceEx. See below.
Followup.cmd
cmdow @ /HID
@echo off

IF EXIST D:\autorun.inf set CDROM=D:
IF EXIST E:\autorun.inf set CDROM=E:
IF EXIST F:\autorun.inf set CDROM=F:
IF EXIST G:\autorun.inf set CDROM=G:
IF EXIST H:\autorun.inf set CDROM=H:
IF EXIST I:\autorun.inf set CDROM=I:
IF EXIST J:\autorun.inf set CDROM=J:

SET KEY=HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceEx

REG ADD %KEY%\001 /V 1 /D "%CDROM%\postinstall\Security\GFI\postinstall.cmd" /f

shutdown -r -f -t 0


Postinstall.cmd
cmdow @ /HID
@echo off

net user LNSS_MONITOR_USR password
sc config "GFI LANguard N.S.S. 7.0 Attendant Service" password= password


If I test this install all by itself on a fresh Windows install, it works just fine after reboot. But I am trying to have this happen through WPI and I have it set as a dependancy of the GFI application and have the install order set to 9999 so it the last thing in RunOnceEx. Postinstall.cmd gets added to RunOnceEX but it gets executed before the reboot. I thought that setting the shutdown command to happen immediately would prevent that, but it just doesn't seem to work the way I want it to. Can anyone give me any tips on how I can get this working.

Thanks.

This post has been edited by imthemp3king: 17 March 2006 - 08:07 AM



#2 User is offline   lawrenca 

  • Broken by Design
  • PipPip
  • Group: Members
  • Posts: 129
  • Joined: 01-April 04

Posted 25 March 2006 - 10:05 PM

imthemp3king,
Not sure if you were in on the WPI4.4rc1 testing, but made some enhancements to my WPI to include RebootFlag and Reboot capability. This version is definately not the release version of any kind as mritter and Kel have been working on a very nice solution for RC2.

The RebootFlag checkbox will flag for reboot then after all the WPI Applications get installed, it will reboot your system.

The Reboot checkbox will reboot your system after executing the last command of the current application, then pick up where it left off installing the rest of the apps when your system comes back up.

These 2 functions are found as checkboxes under the Config Page of WPI.

Be sure to make backup copies of your files as the code within my version will modify your config.js...it is not backwards compatible (at least I don't think).

The download can be found at this post:

Post of Potential Solution

#3 User is offline   imthemp3king 

  • Newbie
  • Group: Members
  • Posts: 41
  • Joined: 30-March 04

Posted 30 March 2006 - 07:45 AM

Thanks for the reply, I was able to resolve my issue without the use of a reboot. The service wasn't neccessary for proper program execution but more of a convenience feature so I just told the installer not to start it.

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users



All trademarks mentioned on this page are the property of their respective owners
Copyright © 2001 - 2011 msfn.org
Privacy Policy