• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 909
  • Last Modified:

Execute script after ghost

Hi !

I would like to execute a cmd, vbs, etc... script before the reboot of my computer after the ghost. I boot with WinPE, execute my imaging stuff with ghost32.exe and then i would like to execute a script that copies some files in my fresh ghosted computer before the reboot. Is it possible ?
0
cegepexchange
Asked:
cegepexchange
  • 6
  • 4
  • 3
2 Solutions
 
sg08234Commented:
Can you use a task scheduled on user logout?

Michael
0
 
cegepexchangeAuthor Commented:
can we do that in winpe ? please tell me how !!! :)
0
 
sg08234Commented:
As WinPE is a complete Windows environment the task manger should be available too (I did not check it)
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
bcruse32347Commented:
Are you setting up the ghost imaging process to be scripted or are you calling ghost from the command prompt in WinPE?? or are you using a GUI?

If you are setting it scripted just add the commands to the end of the script. If not create a script and place it in the windows directory of the WinPE image. If you are using a GUI or Desktop in WinPE add an Icon in the GUI or to the WinPE Desktop.

To add stuff into WinPE you can use a tool called GImageX.  If you need more information about editing  WinPE  I can guide you in the right direction.
0
 
cegepexchangeAuthor Commented:
Hi bcruse,

I use pxe + tftp for deploying my winpe image and when the winpe boots, a script called start.bat is executed (with the 'call ghost32.exe') in it. The problem is that I need to start the ghost, wait for it to finish and THEN i would like to execute a command and then reboot. all my scripts are in the winpe image but i need a place to call them.
0
 
sg08234Commented:
Thus the problem is "wait for it to finish"?

If so can't you use start/wait <ghost>?
0
 
bcruse32347Commented:
Yes start/wait is what you want to use in the scripts.... Not just for ghost but for any following command also
0
 
cegepexchangeAuthor Commented:
Ok! Thanks!

If i hit "reboot" in the ghost32.exe, will it execute the next command anyway? Probably not?
0
 
bcruse32347Commented:
No it will reset the computer before the next command executes.
0
 
cegepexchangeAuthor Commented:
Alright thanks! I'll try to check for a scheduled task before the reboot then.
0
 
bcruse32347Commented:
Why not do a start/wait and then have ghost close (not reset). The next command would execute after the image is laid down on the disk. Then you could copy files, add registry entries, change the name, etc...
0
 
cegepexchangeAuthor Commented:
Good idea! Ill try that! thanks!
0
 
cegepexchangeAuthor Commented:
Thanks for all the help, it worked with start /wait until the ghost finish and then i copy my files then reboot. Thanks again!
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

  • 6
  • 4
  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now