/build/static/layout/Breadcrumb_cap_w.png

Oracle Java Runtime Environment

Don't be a Stranger!

Sign up today to participate, stay informed, earn points and establish a reputation for yourself!

Sign up! or login
Views: 21.7k  |  Created: 10/01/2007

Average Rating: 0
Java Runtime Environment has 1 inventory records, 72 Questions, 8 Blogs and 20 links. Please help add to this by sharing more!

Deployment Tips (42)

Most Common Setup Type
Not Determined
Average Package Difficulty Rating
Rated 2 / 5 (Somewhat Easy) based on 4 ratings
Most Commonly Reported Deployment Method
Windows Installer with Custom Transform (MST)
130
Command Line
After downloading the offline installation from http://java.sun.com/javase/downloads/index.jsp

Silent install with autoupdates disabled:
jre-6u1-windows-i586-p.exe /s AgreeToLicense=YES IEXPLORER=1 MOZILLA=1 REBOOT=Suppress JAVAUPDATE=0
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
126
Command Line

jre-6-windows-i586.exe /s IEXPLORER=1 MOZILLA=1 REBOOT=Suppress

Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
123
Note
Hi

I found a way to disable the Updater!

Using Wise Packet Studio i made a MST, contaning following REG-File (deploy in Windows directory):


Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Update\Policy]
"EnableJavaUpdate"=dword:00000000
"NotifyDownload"=dword:00000001
"NotifyInstall"=dword:00000000
"VisitorId"="3fb2c346-9331a7da4"
"UpdateSchedule"=dword:00000000
"Frequency"=dword:00000001



With Wise i made a custom action (Execute program from destination), to import the REG durring "InstallFinalize"

Regedit.exe -s c:\windows\[your-REG].reg
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
121
Security

I was able to stop the Automatic Updates from occuring by setting a Software Restriction Policy using Group Policy. I blocked the JUSCHED.EXE and JUCHECK.EXE files from running. When doing a manual check, a couple of errors are logged in the Application log, but the user sees nothing. Should work the same for a scheduled check.

Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
121
Note
IMPORTANT CORRECTION of my above posting.

I'm sorry I have to admit, I was wrong with my proposal to leave the "IEXPLORER" property untouched. Though Sun's Javatest webpage shows correct information about the Java install, other applets might not run! So you DO have to set "IEXPLORER" to "1".

I did not see any side effects. Maybe my former findings were related to setting the "EULA" value. But as everything runs fine now, I did not check that one.
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
120
Note
Thanks you everyone for the entries and switches. I borrowed from everyone notes to develop one that I think works with no errors..

1st I extraced the msi package from exe for the Jre you might have to do a search for it on your machine.. just do *.msi you will find it. It was placed on temp directory so I had to do some hunting..

2nd. what switches do you want to turn off.. for our environment...

We wanted to disable javaupdate and notifyinstall and the update schedule..

If you try to put the switches when the software is being installed they won't change from 0 to 1.. In the same batch file added the registry hacks to change the 0 to turn off the updates.. good luck..

:install
msiexec.exe /i "\\JRE-610u\jrse16.msi"
/quiet /passive /norestart ADDLOCAL=ALL IEXPLORER=1 REBOOT=Suppress

:Configure Plug-In
reg add "HKLM\SOFTWARE\Javasoft\Java Plug-in\1.6.0_03" /v HideSystemTrayIcon /t reg_dword /d 0 /f

:Disable Updates
reg add "HKLM\SOFTWARE\Javasoft\Java Update\Policy" /v EnableJavaUpdate /t reg_dword /d 0 /f
:reg add "HKLM\SOFTWARE\Javasoft\Java Update\Policy" /v Frequency /t reg_dword /d 0 /f
reg add "HKLM\SOFTWARE\Javasoft\Java Update\Policy" /v NotifyDownload /t reg_dword /d 0 /f
reg add "HKLM\SOFTWARE\Javasoft\Java Update\Policy" /v NotifyInstall /t reg_dword /d 0 /f
:reg add "HKLM\SOFTWARE\Javasoft\Java Update\Policy" /v UpdateSchedule /t reg_dword /d 0 /f

:Delete from Run Key
reg delete "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Run" /v SunJavaUpdateSched /f
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
119
Command Line
For Java Runtime, I was finding my users contacting me saying 'shall I install the update?'. So in this configuration I have removed the update function, leaving it to me to test and deploy it in my own time (and saving some bandwidth from the Internet). :-

\\servername\volname\foldername\jre\jre-6u3-windows-i586-p-s.exe /s /v"/qn ADDLOCAL=ALL IEXPLORER=1 REBOOT=Suppress JAVAUPDATE=0 /L c:\ins\jre6u3.txt"

rem : Disable Update
rem REG ADD "HKLM\SOFTWARE\JavaSoft\Java Update\Policy" /v EnableJavaUpdate /t REG_DWORD /d 0 /f
rem REG ADD "HKLM\SOFTWARE\JavaSoft\Java Update\Policy" /v EnableAutoUpdateCheck /t REG_DWORD /d 0 /f
rem REG ADD "HKLM\SOFTWARE\JavaSoft\Java Update\Policy" /v NotifyDownload /t REG_DWORD /d 0 /f
rem REG ADD "HKLM\SOFTWARE\JavaSoft\Java Update\Policy" /v NotifyInstall /t REG_DWORD /d 0 /f
rem REG DELETE "HKLM\SOFTWARE\JavaSoft\Java Update\Policy" /v PromptAutoUpdateCheck /f


- Note: Remove the 'rem' from each line to use the commands. Always be careful when making changes to the registry.
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
118
Note

As of 4-18-07: Downloading from "jre-6u1-windows-i586-p-s.exe" http://www.java.com/en/download/manual.jsp does not work. The installer is apparently missing its transform. Download from http://java.sun.com/javase/downloads/index.jsp instead. This package is not distributed with the silencer.

Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
118
Note
I found this info how to get a msi file on http://openofficetechnology.com/book/export/html/23
Alex

Run the JRE installation executable file, jre-6u1-windows-i586-p.exe. The License Agreement screen will appear. Do not click either "Decline" or "Accept".
The installer executable will have placed a file called "jre1.6.0_01.msi" into the directory "C:\Documents and Settings\<your username>\Application Data\Sun\Java\jre1.6.0_01". Copy the .msi file to a network installation point, which is a location on the network accessible to the client computers, such as

\\fileserver\net_install_images\jre1.6.0_01
Note 1: Earlier versions of JRE installation executable placed the .msi file into a subdirectory such as "C:\Documents and Settings\<your username>\Local Settings\Application Data\{XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX}", where the name of the subdirectory depends on the JRE version. The .msi file corresponding to the JRE version can be located by looking in all subdirectories with names matching this pattern.
Note 2: Neither the Java installer executable nor the .msi file support the “/a” administrative installation option.
Returning to the License Agreement screen, click "Decline". The installer will delete the Application Data\Sun\Java directory and its .msi file, then terminate.
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
118
Note
I used the following to install silently and prevent autoupdates thereafter:

