MSFN Forum: [Solved] setupcomplete.cmd and java7 - MSFN Forum

Jump to content


Unattended CD/DVD Guide Homepage · MSFN Forum Rules

Welcome to the Applications Installs forum. Make sure you read the forum rules before you start posting.

Links/Requests to warez and/or any illegal material (porn, cracks, serials, etc..) will not be tolerated. Discussion of circumventing WGA/activation/timebombs/keygens or any other illegal activity will also not be tolerated.

We try our best to keep this forum clean of illegal content. If you see any illegal activity use the "report" button you find in every post to report the specific post to the moderators. If you ignore any of the rules you will be banned without notice.

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

[Solved] setupcomplete.cmd and java7 Rate Topic: -----

#1 User is offline   khimtiki 

  • Group: Members
  • Posts: 5
  • Joined: 22-September 12
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 22 September 2012 - 12:12 PM

Hello everybody :)

First of all sorry for my bad english... It's not my native language. Thanks :)

I've done AIO Windows 7 by myself with post-install setupcomplete.cmd script.

Here is my script:

@echo off
setlocal enableextensions disabledelayedexpansion
(set CDROM=)
for %%i in (C D E F G H I J K L M N O P Q R S T U V W X Y Z) do (if exist %%i:\sources\install.wim set "CDROM=%%i:")
if not defined CDROM goto :eof

:: KB2533552
IF NOT EXIST %SystemRoot%\SysWOW64 start /wait wusa.exe %CDROM%\updates\Windows6.1-KB2533552-x86.msu /quiet /norestart
IF EXIST %SystemRoot%\SysWOW64 start /wait wusa.exe %CDROM%\updates\Windows6.1-KB2533552-x64.msu /quiet /norestart

:: http://www.microsoft.com/pl-pl/download/details.aspx?id=16
IF NOT EXIST %SystemRoot%\SysWOW64 start /wait %CDROM%\updates\Windows-KB890830-V4.12.exe /Q
IF EXIST %SystemRoot%\SysWOW64 start /wait %CDROM%\updates\Windows-KB890830-x64-V4.12.exe /Q

:: Windows Defender defs
IF NOT EXIST %SystemRoot%\SysWOW64 start /wait %CDROM%\updates\mpas-fe.exe /Q
IF EXIST %SystemRoot%\SysWOW64 start /wait %CDROM%\updates\mpas-fe-x64.exe /Q

:: DirectX
start /wait %CDROM%\updates\directx\DXSETUP /silent

:: .NET Framework 4.5
start /wait %CDROM%\updates\dotnetfx45_full_x86_x64.exe /q /norestart /ChainingPackage ADMINDEPLOYMENT
start /wait %CDROM%\updates\dotNetFx45LP_Full_x86_x64pl.exe /q /norestart /ChainingPackage ADMINDEPLOYMENT

:: Silverlight
IF NOT EXIST %SystemRoot%\SysWOW64 start /wait %CDROM%\updates\Silverlight.exe /Q
IF EXIST %SystemRoot%\SysWOW64 start /wait %CDROM%\updates\Silverlight_x64.exe /Q

:: Java JRE
IF EXIST %SystemRoot%\SysWOW64 start /wait %CDROM%\updates\jre-7u7-windows-x64.exe /s /v"/qn"
:: timeout /t 10 > nul
start /wait %CDROM%\updates\jre-7u7-windows-i586.exe /s /v"/qn"
:: =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

:: Adobe Flash Player
start /wait %CDROM%\updates\install_flash_player_11_active_x.exe -install
start /wait %CDROM%\updates\install_flash_player_11_plugin.exe -install

:: Ending
:: shutdown /R /T 5
rmdir /s /q "%systemdrive%\Users\Public\Videos"
rmdir /s /q "%systemdrive%\Users\Public\Pictures"
rmdir /s /q "%systemdrive%\Users\Public\Music"
rmdir /s /q "%systemdrive%\Users\Public\Downloads"
rmdir /s /q "%systemdrive%\Users\Public\Documents"
rmdir /s /q "%systemdrive%\Users\Public\Desktop"
rmdir /s /q "%systemdrive%\Users\Public\Libraries"
rmdir /s /q "%systemdrive%\Users\Public\Favorites"
IF EXIST %WinDir%\Setup\scripts RD /S /Q %WinDir%\Setup\scripts >nul
DEL /F /Q %0% >nul



