MSFN Forum: [Request] Close mshta.exe during installation - MSFN Forum

Jump to content



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

[Request] Close mshta.exe during installation Reduce CPU & installation times in one Rate Topic: -----

#1 User is offline   codejunkie 

  • Member
  • PipPip
  • Group: Members
  • Posts: 172
  • Joined: 23-May 04

  Posted 14 December 2005 - 09:52 PM

Just a suggestion.


Would it be possible to have WPI-W create batch files that add the registry values for RunOnceEx (Application Installer) then mshta.exe doesn’t have to be running in the background watching the registry until it needs to add the next batch of RunOnceEx commands

Here’s what I’d like to see WPI-W create before closing to begin installation
SET KEY=HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceEx\00

REG ADD %RUNONCEEX% /V TITLE /D "Installing Applications" /f

REG ADD %KEY%02 /VE /D "NOD32 AntiVirus v2.50.25" /f
REG ADD %KEY%02 /V 1 /D "%CDROM%\APPS\NOD32\2.50.25\NT\setup.exe /silentmode /settings=%CDROM%\APPS\NOD32\2.50.25\NT\ClientSetup.xml" /f
 /cfg=%CDROM%\APPS\NOD32\2.12.3\ClientConfig.xml

REG ADD %KEY%05 /VE /D "Adobe Reader v7" /f
REG ADD %KEY%05 /V 1 /D "%CDROM%\APPS\Adobe\acroread705.exe" /f

REG ADD %KEY%06 /VE /D "Windows Journal Viewer" /f
REG ADD %KEY%06 /V 1 /D "%CDROM%\APPS\JournalViewer\JournalViewer.exe -y" /f

REG ADD %KEY%16 /VE /D "Firefox v1" /f
REG ADD %KEY%16 /V 1 /D "%CDROM%\APPS\FireFox\Firefox_Setup_v1.0.7.exe -y" /f
REG ADD %KEY%16 /V 2 /D "%CDROM%\APPS\FireFox\plugins.bat" /f

REG ADD %KEY%17 /VE /D "Thunderbird v1" /f
REG ADD %KEY%17 /V 1 /D "%CDROM%\APPS\Thunderbird\Thunderbird_Setup_v1.0.7.exe -y" /f
REG ADD %KEY%17 /V 2 /D "%CDROM%\APPS\Thunderbird\plugins.bat" /f

REG ADD %KEY%19 /VE /D "Daemon Tools v3.47" /f
REG ADD %KEY%19 /V 1 /D "%CDROM%\APPS\DaemonTools\DaemonTool_v3.47.msi /qn REBOOT=Suppress" /f
REG ADD %KEY%19 /V 2 /D "%CDROM%\APPS\DaemonTools\arniWORX_InstallerScript.exe" /f

REG ADD %KEY%22 /VE /D "Java Runtimes" /f
REG ADD %KEY%22 /V 2 /D "%CDROM%\APPS\Runtimes\Java\MSJavaVM_3810.exe" /f
REG ADD %KEY%22 /V 1 /D "%CDROM%\APPS\Runtimes\Java\jre505.exe" /f

REM ---------- Import Next Install Window To Reg --------
REG ADD %KEY%22 /VE /D "Next Install Window" /f
REG ADD %KEY%22 /V 1 /D "%tmp%\page2.bat" /f


This would save on CPU power during the installation... mshta.exe uses 80% of the CPU (Athlon 64 3000+) while installing so the installation takes much longer as there are a lot of SFX on my installation DVD

This post has been edited by codejunkie: 14 December 2005 - 10:17 PM



#2 User is offline   glent 

  • Tpyo Spceialist
  • PipPipPipPipPipPip
  • Group: Members
  • Posts: 1,041
  • Joined: 16-August 04

Posted 15 December 2005 - 03:02 AM

This would be a very nice feature :D mabye we could have wpi.cmd call wpi.hta with a switch to reduce the cpu hogging
tpy start /? in a cmd windows to see what i mean

This post has been edited by glent: 15 December 2005 - 03:15 AM


#3 User is offline   codejunkie 

  • Member
  • PipPip
  • Group: Members
  • Posts: 172
  • Joined: 23-May 04

Posted 15 December 2005 - 11:33 PM

well that got it down from 100% on my P3-933 to 50-60% when set to low


is anyone still working on this project as in updating it with new feature? or just correcting problems with the current version?

I sort of expected kelsenellenelvian to have replied to me request... was on when I posted it reading generate.js, problem with detected path

#4 User is offline   Kelsenellenelvian 

  • WPI Guru
  • Group: Developers
  • Posts: 7,653
  • Joined: 18-September 03
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 15 December 2005 - 11:48 PM

I am still here but as for the killing of mshta during installs that would be nice but the only way I could figure it out would be something like pskill. If I can find another way I would love to do it. As for developement it is still going on just slow as this is the school season and the current version is sooo stable...

#5 User is offline   codejunkie 

  • Member
  • PipPip
  • Group: Members
  • Posts: 172
  • Joined: 23-May 04