jre-1_5_0_11-windows-i586-p.exe /s AgreeToLicense=YES ADDLOCAL=ALL IEXPLORER=1 MOZILLA=1 REBOOT=RS WEBSTARTICON=0 JAVAUPDATE=1 JU=1 SYSTRAY=0 /l*v \"%TEMP%\jre1.5.0.11.msi.log\"

Notice no more /V" switches

As for the updates, the results were not consistent:

-The registry values set would sometimes conflict with what the Java CPL applet would say.

-JAVAUPDATE=1 seemed to control the Update tab in the Java CPL applet.

-JU did nothing I could tell

-None of these switches will remove (uninstall) previous versions of Java, they just accumulate in ARP and program files!

-Sun does not document any of the JAVAUPDATE/AUTOUPDATECHECK/JU properties. With the disconnect between the registry setting and the Java CPL applet that I have witnessed, I would say these properties are for our frustration only. The true settings are probably buried inside some binary file.

Remember: Java is cross-platform and only Windows has a registry. It makes sense for Sun not care too much how good the registry controls Java updates compared to how well some other "secret" file used in all versions of Java VM (not just windows).

My solution to preventing the Java autoupdates regardless of
what's already on the PC:

Windows Registry Editor Version 5.00
;forcefully disable AutoUpdates
[HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Update\Policy]
"EnableJavaUpdate"=dword:00000000
"EnableAutoUpdateCheck"=dword:00000000
"UpdateSchedule"=dword:00000000
"Frequency"=dword:01190000

;Kill Java Update scheduler
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run]
"SunJavaUpdateSched"=-
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
118
Note
Run setup just like mentioned before and stop at the moment you need to agree to the EULA! Go to your profile's temp directory. If it is has files in it, delete them before you start the setup. When the Java setup starts a file with a variable name (and a .msi extension) is created in this folder. Copy that out to a location of your choice.

Stop the install of JRE.

Use ORCA to open the copied .msi. Rename it if you like and look for the following entry:

On the left side table-property on the right side "javaupdate" equals 1. Change the value of 1 to 0 and save the .msi.

Place the .msi in a share which you use for distribution of software and add an entry to GPO. I have done this in the computer part of the GPO or else it may fail.
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
118
Note
I found this info how to get a msi file on http://openofficetechnology.com/book/export/html/23
Alex

Run the JRE installation executable file, jre-6u1-windows-i586-p.exe. The License Agreement screen will appear. Do not click either "Decline" or "Accept".
The installer executable will have placed a file called "jre1.6.0_01.msi" into the directory "C:\Documents and Settings\<your username>\Application Data\Sun\Java\jre1.6.0_01". Copy the .msi file to a network installation point, which is a location on the network accessible to the client computers, such as

\\fileserver\net_install_images\jre1.6.0_01
Note 1: Earlier versions of JRE installation executable placed the .msi file into a subdirectory such as "C:\Documents and Settings\<your username>\Local Settings\Application Data\{XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX}", where the name of the subdirectory depends on the JRE version. The .msi file corresponding to the JRE version can be located by looking in all subdirectories with names matching this pattern.
Note 2: Neither the Java installer executable nor the .msi file support the “/a” administrative installation option.
Returning to the License Agreement screen, click "Decline". The installer will delete the Application Data\Sun\Java directory and its .msi file, then terminate.
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
117
Command Line
This is the script I use for deploying java runtime. Tested and verified to work on WinXP SP2 and WinXP SP2 x64.

Copy and paste the bit between the "---" into a cmd-file. Add this file to a GPO and deploy over AD.

I've had some problems with the script installing the jre over and over again. The first condition test (if there is a folder called "jre1.6.0_01" in %programfiles%\java solves this issue, and will quietly exit if it's already installed.

"JAVAUPDATE=1" on the install line isn't really needed. I just add it to make sure the reg-keys are made. After install I set the changes I want dor autoupdate etc.

Usually I use the autoupdate on my admin-machine to see when there's a new release. for the other user-machines this check is off.

You can change the reg-settings as necessary.


---
if exist "%programfiles%\Java\jre1.6.0_01" goto end else install

:install
"\\domain.local\dfs\MSI\Sun Java v1.6.0 Update 1\jre-6u1-windows-i586-p.exe" /quiet /passive /norestart ADDLOCAL=ALL IEXPLORER=1 REBOOT=Suppress JAVAUPDATE=1

:end
:: Configure Plugin
REG ADD "HKLM\SOFTWARE\JavaSoft\Java Plug-in\1.6.0_01" /v HideSystemTrayIcon /t REG_DWORD /d 0 /f

:: Disable Update
REG ADD "HKLM\SOFTWARE\JavaSoft\Java Update\Policy" /v EnableJavaUpdate /t REG_DWORD /d 1 /f
REG ADD "HKLM\SOFTWARE\JavaSoft\Java Update\Policy" /v EnableAutoUpdateCheck /t REG_DWORD /d 1 /f
REG ADD "HKLM\SOFTWARE\JavaSoft\Java Update\Policy" /v NotifyDownload /t REG_DWORD /d 1 /f
REG ADD "HKLM\SOFTWARE\JavaSoft\Java Update\Policy" /v NotifyInstall /t REG_DWORD /d 1 /f
rem REG DELETE "HKLM\SOFTWARE\JavaSoft\Java Update\Policy" /v PromptAutoUpdateCheck /f
---

HTH.
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
115
Command Line
msiexec /i jre1.6.0.msi /qn

this will show no gui at all but avoid the 1606 error which you will get if you're using /qb!.

uninstalling using /qb! works fine.
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
114
Command Line

Additional command line reference

Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
  • Can this link be updated please? :D - ashlea 12 years ago
21
Note
(This issue is now fixed in Java 6 Update 12 and beyond - see below)

BEWARE - The MSI packages for Java 6 Update 10 and Java 6 Update 11 are BROKEN and will hang if you attempt to upgrade, remove or redeploy them once they are installed via Group Policy Software Installation.

This is an issue with the installation logic and the new Java Quick Starter Service (jqs.exe), in that the installer will present a dialog asking for this process to be closed, which is invisible during Group Policy Software Installation.

If you have already deployed these packages, you can work around this by disabling the JavaQuickStarterService inside Group Policy when deploying the software.

See the following Sun forum post for more information and discussion:
http://forums.sun.com/thread.jspa?threadID=5341011

EDIT 20/3/09 - This issue has been resolved since Java 6 Update 12, as has the issue with /qb mentioned by Lamarth above - see Java Bug ID 6782024 and Java Bug ID 6764967.
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
13
Note
Anybody not confused about all these various proposals? Let me contribute ;-) I'll keep it simple.

So this is what I found out distributing version 1.6.0_04 (6u4 or 6 update 4) with GPO.

There's three things I wanted to accomplish:
- disable automatic updating
- hide the update tab for standard users (for admins you cannot hide it anyway)
- stop the tray icon from showing up when visiting a website containing Java applets