OK, every soft is installing correctly except Java Runtime i586 on brand new x64 system installed. (I'm testing it on Oracle VirtualBox). I underlined failing line above with =-=-=-= signs.
So, if Windows 7 is 64-bit, the setupcomplete.cmd script installs jre-7u7-windows-x64.exe only, but the i586 version setup is omitted :( Strange... I want to install both JRE on 64 bit system...
If I install 32-bit Windows, then the script correctly installs i586 jre version.
I also tried to get more info by adding /L switch to command:

... jre-7u7-windows-x64.exe /s /v"/qn /L C:\javax64.txt"
... jre-7u7-windows-i586.exe /s /v"/qn /L C:\javax86.txt"


In this case, the logfile for 64-bit version is filled with full installer output (15kb file), but the logfile for 32-bit installer is absolutely empty (just file created) :(

I did one more test - commented x64 setup line to pass only 32 bit version - the script did not install it too! :(

What's wrong with it? Could you help me, please...
Thanks!

This post has been edited by khimtiki: 24 September 2012 - 04:41 AM



#2 User is offline   MrJinje 

  • Tool™ Developer
  • Group: Developers
  • Posts: 942
  • Joined: 14-October 09
  • OS:none specified
  • Country: Country Flag

Posted 22 September 2012 - 09:48 PM

What happens when you try to install the i586 manually. Try it without the silent switches (in your VM) and see if any errors pop up.

This post has been edited by MrJinje: 22 September 2012 - 10:00 PM


#3 User is offline   myselfidem 

  • Member
  • PipPipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,380
  • Joined: 06-January 10
  • OS:Windows 7 x86
  • Country: Country Flag

Posted 23 September 2012 - 02:04 AM

Have you tried to install the java version x86 first and after java version x64?

#4 User is offline   khimtiki 

  • Group: Members
  • Posts: 5
  • Joined: 22-September 12
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 23 September 2012 - 05:06 AM

Thank you for answers.
I tried x64 first, I tried x86 first - without result.
When installing "by hand' from %CDROM%\updates folder, jre is installing correctly, I've got both java installed then :)

But, I did another test totay :) I changed script as MrJinje said in this way:

[cutted other stuff]...
IF EXIST %SystemRoot%\SysWOW64 start /wait %CDROM%\updates\jre-7u7-windows-x64.exe /s /v"/qn"
start /wait %CDROM%\updates\jre-7u7-windows-i586.exe
[cutted other stuff]...

to get install wizard on screen.

So there's what I get!

Posted Image

Posted Image

First screenshot - the wizard appears, click "Install" and:
Second screenshot - Boom! Error! It's in polish, but Google translator gives: "Unable to open the installation package. Verify that the package exists and you can access it, or contact the application vendor to verify that this is a valid Windows Installer package."

Why?... x64 wihout error, i586 with such error? The same names, the same location...
Why can I install it by hand after system installation with no problems?... Maybe the new i586 version of 7u7 JRE setup must have any other additional parameters to add in setupcomplete.cmd?

Thanks in advance for any tips :)

#5 User is offline   myselfidem 

  • Member
  • PipPipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,380
  • Joined: 06-January 10
  • OS:Windows 7 x86
  • Country: Country Flag

Posted 23 September 2012 - 05:51 AM

To solve the same trouble, I used this swtiches with SetupComplete.cmd (look at the position quotes):

Example:
REG ADD HKLM\Software\Microsoft\Windows\CurrentVersion\RunOnceEx
SET KEY=HKLM\Software\Microsoft\Windows\CurrentVersion\RunOnceEx

REG ADD %KEY%\030 /V 1 /D "%systemdrive%\Install\Java\jre-7u7-windows-i586.exe /s /v "/qn"" /f


HTH

This post has been edited by myselfidem: 23 September 2012 - 06:08 AM


#6 User is offline   khimtiki 

  • Group: Members
  • Posts: 5
  • Joined: 22-September 12
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 23 September 2012 - 09:17 AM

Thank you myselfidem for this tip.

If I understand, I have to copy setup file before "REG ADD" line to the %systemdrive%\... folder?
Or can I simply use:

REG ADD %KEY%\030 /V 1 /D "%CDROM%\updates\jre-7u7-windows-i586.exe /s /v "/qn"" /f

instead of %systemdrive% ?

I will test it later on :)

#7 User is offline   myselfidem 

  • Member
  • PipPipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,380
  • Joined: 06-January 10
  • OS:Windows 7 x86
  • Country: Country Flag

Posted 23 September 2012 - 09:27 AM

Yes, with my example above, all my programs are copied inside the folder "Install".

But you can try with your method using %CDROM%

start /wait "%CDROM%\updates\jre-7u7-windows-i586-s.exe /s /v "/qn""


And installing first the java x86 version and after java x64 version.

This post has been edited by myselfidem: 23 September 2012 - 09:30 AM


#8 User is offline   khimtiki 

  • Group: Members
  • Posts: 5
  • Joined: 22-September 12
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 23 September 2012 - 11:15 AM

OK, I did 2 tests...

1'st test - change quotes as follows:

start /wait "%CDROM%\updates\jre-7u7-windows-i586.exe /s /v "/qn""

still doesn't install i586... :(

2'nd test - registry key method as follows:

REG ADD HKLM\Software\Microsoft\Windows\CurrentVersion\RunOnceEx
SET KEY=HKLM\Software\Microsoft\Windows\CurrentVersion\RunOnceEx
REG ADD %KEY%\030 /V 1 /D "%CDROM%\updates\jre-7u7-windows-i586.exe /s /v "/qn"" /f

Bingo! That did the trick! Now both versions of JRE is correctly installed on x64 system :)