Posted 16 December 2005 - 04:51 PM

I will agree with it being stable but there are a few bugs are there not? IE multi-default section


why would you have to use pskill.exe??

Windows includes taskkill.exe
TASKKILL [/S system [/U username [/P [password]]]]
		 { [/FI filter] [/PID processid | /IM imagename] } [/F] [/T]

Description:
	This command line tool can be used to end one or more processes.
	Processes can be killed by the process id or image name.

Parameter List:
	/S	system		   Specifies the remote system to connect to.

	/U	[domain\]user	Specifies the user context under which
						   the command should execute.

	/P	[password]	   Specifies the password for the given
						   user context. Prompts for input if omitted.

	/F					 Specifies to forcefully terminate
						   process(es).

	/FI   filter		   Displays a set of tasks that match a
						   given criteria specified by the filter.

	/PID  process id	   Specifies the PID of the process that
						   has to be terminated.

	/IM   image name	   Specifies the image name of the process
						   that has to be terminated. Wildcard '*'
						   can be used to specify all image names.

	/T					 Tree kill: terminates the specified process
						   and any child processes which were started by it.

	/?					 Displays this help/usage.

Filters:
	Filter Name   Valid Operators		   Valid Value(s)
	-----------   ---------------		   --------------
	STATUS		eq, ne					RUNNING | NOT RESPONDING
	IMAGENAME	 eq, ne					Image name
	PID		   eq, ne, gt, lt, ge, le	PID value
	SESSION	   eq, ne, gt, lt, ge, le	Session number.
	CPUTIME	   eq, ne, gt, lt, ge, le	CPU time in the format
											of hh:mm:ss.
											hh - hours,
											mm - minutes, ss - seconds
	MEMUSAGE	  eq, ne, gt, lt, ge, le	Memory usage in KB
	USERNAME	  eq, ne					User name in [domain\]user
											format
	MODULES	   eq, ne					DLL name
	SERVICES	  eq, ne					Service name
	WINDOWTITLE   eq, ne					Window title

NOTE: Wildcard '*' for the /IM switch is accepted only with filters.

NOTE: Termination of remote processes will always be done forcefully
	  irrespective of whether /F option is specified or not.

Examples:
	TASKKILL /S system /F /IM notepad.exe /T
	TASKKILL /PID 1230 /PID 1241 /PID 1253 /T
	TASKKILL /F /IM notepad.exe /IM mspaint.exe
	TASKKILL /F /FI "PID ge 1000" /FI "WINDOWTITLE ne untitle*"
	TASKKILL /F /FI "USERNAME eq NT AUTHORITY\SYSTEM" /IM notepad.exe
	TASKKILL /S system /U domain\username /FI "USERNAME ne NT*" /IM *
	TASKKILL /S system /U username /P password /FI "IMAGENAME eq note*"



Id love to help but I just don't know JavaScript

#6 User is offline   glent 

  • Tpyo Spceialist
  • PipPipPipPipPipPip
  • Group: Members
  • Posts: 1,041
  • Joined: 16-August 04

Posted 17 December 2005 - 07:41 AM

where are the other developers these days? im sure there was 4 of you guys not long ago

#7 User is offline   Kelsenellenelvian 

  • WPI Guru
  • Group: Developers
  • Posts: 7,653
  • Joined: 18-September 03
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 17 December 2005 - 04:43 PM

They all went to school.

#8 User is offline   WotC 

  • Member
  • PipPip
  • Group: Members
  • Posts: 127
  • Joined: 29-January 05

Posted 23 March 2006 - 12:14 PM

**** - this is really apita. i just switched from wihu to wpi (because the development of wihu was stopped and i like the dependency options...) but the cpu time is really APITA! i mean - most of the time its just... waiting? i have to wait 14 seconds (AMD64 2.1GHz) after pressing the config button :-(. 2 seconds when going back to the install menu... is there REALLY now chance to uhm - somehow "fix" this? is it just adding the registry entry and then - uhm - idling? anyone knows?

#9 User is offline   wixfigura 

  • Junior
  • Pip
  • Group: Members
  • Posts: 65
  • Joined: 27-October 05

Posted 23 March 2006 - 12:40 PM

Hey Boys n Girls!!

Nobody realized that the new wpi.exe ( the autoit file ) in WPI4,4rc1 closes mshta after calling the ktools.exe???

#10 User is offline   WotC 

  • Member
  • PipPip
  • Group: Members
  • Posts: 127
  • Joined: 29-January 05

Posted 23 March 2006 - 12:50 PM

4.4? where did u get it from? am i blind? but thanks for the fast reply!

#11 User is offline   wixfigura 

  • Junior
  • Pip
  • Group: Members
  • Posts: 65
  • Joined: 27-October 05

Posted 23 March 2006 - 12:59 PM

Just look a few topics behind - its a testing version with new setupscreen, but works fine, the only thing is, that working with .msi files isnt worked out ( cause its based on Autoit and this needs a special way to call msi files. Some changes in Config.js and it also works ), heses the link WPI 4,4RC1

good luck - bye

#12 User is offline   WotC 

  • Member
  • PipPip
  • Group: Members
  • Posts: 127
  • Joined: 29-January 05

Posted 23 March 2006 - 01:47 PM

k, thanks - i got it... but it seems the new version makes more troubles than goods! the msi bug hurts... and i fear that fixing here and there makes the whole program more and more unreliable in terms of running on various machines. furthermore im no autoit freak - narf... its really a pain!

maybe there is someone around willing to continue the wihu project... although wpi is quite nice... hah, choices, choices, choices... and lots of waiting :-)