To achieve this
- Open the extracted jre1.6.0_nn.msi in Microsoft's Orca.
- Go to the properties table.
- Change the value "SYSTRAY" to "0", this hides the tray icon.
- Change the value "JU" to "0", this hides the update tab.
- Change the value "AUTOUPDATECHECK" to "0", this disables the automatic updating. In fact it merely prevents the scheduler-entry to be written to the HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Run registrykey. If you open the java control panel applet and look at the update tab it will look as if automatic updates were enabled - don't care! There is no need to change the "JAVAUPDATE" property (in fact I did not see any effect setting it to "0").
- Generate a transform to hold these changes. Do NOT save any changes to the .MSI. This way you will be able to reuse the transform file for future versions of the JRE. Also you might modify the transform while your GPO is and stays in effect (do not forget to redeploy in this case).
- In your GPO create a new policy to install the .MSI modified by the transform.
- If you have a previous version installed by GPO tell the new policy to update the old version by uninstalling it. Do not select "overwrite", because then you might end up with both versions installed on your clients.

You may find clients where the uninstall of a previous version resulted in an ERROR so the new version will not be installed. Most likely you will solve the problem by manually reinstalling the old version and then reboot. Do not manually uninstall the reinstalled version!

So why did I not change the "EULA" property? Because I was never confronted with an EULA when installing by GPO and I want to change as few things as possible to avoid any negative side effects (see next item).
And why did I not change the "IEXPLORER" property? Because for one thing I found that the installer can find out itself and secondly - much worse - setting this to "1" was the cause for Java not to work properly on my XP clients! Java applets on websites simply would not load, instead there was only a grey box. B.T.W. to test your Java install sun provides the following webpage:

http://java.com/de/download/help/testvm.xml

So I hope this will get you up and running.
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
7
Note
Disable Automatic Update in Latest Versions

Since approximately 1.6.18 / 6.0 update 18, Sun has included Java Auto Updater as a separate package that is automatically installed with the JRE. You can disable automatic updates by uninstalling the Java Auto Updater after the JRE is installed or upgraded, by the following command line:

msiexec /qn /x {4A03706F-666A-4037-7777-5F2748764D10}
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
6
Command Line
For JRE-6u5-Windows-i585-p.exe I used the following command to silently install;

jre-6u5-windows-i586-p.exe /qn ADDLOCAL=ALL SYSTRAY=0 EULA=0 IEXPLORER=1 JAVAUPDATE=0 AUTOUPDATECHECK=0 JU=0 REBOOT=ReallySupress

I then did the following reg hack to make sure the Auto-Updates were disabled;

[HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Update\Policy]
"EnableJavaUpdate"=dword:00000000
"NotifyDownload"=dword:00000000
"NotifyInstall"=dword:00000000

Then to silently un-install I ran the following;

msiexec /qn /x {3248F0A8-6813-11D6-A77B-00B0D0160050}
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
6
Note
Our business goals were to get rid of the EULA, turn off autoupdates, remove the update tab from the JAVA Control Panel applet, have Java work with Internet Explorer, and have the package install silently (thus I was able to utilize /qn and avoid the /qb installation issue).

I created an MST with the following settings using Acresso Admin Studio 9:

Under Property Manager I set the following properties:
1. AUTOUPDATECHECK = 0
2. EULA = 0
3. IEXPLORER = 1
4. JAVAUPDATE = 0

I then created a Custom Action as follows:

1. Run VBscript code
2. Location stored directly in custom action (places code in MST)

Code snippet

Set Shell = CreateObject ( "WScript.Shell" )
Shell.RegWrite "HKLM\SOFTWARE\JavaSoft\Java Update\Policy\EnableJavaUpdate", "0", "REG_DWORD"

3. Return processing = Synchronous (Ignores exit code)
4. Run during Patch Uninstall = No
5. In-Script Execution = Immediate Execution
6. Execution Scheduling = Always Execute
7. Install UI Sequence = Absent from Sequence
8. Install execute sequence = After InstallFinalize

I had to create the custom VB action because I found setting the JU property to 0 never removed the update tab from the Java control panel applet.
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
6
Note
Here is my VB script I wrote to deploy Java 6u12, it can easily be modified for 13 and up. I created this to run in SMS and return the correct error codes. It works for various applications just modify and remove the sub routines you don't need.

I wrote this to fix my 6u10 deployments where I needed to stop the jqs service in order to remove it. I then decided to make sure all of my systems left the jqs service disabled as I saw no delay in launching java apps without it.

Not Perfect but it works very well. I am sure someone with more advance vb script knowledge could fine tune this.

Dim WshShell
Set WshShell = WScript.CreateObject("Wscript.shell")
strWinDir = WshShell.ExpandEnvironmentStrings("%SYSTEMROOT%")

Dim ReturnCode
AppPath = GetPath

RemoveOldVersions

ReturnCode = 1
'Installes New Version

'WScript.Echo WshShell.CurrentDirectory
WshShell.CurrentDirectory = AppPath
'WScript.Echo WshShell.currentDirectory
ReturnCode = WshShell.Run("jre-6u12-windows-i586-p.exe IEXPLORER=1 JAVAUPDATE=0 AUTOUPDATECHECK=0 MOZILLA=1 JU=0 SYSTRAY=0 /qn",, True)

'Exit Path determined by ReturnCode
Select Case ReturnCode

Case 0
DisableUpdates
DisableJQS
'WScript.Echo "Installation Completed successfully: " & ReturnCode
WScript.Quit(ReturnCode)
Case 3010
DisableUpdates
DisableJQS
'WScript.Echo "Installation Completed successfully, Reboot Required: " & ReturnCode
WScript.Quit(ReturnCode)

End Select

'WScript.Echo "Installation ended with error: " & ReturnCode
WScript.Quit(ReturnCode)


Sub RemoveOldVersions

'Disables the JQS Service for removal
DisableJQS

'Removes old Versions
ReturnCode = WshShell.Run("MsiExec.exe /x{3248F0A8-6813-11D6-A77B-00B0D0160000} /qn REBOOT=reallysuppress",, True)
ReturnCode = WshShell.Run("MsiExec.exe /x{3248F0A8-6813-11D6-A77B-00B0D0160010} /qn REBOOT=reallysuppress",, True)
ReturnCode = WshShell.Run("MsiExec.exe /x{3248F0A8-6813-11D6-A77B-00B0D0160020} /qn REBOOT=reallysuppress",, True)
ReturnCode = WshShell.Run("MsiExec.exe /x{3248F0A8-6813-11D6-A77B-00B0D0160030} /qn REBOOT=reallysuppress",, True)
ReturnCode = WshShell.Run("MsiExec.exe /x{3248F0A8-6813-11D6-A77B-00B0D0160040} /qn REBOOT=reallysuppress",, True)
ReturnCode = WshShell.Run("MsiExec.exe /x{3248F0A8-6813-11D6-A77B-00B0D0160050} /qn REBOOT=reallysuppress",, True)
ReturnCode = WshShell.Run("MsiExec.exe /x{3248F0A8-6813-11D6-A77B-00B0D0160060} /qn REBOOT=reallysuppress",, True)
ReturnCode = WshShell.Run("MsiExec.exe /x{3248F0A8-6813-11D6-A77B-00B0D0160070} /qn REBOOT=reallysuppress",, True)
ReturnCode = WshShell.Run("Msiexec.exe /x{26A24AE4-039D-4CA4-87B4-2F83216010FF} /qn REBOOT=reallysuppress",, True)
ReturnCode = WshShell.Run("Msiexec.exe /x{26A24AE4-039D-4CA4-87B4-2F83216011FF} /qn REBOOT=reallysuppress",, True)
ReturnCode = WshShell.Run("Msiexec.exe /x{26A24AE4-039D-4CA4-87B4-2F83216012FF} /qn REBOOT=reallysuppress",, True)

