For a Landesk batch package I used 3 files:
1. bat script (install_arcgis10_1.bat)
2. zip file containing the installation files (arcgis10_1.zip)
3. 7zip.exe (just download the executable from www.7-zip.org)
The script queries the windows registry for product codes for specific version of ArcGIS, and uninstalls it before running the 10.1 installer (in my case i run a query for 9.2 and 9.3 and uinstall them) For a full list of ArcGIS uinstall strings (GUID), look here: http://support.esri.com/en/knowledgebase/techarticles/detail/28709
Below is the bat script:
@echo off
:: Arcgis 10.1 installer
::Check for previous versions of Arcgis
::Check for Windows x64
IF EXIST %windir%\SysWOW64\ (
REM Remove ArcGIS 9.2
reg query HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall\{1F34839E-4826-4B64-B1B3-42E5AE8DEC5A} >NUL 2>NUL && start /wait MsiExec.exe /qn /x{1F34839E-4826-4B64-B1B3-42E5AE8DEC5A} /Li "c:\UinstallESRI92.txt"
REM Remove ArcGIS 9.3
reg query HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall\{5033400B-0977-45AB-94CE-CC135A8E1BBB} >NUL 2>NUL && start /wait MsiExec.exe /qn /x{5033400B-0977-45AB-94CE-CC135A8E1BBB} /Li "c:\UinstallESRI93.txt"
) ELSE (
REM Remove ArcGIS 9.2
reg query HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{1F34839E-4826-4B64-B1B3-42E5AE8DEC5A} >NUL 2>NUL && start /wait MsiExec.exe /qn /x{1F34839E-4826-4B64-B1B3-42E5AE8DEC5A} /Li "c:\UinstallESRI92.txt"
REM Remove ArcGIS 9.3
reg query HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{5033400B-0977-45AB-94CE-CC135A8E1BBB} >NUL 2>NUL && start /wait MsiExec.exe /qn /x{5033400B-0977-45AB-94CE-CC135A8E1BBB} /Li "c:\UinstallESRI93.txt"
)
:: Unzip Arcgis installer
start /wait 7za.exe x arcgis10_1.zip -y -oC:\Windows\temp\arcgis10_1
:: Run ArcGIS 10.1 Installer
start /wait C:\Windows\temp\arcgis10_1\setup.exe ESRI_LICENSE_HOST=PATH_TO_YOUR_LICENSE_SERVER /qn
:END
Created with version 10.2.1
1) extract the Installer to a Temp location by double-clicking the downloaded installer. Cancel the automated launch when extraction completes.
2) create an AIP with the command line: msiexec /a "setup.msi" TARGETDIR="<temp path>"
3) using Orca create an MST with the following options in the PROPERTY table:
View inventory records anonymously contributed by opt-in users of the K1000 Systems Management Appliance.