This post has been edited by WotC: 23 March 2006 - 01:58 PM


#13 User is offline   wixfigura 

  • Junior
  • Pip
  • Group: Members
  • Posts: 65
  • Joined: 27-October 05

Posted 23 March 2006 - 06:25 PM

I have no problems with 4,4. Ive made of all my msi files self-exetracting rar-temporary files with the option (maybe): start after extraction blabla.msi /qb /norestart or something like that.
But it also works with the prefix (example): msiexec /i ACDSee7.msi /passive in WPI (i think so). this is the method how to open a msi in autoit.
The other problems are solved now, i think. In my DVD it works perfect.
The closing of mshta is connected with opening the ktools.exe before, so you cannot use WPI.exe in 3.8 or lower. It works like this: In WPI you can choose the files to install, after pushing install WPI tranfers to ktool and WPI doesnt need to run anymore. So WPI.exe closes mshta. In 3,8 or lower mshta is needed til WPI finishes.
So you are right - the ktool method needs not as much system-resources than without. ktool is just a little autoit-script that reads the installation from a txt file.

This post has been edited by wixfigura: 23 March 2006 - 06:31 PM


#14 User is offline   mritter 

  • WPI Co-Developer
  • Group: Developers
  • Posts: 1,088
  • Joined: 13-November 05

Posted 23 March 2006 - 09:22 PM

Am I missing something that you guys aren't? When I watch mshta in the Task Manager while working with WPI, it rarely goes above 15%, usually hangs at 5%, sometimes goes to 23% to 85% when doing a large change, like going to Options. It does use 36MB of RAM, no more than running Explorer for a web site. There is no delay like WotC is having (I also have AMD64). It just reloads the page like hitting refresh in Explorer.



I don't see any difference in using WPI to install everything compared to kTool or RunOnceExe. It is not the program slowing the computer, it is the program being installed. Once the install process is started, the GUI of WPI is idle, 5% CPU.



I somewhat like the idea of mshta closing so the desktop could come up and you could do some work. But your computer is still slow due to the programs being installed. I could just be used to having a fast AMD64 and don't really notice the time for installs. And I do walk away and go about my business on other computers, so I don't really need to do background work.

#15 User is offline   WotC 

  • Member
  • PipPip
  • Group: Members
  • Posts: 127
  • Joined: 29-January 05

Posted 24 March 2006 - 09:51 AM

hmmm, i'll check this during an install. i had the feeling that installation took MUCH longer than when using wihu (with more or less the same programs being installed). when just in "select" mode i also have about 5% cpu usage. however, sa soon as i am in config mode thats 80%. i'll check the % when installing (as soon as i have something to install :-)).

how many apps do u have in ur config file? i have about 120 or so - the loading time increases dramatically with the # of apps

#16 User is offline   mritter 

  • WPI Co-Developer
  • Group: Developers
  • Posts: 1,088
  • Joined: 13-November 05

Posted 24 March 2006 - 10:04 AM

OK, yes, with 120 apps it will take longer to render the config window. That is something I have been thinking about in the back of my mind. I have a general idea on how to "fix it".
What WPI is doing is doing a for(...) loop and creating a <form> for each entry, which is 205 lines long. So 120x205=24600 lines of code.
I only have like 30 apps, so mine does render fairly quick.

#17 User is offline   lawrenca 

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

Posted 25 March 2006 - 07:53 AM

All,
I see about 28% CPU useage on a fresh install of Windows XP with SP2 on a CF-51 Panasonic Toughbook (2GHz Pentium-M Processor and 2GB RAM) just while mshta.exe sits idle (using WPI 4.3.8)...with a mouse over showing tooltip, this jumps in the range of 50-80% depending on the size of the tip.

Beyond that, I still am getting the Slow Scripting errors on some more challenged machines (I still have about 140 systems fielded that run on 700MHz Processors and 256MB-512MB RAM...really notice the difference there!

On the other end, my Dell WS370 and WS380 systems don't have a problem at all and I see numbers very similar to what mritter references.

We definately owe Kel more specs on performance issues (with numbers attached) for actual install performance hits (audio vs. no audio, RunOnceEx vs. File or Memory Install, self-extracting exe vs. uncompressed installs, etc.).

BTW, my config.js has just under 100 apps. Will double that when I add the lines to launch exe for modification, repair, or re-install (not silent).

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