End Sub

Sub DisableUpdates

'Sets registry Keys EnableJavaUpdate, UpdateSchedule, NotifyDownload, Frequency to the Value of 0
'These remove the update tab In the Java console and disable updates.

Const HKEY_LOCAL_MACHINE = &H80000002

strComputer = "."

Set oReg = GetObject("winmgmts:{impersonationLevel=impersonate}!\\" & strComputer & "\root\default:StdRegProv")
strKeyPath = "SOFTWARE\JavaSoft\Java Update\Policy"
dwValue = 0

strValueName = "EnableJavaUpdate"
oReg.SetDWORDValue HKEY_LOCAL_MACHINE, strKeyPath, strValueName, dwValue

strValueName = "UpdateSchedule"
oReg.SetDWORDValue HKEY_LOCAL_MACHINE, strKeyPath, strValueName, dwValue

strValueName = "NotifyDownload"
oReg.SetDWORDValue HKEY_LOCAL_MACHINE, strKeyPath, strValueName, dwValue

strValueName = "Frequency"
oReg.SetDWORDValue HKEY_LOCAL_MACHINE, strKeyPath, strValueName, dwValue

End Sub

Sub DisableJQS

'Disables the Java Quick Start service
On Error Resume Next
WshShell.CurrentDirectory = "C:\Program Files\Java\jre6\bin\"
WshShell.Run "jqs.exe -unregister",, True

End Sub

Function GetPath

Dim path
path = WScript.ScriptFullName ' script file name
GetPath = Left(path, InStrRev(path, "\"))

End Function
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
5
Note
Why does /qb fail?

Sun has added some new actions to the InstallUI Sequence, for some reason. Then they realised that /qn failed, so there's the same custom actions in the InstallExecuteSequence, but only when UILevel is 2.

To tell Windows Installer that /qb should go down the same code path as /qn, replace every UILevel=2 with UILevel<=3 and every UILevel<>2 with UILevel>3 (in a Transform, of course)
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
5
Note
You can run the MSI and MST created with Wise package Studio with the /QB! switch.

You should always creat a Transform for this MSI since the following needs to be changed or added:

In the Registry, only the following keys need to be changed:
I created an EXE with Wise Script Express that contained these Registry changes and called that EXE after InstallFinalize in the MSI Script with "Execute Program from Installation".

[HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Update\Policy]
"EnableJavaUpdate"=dword:00000000
"EnableAutoUpdateCheck"=dword:00000000
"NotifyDownload"=dword:00000000
"NotifyInstall"=dword:00000000
"Frequency"=dword:010d0000
"UpdateSchedule"=dword:00000000

I make it a practice in ALL MSI or MST packages I create, do also make these changes:

1) Change the Reboot option to Never reboot

2) Change the installation option to Per-Machine

3) Hide the remove and Modify buttons and only have the
Repair optin available (oh yeah, this option is
disabled by default because it is broken in the Vendor
MSI. If you enable it and run the Repair, it removes
the application)good job Sun.

4) Add a Property called ROOTDRIVE (ALL CAPS no spaces)
with a value of C:\ What this option does, is force
the application to install to C: and not a different
partition if the Users have one. This is not supposed
to happen if C: has more space, but it does.

KJ

Wisepackager.com
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
5
Note
Hi everyone ...

Using Orca for Altiris install, very easy:

Transform:Property:
1. AUTOUPDATECHECK = 0
2. EULA = 1
3. EULA_JAVAFX_ACCEPT = yes
4. IEXPLORER = 1
5. JAVAUPDATE = 0
6. JU=0
7. MOZILLA = 1
8. SYSTRAY = 0

ALTIRIS:

Set path to installer
Check run in quiet mode
Check copy
switch: TRANSFORMS=jre1.6.0_XX.mst

After install, on test box, goto:
http://java.com/en/download/help/testvm.xml

Should display current installed version

What I discovered is that when logged in as an admin, the update tab will be visible. When logged in as a non-admin account, it is not visible.

Same note as above regarding autoupdate check. You can double check to verify that updates are not working by configuring the auto-update to daily and the clock to the next hour. Leave it alone, it will not auto update (recheck with the website).

I did not need a reg fix or vb script to change any settings.

If you discover something to the contrary, please email me.
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
4
Note
After running the J2SE Installer downloaded from Java JRE 6 update 1, browsing to the %temp% dir it created a random named .msi file. I copied this msi file, paste and renamed it jre-6u1-windows-i586-p.msi, and run this Install.cmd:

Install.cmd:
{
jre-6u1-windows-i586-p.msi /qn AgreeToLicense=YES
REGEDIT /S RemoveSunJavaUpdateCheck.reg
}

RemoveSunJavaUpdateCheck.reg:
{
Windows Registry Editor Version 5.00

;Disable Java Update Check on Startup
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run]
"SunJavaUpdateSched"=-
}
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
4
Note
Created an MST with the RegKeys above and added a Custom Action after the Install finalize with the following command:

reg add "HKLM\Software\JavaSoft\Java Update\Policy" /v EnableJavaUpdate /t REG_DWORD /d 0 /f

run in C:\windows\system32

and there is no update.

Its the same as mentioned above, but with no external files.

Thanks guys for your research.
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
4
Note
Download the new update:

jre-6u12-windows-i586-p-s.exe
or
jre-6u12-windows-i586-p.exe

NOTE: The install does not put all the files into %temp% with the new Update 12 during the install. As such follow the directions below.

Run the install of the application manually to allow for the EXE to install the MSI and extract all the installation source files.

To determine were the installation sources files are (MSI and CAB) you can look in the registry

[HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{26A24AE4-039D-4CA4-87B4-2F83216012FF}]
"InstallSource"="<LOCATION TO GO TO>"

In the installsource location you will find both the MSI and the CAB file which will now allow you to create your MST file for the silent install of the application.

In the MST you can also include the changes you need to make in the registry to disable auto updates or perform any other standard deployment practices.
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
4
Note
Version 6 Update 13:

The process is similar to cory2211 did with update 12. I download the offline file and the run it on the clean machine. Get the .msi and .cab file under (this is from a xp machine) C:\Documents and Settings\"profile"\Application Data\Sun\Java\jre1.6.0_13.

I used Orca to make an .mst file.
under Property table, I make the following changes:
AutoUpdateCheck = 0
IExplorer = 1
JavaUpdate = 0
Mozilla = 1
Systray = 0
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
4
Note
For JRE 6_17 follow these steps:
------------------------------------------------------------
-Download from:
"https://cds.sun.com/is-bin/INTERSHOP.enfinity/WFS/CDS-CDS_Developer-Site/en_US/-/USD/ViewProductDetail-Start?ProductRef=jre-6u17-oth-JPR@CDS-CDS_Developer"
------------------------------------------------------------
-Extract MSI + CAB from "%USERPROFILE%\Application Data\Sun\Java\jre1.6.0_17"
------------------------------------------------------------
-Create MST or command line with property's:
AUTOUPDATECHECK=0
EULA=1
IEXPLORER=1
JAVAUPDATE=0
JU=0
MOZILLA=1
REBOOT=ReallySuppress
SYSTRAY=0
------------------------------------------------------------
- Add the EULA user info by adding the RegKey/value:
HKCU\Software\JavaSoft\Java Runtime Environment\1.6.0_17\
EULA=1 (REG_DWORD)
I did this by using Active Setup, learn more about this technique on "http://www.etlengineering.com/installer/activesetup.txt"
------------------------------------------------------------
Enjoy
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
3
Note
To add proxy information. (This is for version 1.6.0.X-14)
Make 2 files with the filenames.
"deployment.config"
"deployment.properties"
Look in the install.cmd script below to see where they go.