Thank you VERY VERY much for your help, :thumbup realy appreciated.

One question more, sorry for OT :blushing: Is the installation of JRE on right order important? Some says, install x64 before i586 because some applications may not work correctly... and some says - install i586 before x64... How is it? I'm just curious :rolleyes:

This post has been edited by khimtiki: 23 September 2012 - 12:20 PM


#9 User is offline   myselfidem 

  • Member
  • PipPipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,380
  • Joined: 06-January 10
  • OS:Windows 7 x86
  • Country: Country Flag

Posted 23 September 2012 - 11:38 AM

Thanks! :)

In fact the order seems not to be really important...But if you have trouble install first java x86 version!

Cheers

#10 User is offline   khimtiki 

  • Group: Members
  • Posts: 5
  • Joined: 22-September 12
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 23 September 2012 - 12:23 PM

Ok, thanks for all explanations :)

Request to moderator - we may close this topic with [solved] in subject.

#11 User is offline   MagicAndre1981 

  • after Windows 7 GA still Vista lover :)
  • Group: Patrons
  • Posts: 4,958
  • Joined: 28-August 05
  • OS:Vista Ultimate x86
  • Country: Country Flag

Posted 23 September 2012 - 12:59 PM

View Postkhimtiki, on 23 September 2012 - 12:23 PM, said:

Request to moderator - we may close this topic with [solved] in subject.


you can edit your topic yourself and add this.

#12 User is offline   TheWalrus 

  • N.W.O.
  • PipPipPipPipPip
  • Group: Members
  • Posts: 910
  • Joined: 11-August 08
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 25 September 2012 - 01:18 AM

I just have a question - is it needed to use start /wait in setupcomplete.cmd? I never saw a difference.

#13 User is offline   myselfidem 

  • Member
  • PipPipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,380
  • Joined: 06-January 10
  • OS:Windows 7 x86
  • Country: Country Flag

Posted 25 September 2012 - 04:19 AM

No. You can use cmd /c instead, if you want !

Share this topic:


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

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



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