In the file "deplyment.config" add:

deployment.system.config=file\:/C\:/WINDOWS/Sun/Java/Deployment/deployment.properties
deployment.system.config.mandatory=false

In the file "deployment.properties" add:

#deployment.properties
deployment.proxy.ftp.host=your.proxy.com
deployment.proxy.https.port=8080
deployment.proxy.ftp.port=8080
deployment.proxy.type=1
deployment.proxy.http.host=your.proxy.com
deployment.proxy.https.host=your.proxy.com
deployment.proxy.same=true
deployment.browser.vm.mozilla=true
deployment.capture.mime.types=true
deployment.javapi.cache.update=true
deployment.proxy.http.port=8080
deployment.javaws.autodownload=NEVER
deployment.system.tray.icon=false
deployment.proxy.bypass.local=true

More alternatives here: http://java.sun.com/javase/6/docs/technotes/guides/deployment/deployment-guide/properties.html

Make a commands in a script that are similar to that I have made in the script below. I have added my whole install.cmd script here. (server names modified)

Title Sun Java Runtime 1.6.0.14 INSTALL
net stop "Java Quick Starter" >nul
::waiting for the service to stop
ping localhost -n 10 >nul
set SOURCE=\\server\share$\Sun\Java\1.6.0.14
MSIEXEC /i "%SOURCE%\jre1.6.0_14.msi" /qn
reg add "HKLM\SOFTWARE\Javasoft\Java Plug-in\1.6.0_14" /v HideSystemTrayIcon /t reg_dword /d 0 /f
::Disable Updates
reg add "HKLM\SOFTWARE\Javasoft\Java Update\Policy" /v EnableJavaUpdate /t reg_dword /d 0 /f
reg add "HKLM\SOFTWARE\Javasoft\Java Update\Policy" /v Frequency /t reg_dword /d 0 /f
reg add "HKLM\SOFTWARE\Javasoft\Java Update\Policy" /v NotifyDownload /t reg_dword /d 0 /f
reg add "HKLM\SOFTWARE\Javasoft\Java Update\Policy" /v NotifyInstall /t reg_dword /d 0 /f
reg add "HKLM\SOFTWARE\Javasoft\Java Update\Policy" /v UpdateSchedule /t reg_dword /d 0 /f
::Delete from Run Key
reg delete "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Run" /v SunJavaUpdateSched /f
::Proxy settings
md "C:\WINDOWS\Sun\Java\Deployment"
copy "%SOURCE%\deployment.config" "C:\windows\sun\Java\Deployment" /Y
copy "%SOURCE%\deployment.properties" "C:\windows\sun\Java\Deployment" /Y
net start "Java Quick Starter"
exit /b 0
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
2
Note

At the moment it looks like it's not possible to globally disable automatic updates. JRE 6.0u1 doesn't recognize the EnableAutoUpdateCheck or JavaUpdate keys. Instead the information is stored in binary format in HKCU\Software\JavaSoft\Java Update\Policy\EnableAutoUpdateCheck, and that information does not carry over to other users, even if the NTUSER.DAT file is copied over to the default user. JRE 5.0u6 is the most recent version where the automatic update behavior can be controlled for all users.

Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
1
Script
We mostly use Windows 7 x64 but we do have a few x86 systems so here is the script we run from the k1000 (after extracting all files from the java.exe file we add them and the script to a compressed file and launch the script) As time permits I will rewrite as a vbs file but here is what I have so far. This is as simple as I can make it and we have had no problems. I thought about removing previous versions but I really don't see the need. Realistically by the time it might become a problem I would be changing out their workstation anyway and if I was to pass their workstation down to someone else I would wipe it anyway. ------------Script----------------- @ECHO OFF ECHO Sun J2SE Runtime Environment 6 Update 31.. start /wait msiexec /qn /norestart /i jre1.6.0_31.msi REM Configure on x86 systems IF NOT EXIST %SYSTEMROOT%\SysWOW64\REG.EXE ( REG.EXE ADD "HKLM\SOFTWARE\JavaSoft\Java Update\Policy" /v EnableJavaUpdate /t REG_DWORD /d 0 /f REG.EXE ADD "HKLM\SOFTWARE\JavaSoft\Java Update\Policy" /v EnableAutoUpdateCheck /t REG_DWORD /d 0 /f ) REM Configure on x64 systems IF EXIST %SYSTEMROOT%\SysWOW64\REG.EXE ( %SYSTEMROOT%\SysWOW64\REG.EXE ADD "HKLM64\SOFTWARE\Wow6432Node\JavaSoft\Java Update\Policy" /v EnableJavaUpdate /t REG_DWORD /d 0 /f %SYSTEMROOT%\SysWOW64\REG.EXE ADD "HKLM64\SOFTWARE\Wow6432Node\JavaSoft\Java Update\Policy" /v EnableAutoUpdateCheck /t REG_DWORD /d 0 /f ) -------------------end of Script---------------
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
1
Note
I'm so sick of fighting with disabling auto updates with JRE. Every version seems to be slightly different.

Anyway, today I refer specifically to 1.6.0_14 (aka version 6 update 14).

The install .exe accepts MSI command-line arguments which is cool. I created a transform that contains a vbs custom action to delete the "Run" registry entry for jusched.exe. It seems that if jusched.exe isn't running auto updates don't happen, regardless of the other update settings. The custom action is last in the InstallExecuteSequence. Simple and hopefully works for future versions too.

Now I just run "jre-6u14-windows-i586-s.exe TRANSFORMS=NoUpdateSched.mst /qb!" and it's done. You can even speed up the install a little by getting the extracted msi and cab files from "%USERPROFILE%\Application Data\Sun\Java\jre1.6.0_14\" and run "msiexec /i jre1.6.0_14.msi TRANSFORMS=NoUpdateSched.mst /qb!", this way the exe doesn't have to extract them first.

Here's the vbs:

Option Explicit

Const HKEY_LOCAL_MACHINE = &H80000002

' Setup registry connector
Dim strComputer, objReg, oShell

On Error Resume Next

strComputer = "."
Set objReg=GetObject("winmgmts:{impersonationLevel=impersonate}!\\" & strComputer & "\root\default:StdRegProv")
Set oShell=CreateObject("Wscript.Shell")

DeleteRegKeyValue HKEY_LOCAL_MACHINE, "SOFTWARE\Microsoft\Windows\CurrentVersion\Run", "SunJavaUpdateSched"
Wscript.Quit 0

Function DeleteRegKeyValue(strRegistry, strKeyPath, strValueName)
objReg.DeleteValue strRegistry,strKeyPath,strValueName
End Function
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
1
Command Line
For disabling the Update function in Update 16:
Simply create a mst file and change the "AUTOUPDATECHECK" and "JAVAUPDATE" public properties to 0

Then run the msi with the mst file applyed (msiexec /I jre1.6.0_16.msi TRANSFORMS=NoUpdate.mst /passive)
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
0
Note

Here I published a tutorial for it and many others programs. Please comment on the blog if you have questions.

 

http://it-grund.blogspot.com/2012/04/how-to-deployinstall-silently-and.html

 

Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
0
Note
If anyone notices sorry I posted this to the wrong spot the first time We mostly use Windows 7 x64 but we do have a few x86 systems so here is the script we run from the k1000 (after extracting all files from the java.exe file we add them and the script to a compressed file and launch the script) As time permits I will rewrite as a vbs file but here is what I have so far. This is as simple as I can make it and we have had no problems. I thought about removing previous versions but I really don't see the need. Realistically by the time it might become a problem I would be changing out their workstation anyway and if I was to pass their workstation down to someone else I would wipe it anyway. ------------Script----------------- @ECHO OFF ECHO Sun J2SE Runtime Environment 6 Update 31.. start /wait msiexec /qn /norestart /i jre1.6.0_31.msi REM Configure on x86 systems IF NOT EXIST %SYSTEMROOT%\SysWOW64\REG.EXE ( REG.EXE ADD "HKLM\SOFTWARE\JavaSoft\Java Update\Policy" /v EnableJavaUpdate /t REG_DWORD /d 0 /f REG.EXE ADD "HKLM\SOFTWARE\JavaSoft\Java Update\Policy" /v EnableAutoUpdateCheck /t REG_DWORD /d 0 /f ) REM Configure on x64 systems IF EXIST %SYSTEMROOT%\SysWOW64\REG.EXE ( %SYSTEMROOT%\SysWOW64\REG.EXE ADD "HKLM64\SOFTWARE\Wow6432Node\JavaSoft\Java Update\Policy" /v EnableJavaUpdate /t REG_DWORD /d 0 /f %SYSTEMROOT%\SysWOW64\REG.EXE ADD "HKLM64\SOFTWARE\Wow6432Node\JavaSoft\Java Update\Policy" /v EnableAutoUpdateCheck /t REG_DWORD /d 0 /f ) -------------end of Script---------------
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
0
Command Line
To disable the JQS service for Java 6u10 and higher use this command

'Disables the Java Quick Start service
"C:\Program Files\Java\jre6\bin\jqs.exe -unregister"
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
0
Note

I have built ZEN deployments for several versions by extracting just the MSI and building an MST using the property settings listed in this section. In previous versions, the MSI was self-contained. Today I found that the msi for v1.6.0_23 no longer has the files compiled with it so the data.cab file also has to be present for the distribution.

Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
0
Note
The following gets rid of all versions prior to the one specified in the script. Just used it to kill off everything prior to ver update 6 ver 24

Kudos to the author.

Shame on sun. Maybe oracle will fix this finally.

'# Galen Dobbs - 12:42 19/03/2009
'# Uninstalls all but the chosen version of Java Runtime.
'# Based on a script by 'Daz' from the Appdeploy.com message boards.
'# Based on a script by 'muaddip' from the Appdeploy.com message boards.
'# http://www.appdeploy.com/messageboards/tm.asp?m=29809


Option Explicit

Dim wshShell, fso, strLogFile, ts, strTempDir, strTempISS, strUnString, tsIn, blFound
Dim strUninstLine, CLSID, search5, search6, search7, strJRE1, strDisplayName, strDisplayVersion
Dim strPublisher, strUninstallString, strJREUninstallString, strJREDisplayName
Dim search1, search2, search3, search4, strJREUninstallStringNEW, ret, strUninstCMD
Dim tsISS, strSetupexe, qVal, strComputername, strCurrentVersion, searchCurVer

'Change this to match the version that you don't want to have it uninstall
strCurrentVersion = "Java(TM) 6 Update 24"

qVal = 0

Set wshShell = CreateObject("WScript.Shell")
Set fso = CreateObject("Scripting.FileSystemObject")

strComputername = wshShell.ExpandEnvironmentStrings("%COMPUTERNAME%")

If Not fso.FolderExists("C:\Logs") Then fso.CreateFolder("C:\Logs")
strLogFile = "C:\Logs\Java_Uninstall_" & strComputername & ".log"
Set ts = fso.OpenTextFile(strLogFile, 8, True)

ts.WriteLine String(80, "_")
ts.WriteLine String(80, "¯")
ts.WriteLine Now() & " - Java Runtime(s) uninstallation"
ts.WriteLine String(80, "_") & vbCrlf

'# Generate Registry extracts from 'Uninstall' keys.
PreFlight()

'# Kill Java Processes
KillProc()

strTempDir = wshShell.ExpandEnvironmentStrings("%temp%")
strTempISS = strTempDir & "\iss"
strUnString = " -s -a /s /f1"
Set tsIn = fso.OpenTextFile(strTempDir & "\uninstall.tmp", 1)

If Not fso.FolderExists(strTempISS) Then fso.CreateFolder(strTempISS)

blFound = False

Do While Not tsIn.AtEndOfStream
strUninstLine = tsIn.ReadLine
CLSID = Mid(strUninstLine, 73, 38)
search5 = Instr(strUninstLine, "JRE 1")
search6 = Instr(strUninstLine, "]")
If search5 > 0 AND search6 > 0 Then
strJRE1 = Replace(Mid(strUninstLine, search5, search6),"]","")
End If

On Error Resume Next

strDisplayName = wshShell.RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\" & CLSID & "\DisplayName")
strDisplayVersion = wshShell.RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\" & CLSID & "\DisplayVersion")
strPublisher = wshShell.RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\" & CLSID & "\Publisher")
strUninstallString = wshShell.RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\" & CLSID & "\UninstallString")

strJREUninstallString = wshShell.RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\" & strJRE1 & "\UninstallString")
strJREDisplayName = wshShell.RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\" & strJRE1 & "\DisplayName")

On Error Goto 0

'Search for presence of Java and Sun in DisplayName and Publisher
search1 = Instr(1, strDisplayName, "Java", 1)
search2 = Instr(1, strPublisher, "Sun", 1)
search3 = Instr(1, strDisplayName, "J2SE", 1)
search4 = Instr(1, strUninstallString, "setup.exe", 1)
search7 = InStr(1, strDisplayName, "Development", 1) + InStr(1, strDisplayName, "Java DB", 1)

'Make sure it is not the current version
searchCurVer = InStr(1, strDisplayName, strCurrentVersion, 1)

If searchCurVer > 0 Then
ts.WriteLine Now() & " - Current Version: " & strDisplayName & " found, leaving it alone."

ElseIf strJREUninstallString <> "" Then
blFound = True
'# JRE 1 found
strJREUninstallStringNEW = Replace(strJREUninstallString," -f"," -s -a /s /f")
ts.WriteLine Now() & " - " & strJREDisplayName
ts.WriteLine Now() & " - Uninstall String sent: " & strJREUninstallStringNEW
ret = wshShell.Run(strJREUninstallStringNEW , 0, True)
ts.WriteLine Now() & " - Return: " & ret
If ret <> 0 And ret <> 3010 Then qVal = 1

ElseIf search7 = 0 And search1 > 0 Or search3 > 0 And search2 > 0 Then
blFound = True
strUninstCMD = "msiexec.exe /x " & CLSID & " /norestart /qn"

If search4 > 0 Then
'# Old InstallShield setup found
Set tsISS = fso.OpenTextFile(strTempISS & "\" & CLSID & ".iss", 2, True)

'Create Response file for any Java Version
tsISS.WriteLine "[InstallShield Silent]"
tsISS.WriteLine "Version=v6.00.000"
tsISS.WriteLine "File=Response File"
tsISS.WriteLine "[File Transfer]"
tsISS.WriteLine "OverwrittenReadOnly=NoToAll"
tsISS.WriteLine "[" & CLSID & "-DlgOrder]"
tsISS.WriteLine "Dlg0=" & CLSID & "-SprintfBox-0"
tsISS.WriteLine "Count=2"
tsISS.WriteLine "Dlg1=" & CLSID & "-File Transfer"
tsISS.WriteLine "[" & CLSID & "-SprintfBox-0]"
tsISS.WriteLine "Result=1"
tsISS.WriteLine "[Application]"
tsISS.WriteLine "Name=Java 2 Runtime Environment, SE v1.4.0_01"
tsISS.WriteLine "Version=1.4.0_01"
tsISS.WriteLine "Company=JavaSoft"
tsISS.WriteLine "Lang=0009"
tsISS.WriteLine "[" & CLSID & "-File Transfer]"
tsISS.WriteLine "SharedFile=YesToAll"
tsISS.Close

strSetupexe = Left(strUninstallString, search4 + 9)
strUninstCMD = strSetupexe & strUnString & Chr(34) & strTempISS & "\" & CLSID & ".iss" & Chr(34)
End If

ts.WriteLine Now() & " - " & strDisplayName & " - Version: " & strDisplayVersion
ts.WriteLine Now() & " - Uninstall String sent: " & strUninstCMD
ret = wshShell.Run(strUninstCMD , 0, True)
ts.WriteLine Now() & " - Return: " & ret
If ret <> 0 And ret <> 3010 Then qVal = 1
End If

Loop

tsIn.Close

If Not blFound Then
ts.WriteLine Now() & " - No Old Java Runtime versions found installed."
qVal = 99
End If

ts.WriteLine String(80, "_")
ts.WriteLine String(80, "¯")
ts.Close
fso.DeleteFolder(strTempISS)
fso.DeleteFile(strTempDir & "\uninstall.tmp")

WScript.Quit(qVal)

Sub PreFlight()
'# Creates temp files containing extracts from registry 'Uninstall' keys.
Dim wshShell, fso, sTemp
Set wshShell = CreateObject("WScript.Shell")
Set fso = CreateObject("Scripting.FileSystemObject")
sTemp = wshShell.ExpandEnvironmentStrings("%temp%")
wshShell.Run "REGEDIT /E %temp%\registry.tmp HKEY_LOCAL_MACHINE\SOFTWARE\microsoft\windows\currentversion\uninstall", 0, True
wshShell.Run "cmd /c type %temp%\registry.tmp | find /i ""{"" | find /i ""}]"" > %temp%\uninstall.tmp ", 0, True
wshShell.Run "cmd /c type %temp%\registry.tmp | find /i ""JRE 1"" >> %temp%\uninstall.tmp ", 0, True
If Not fso.FileExists(sTemp & "\uninstall.tmp") Then
ts.WriteLine Now() & " - No input - %temp%\uninstall.tmp Reg extract not created."
ts.WriteLine String(80, "_")
ts.WriteLine String(80, "¯")
ts.Close
WScript.Quit(1)
End If
End Sub

Sub KillProc()
'# kills jusched.exe and jqs.exe if they are running. These processes will cause the installer to fail.
Dim wshShell
Set wshShell = CreateObject("WScript.Shell")
wshShell.Run "Taskkill /F /IM jusched.exe /T", 0, True
wshShell.Run "Taskkill /F /IM jqs.exe /T", 0, True
End Sub
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
0
Virtualization
Have noticed a capture of JRE can have incorrectly permissioned HKCU\Software\Classes\CLSID entries in the read only part of the layer.

This has caused OLE issues in Outlook 2010 forms like Voicemail, Enterprise Vault and some Calendar entries like

'The custom form could not be opened. Outlook
will use an Outlook form instead. An error occurred
registering the form in the OLE registry.'

Remove these keys from ready only layer to fix.
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
0
Note
The following gets rid of all versions prior to the one specified in the script. Just used it to kill off everything prior to ver update 6 ver 24

Kudos to the author.

Shame on sun. Maybe oracle will fix this finally.

'# Galen Dobbs - 12:42 19/03/2009
'# Uninstalls all but the chosen version of Java Runtime.
'# Based on a script by 'Daz' from the Appdeploy.com message boards.
'# Based on a script by 'muaddip' from the Appdeploy.com message boards.
'# http://www.appdeploy.com/messageboards/tm.asp?m=29809


Option Explicit

Dim wshShell, fso, strLogFile, ts, strTempDir, strTempISS, strUnString, tsIn, blFound
Dim strUninstLine, CLSID, search5, search6, search7, strJRE1, strDisplayName, strDisplayVersion
Dim strPublisher, strUninstallString, strJREUninstallString, strJREDisplayName
Dim search1, search2, search3, search4, strJREUninstallStringNEW, ret, strUninstCMD
Dim tsISS, strSetupexe, qVal, strComputername, strCurrentVersion, searchCurVer

'Change this to match the version that you don't want to have it uninstall
strCurrentVersion = "Java(TM) 6 Update 24"

qVal = 0

Set wshShell = CreateObject("WScript.Shell")
Set fso = CreateObject("Scripting.FileSystemObject")

strComputername = wshShell.ExpandEnvironmentStrings("%COMPUTERNAME%")

If Not fso.FolderExists("C:\Logs") Then fso.CreateFolder("C:\Logs")
strLogFile = "C:\Logs\Java_Uninstall_" & strComputername & ".log"
Set ts = fso.OpenTextFile(strLogFile, 8, True)

ts.WriteLine String(80, "_")
ts.WriteLine String(80, "¯")
ts.WriteLine Now() & " - Java Runtime(s) uninstallation"
ts.WriteLine String(80, "_") & vbCrlf

'# Generate Registry extracts from 'Uninstall' keys.
PreFlight()

'# Kill Java Processes
KillProc()

strTempDir = wshShell.ExpandEnvironmentStrings("%temp%")
strTempISS = strTempDir & "\iss"
strUnString = " -s -a /s /f1"
Set tsIn = fso.OpenTextFile(strTempDir & "\uninstall.tmp", 1)

If Not fso.FolderExists(strTempISS) Then fso.CreateFolder(strTempISS)

blFound = False

Do While Not tsIn.AtEndOfStream
strUninstLine = tsIn.ReadLine
CLSID = Mid(strUninstLine, 73, 38)
search5 = Instr(strUninstLine, "JRE 1")
search6 = Instr(strUninstLine, "]")
If search5 > 0 AND search6 > 0 Then
strJRE1 = Replace(Mid(strUninstLine, search5, search6),"]","")
End If

On Error Resume Next

strDisplayName = wshShell.RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\" & CLSID & "\DisplayName")
strDisplayVersion = wshShell.RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\" & CLSID & "\DisplayVersion")
strPublisher = wshShell.RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\" & CLSID & "\Publisher")
strUninstallString = wshShell.RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\" & CLSID & "\UninstallString")

strJREUninstallString = wshShell.RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\" & strJRE1 & "\UninstallString")
strJREDisplayName = wshShell.RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\" & strJRE1 & "\DisplayName")

On Error Goto 0

'Search for presence of Java and Sun in DisplayName and Publisher
search1 = Instr(1, strDisplayName, "Java", 1)
search2 = Instr(1, strPublisher, "Sun", 1)
search3 = Instr(1, strDisplayName, "J2SE", 1)
search4 = Instr(1, strUninstallString, "setup.exe", 1)
search7 = InStr(1, strDisplayName, "Development", 1) + InStr(1, strDisplayName, "Java DB", 1)

'Make sure it is not the current version
searchCurVer = InStr(1, strDisplayName, strCurrentVersion, 1)

If searchCurVer > 0 Then
ts.WriteLine Now() & " - Current Version: " & strDisplayName & " found, leaving it alone."

ElseIf strJREUninstallString <> "" Then
blFound = True
'# JRE 1 found
strJREUninstallStringNEW = Replace(strJREUninstallString," -f"," -s -a /s /f")
ts.WriteLine Now() & " - " & strJREDisplayName
ts.WriteLine Now() & " - Uninstall String sent: " & strJREUninstallStringNEW
ret = wshShell.Run(strJREUninstallStringNEW , 0, True)
ts.WriteLine Now() & " - Return: " & ret
If ret <> 0 And ret <> 3010 Then qVal = 1

ElseIf search7 = 0 And search1 > 0 Or search3 > 0 And search2 > 0 Then
blFound = True
strUninstCMD = "msiexec.exe /x " & CLSID & " /norestart /qn"

If search4 > 0 Then
'# Old InstallShield setup found
Set tsISS = fso.OpenTextFile(strTempISS & "\" & CLSID & ".iss", 2, True)

'Create Response file for any Java Version
tsISS.WriteLine "[InstallShield Silent]"
tsISS.WriteLine "Version=v6.00.000"
tsISS.WriteLine "File=Response File"
tsISS.WriteLine "[File Transfer]"
tsISS.WriteLine "OverwrittenReadOnly=NoToAll"
tsISS.WriteLine "[" & CLSID & "-DlgOrder]"
tsISS.WriteLine "Dlg0=" & CLSID & "-SprintfBox-0"
tsISS.WriteLine "Count=2"
tsISS.WriteLine "Dlg1=" & CLSID & "-File Transfer"
tsISS.WriteLine "[" & CLSID & "-SprintfBox-0]"
tsISS.WriteLine "Result=1"
tsISS.WriteLine "[Application]"
tsISS.WriteLine "Name=Java 2 Runtime Environment, SE v1.4.0_01"
tsISS.WriteLine "Version=1.4.0_01"
tsISS.WriteLine "Company=JavaSoft"
tsISS.WriteLine "Lang=0009"
tsISS.WriteLine "[" & CLSID & "-File Transfer]"
tsISS.WriteLine "SharedFile=YesToAll"
tsISS.Close

strSetupexe = Left(strUninstallString, search4 + 9)
strUninstCMD = strSetupexe & strUnString & Chr(34) & strTempISS & "\" & CLSID & ".iss" & Chr(34)
End If

ts.WriteLine Now() & " - " & strDisplayName & " - Version: " & strDisplayVersion
ts.WriteLine Now() & " - Uninstall String sent: " & strUninstCMD
ret = wshShell.Run(strUninstCMD , 0, True)
ts.WriteLine Now() & " - Return: " & ret
If ret <> 0 And ret <> 3010 Then qVal = 1
End If

Loop

tsIn.Close

If Not blFound Then
ts.WriteLine Now() & " - No Old Java Runtime versions found installed."
qVal = 99
End If

ts.WriteLine String(80, "_")
ts.WriteLine String(80, "¯")
ts.Close
fso.DeleteFolder(strTempISS)
fso.DeleteFile(strTempDir & "\uninstall.tmp")

WScript.Quit(qVal)

Sub PreFlight()
'# Creates temp files containing extracts from registry 'Uninstall' keys.
Dim wshShell, fso, sTemp
Set wshShell = CreateObject("WScript.Shell")
Set fso = CreateObject("Scripting.FileSystemObject")
sTemp = wshShell.ExpandEnvironmentStrings("%temp%")
wshShell.Run "REGEDIT /E %temp%\registry.tmp HKEY_LOCAL_MACHINE\SOFTWARE\microsoft\windows\currentversion\uninstall", 0, True
wshShell.Run "cmd /c type %temp%\registry.tmp | find /i ""{"" | find /i ""}]"" > %temp%\uninstall.tmp ", 0, True
wshShell.Run "cmd /c type %temp%\registry.tmp | find /i ""JRE 1"" >> %temp%\uninstall.tmp ", 0, True
If Not fso.FileExists(sTemp & "\uninstall.tmp") Then
ts.WriteLine Now() & " - No input - %temp%\uninstall.tmp Reg extract not created."
ts.WriteLine String(80, "_")
ts.WriteLine String(80, "¯")
ts.Close
WScript.Quit(1)
End If
End Sub

Sub KillProc()
'# kills jusched.exe and jqs.exe if they are running. These processes will cause the installer to fail.
Dim wshShell
Set wshShell = CreateObject("WScript.Shell")
wshShell.Run "Taskkill /F /IM jusched.exe /T", 0, True
wshShell.Run "Taskkill /F /IM jqs.exe /T", 0, True
End Sub
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows
-1
Command Line
On Update 20 you have to edit the
%USERPRIFILE%\AppData\LocalLow\Sun\Java\Deployment\deployment.propertiers
file if you want to turn off the Auto-Download function.

Add following row:
deployment.javaws.autodownload=NEVER

the rest of the file may be empty!
Setup Information:
Setup Type: unspecified
Deployment Method Used: unspecified
Deployment Difficulty: unspecified
Platform(s): Windows

Inventory Records (1)

View inventory records anonymously contributed by opt-in users of the K1000 Systems Management Appliance.

Versions

Java Runtime Environment

Version

6

Questions & Answers (72)

Questions & Answers related to Oracle Java Runtime Environment

2
ANSWERS
1
ANSWERED
0
ANSWERS
6
ANSWERED
2
ANSWERED
0
ANSWERS
1
ANSWERED
9
ANSWERED
2
ANSWERED
4
ANSWERS
1
ANSWERS
4
ANSWERED
2
ANSWERS
2
ANSWERS
4
ANSWERS
4
ANSWERED
1
ANSWERED
2
ANSWERS
1
ANSWERS
1
ANSWERS

Blogs (8)

Blog posts related to Oracle Java Runtime Environment

Reviews (0)

Reviews related to Oracle Java Runtime Environment

 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