ich bekomme die unbeaufsichtigte Installation des Programms AVG 2011 Free nicht hin. Ich habe die heruntergeladene Installationsdatei "avg.exe" genannt, weil der Dateiname sonst ewig lang ist und für die Installation der Name eigentlich wursch ist.
Die Unattended-Parameter sind wie folgt:
Code: Alles auswählen
avg.exe /UILevel=silent /InstallToolbar=0 /ChangeBrowserSearchProvider=0 /InstallSidebar=0 /ParticipateProductImprovement=0 /DontRestart
Installiere ich das aber mit Opsi und starte ich die Installation "on Demand" dann müßte der Anwender die gesamte Installationsprozedur durchgehen, als ob überhaupt keine Parameter übergeben wurden.
Übersehe ich was? Hab ich was vergessen? Oder geht es mit diesem Programm überhaupt nicht? Die Parameter zum Aufruf der Unattended Installation von AVG habe ich übrigens von AVG selbst.
Die setup.ins die ich dazu gebaut habe sieht folgendermaßen aus (den Bereich Winbatch_Install64 nicht beachten, der wird angepaßt, wenn Winbatch_Install32 funktioniert!):
Code: Alles auswählen
; Copyright (c) uib gmbh (www.uib.de)
; This sourcecode is owned by uib
; and published under the Terms of the General Public License.
; credits: http://www.opsi.org/credits/
[Initial]
LogLevel=9
; Log Errors in Logfile but don't abort:
ExitOnError=false
; Show syntax errors in the script:
ScriptErrorMessages=on
; Dont trace step by step through the script:
TraceMode=off
; let started programs run in front of the winst window
StayOnTop=false
[Actions]
requiredWinstVersion >= "4.10.8.6"
DefVar $MsiId32$
DefVar $UninstallProgram32$
DefVar $MsiId64$
DefVar $UninstallProgram64$
DefVar $LogDir$
DefVar $ProductId$
DefVar $MinimumSpace$
DefVar $InstallDir32$
DefVar $InstallDir64$
DefVar $ExitCode$
DefVar $LicenseRequired$
DefVar $LicenseKey$
DefVar $LicensePool$
DefVar $INST_SystemType$
DefVar $INST_architecture$
DefVar $Version$
DefVar $Inst_Cmd32$
DefVar $Inst_Cmd64$
DefVar $Inst_Prg$
DefVar $Uninst_Cmd$
DefVar $Uninst_Prg$
Set $INST_SystemType$ = GetSystemType
set $INST_architecture$ = GetProductProperty("install_architecture","system specific")
Set $LogDir$ = "%SystemDrive%\tmp"
; ----------------------------------------------------------------
; - Please edit the following values -
; ----------------------------------------------------------------
;$ProductId$ should be the name of the product in opsi
; therefore please: only lower letters, no umlauts,
; no white space use '-' as a seperator
Set $ProductId$ = "avg"
;Kein Punkt in der Versionsnummer! 4.30 ist 430, 4.40 ist 440 oder 4.51 ist 451!
Set $Version$ = "2011"
Set $MinimumSpace$ = "30 MB"
; the path were we find the product after the installation
Set $InstallDir32$ = "%ProgramFiles32Dir%\avg-free"
Set $InstallDir64$ = "%ProgramFiles64Dir%\avg-free"
Set $LicenseRequired$ = "false"
Set $LicensePool$ = "p_" + $ProductId$
Set $Inst_Prg$ = "avg.exe"
Set $Inst_Cmd32$ = '/UILevel=silent /InstallToolbar=0 /ChangeBrowserSearchProvider=0 /InstallSidebar=0 /ParticipateProductImprovement=0 /DontRestart'
Set $Inst_Cmd64$ = '/UILevel=silent /InstallToolbar=0 /ChangeBrowserSearchProvider=0 /InstallSidebar=1 /ParticipateProductImprovement=0 /DontRestart'
Set $Uninst_Cmd$ = " /AppMode=SETUP /Maintenance=2 /UILevel=silent"
Set $Uninst_Prg$ = "\AVG10\avgmfapx.exe"
; ----------------------------------------------------------------
if not(HasMinimumSpace ("%SystemDrive%", $MinimumSpace$))
LogError "Not enough space on %SystemDrive%, " + $MinimumSpace$ + " on drive %SystemDrive% needed for " + $ProductId$
isFatalError
; Stop process and set installation status to failed
else
comment "Show product picture"
ShowBitmap "%ScriptPath%\" + $ProductId$ + ".jpg" $ProductId$
; if FileExists("%ScriptPath%\delsub.ins")
; comment "Start uninstall sub section"
; Sub "%ScriptPath%\delsub.ins"
; endif
if $LicenseRequired$ = "true"
comment "Licensing required, reserve license and get license key"
Sub_get_licensekey
endif
comment "Installiere AVG..."
if (($INST_SystemType$ = "x86 System") and ($INST_architecture$ = "system specific")) or ($INST_architecture$ = "both") or ($INST_architecture$ = "32 only")
Message "Kopiere " + $ProductId$ + " nach "+$InstallDir32$+". Das dauert etwas, bitte Geduld..."
comment "copying " + $ProductId$ + " nach "+$InstallDir32$+"
Files_install_32
Message "Installiere " + $ProductId$ + ". Das dauert etwas, bitte Geduld..."
comment "Start setup program"
Winbatch_install_32
Files_delete_32
Sub_check_exitcode
endif
if ($INST_SystemType$ = "64 Bit System") and (($INST_architecture$ = "system specific") or ($INST_architecture$ = "both") or ($INST_architecture$ = "64 only"))
Message "Kopiere " + $ProductId$ + " nach "+$InstallDir32$+". Das dauert etwas, bitte Geduld..."
comment "copying " + $ProductId$ + " nach "+$InstallDir32$+"
Files_install_64
Message "Installiere " + $ProductId$ + ". Das dauert etwas, bitte Geduld..."
comment "Start setup program"
Winbatch_install_64
Files_delete_64
Sub_check_exitcode
endif
endif
[Winbatch_install_32]
; Choose one of the following examples as basis for your installation
; You can use $LicenseKey$ var to pass a license key to the installer
;
; === Nullsoft Scriptable Install System ================================================================
%ScriptPath%\$Inst_Prg$ $Inst_Cmd32$
;$InstallDir32$\install.bat " $InstallDir32$
[Winbatch_install_64]
; Choose one of the following examples as basis for your installation
; You can use $LicenseKey$ var to pass a license key to the installer
;
; === Nullsoft Scriptable Install System ================================================================
"$InstallDir64$\install.bat " $InstallDir64$
[Files_install_32]
; Example of recursively copying some files into the installation directory:
;
;copy "%ScriptPath%\$Inst_Prg$" $InstallDir32$
;copy "%ScriptPath%\install.bat" $InstallDir32$
[Files_install_64]
; Example of recursively copying some files into the installation directory:
;
copy "%ScriptPath%\$Inst_Prg$" $InstallDir64$
[Files_delete_32]
; Example of recursively copying some files into the installation directory:
;
delete /s "$InstallDir32$\*.*"
[Files_delete_64]
; Example of recursively copying some files into the installation directory:
;
delete /s "$InstallDir64$\*.*"
[Sub_check_exitcode]
comment "Test for installation success via exit code"
set $ExitCode$ = getLastExitCode
; informations to exit codes see
; http://msdn.microsoft.com/en-us/library/aa372835(VS.85).aspx
; http://msdn.microsoft.com/en-us/library/aa368542.aspx
if ($ExitCode$ = "0")
comment "Looks good: setup program gives exitcode zero"
else
comment "Setup program gives a exitcode unequal zero: " + $ExitCode$
if ($ExitCode$ = "1605")
comment "ERROR_UNKNOWN_PRODUCT 1605 This action is only valid for products that are currently installed."
comment "Uninstall of a not installed product failed - no problem"
else
if ($ExitCode$ = "1641")
comment "looks good: setup program gives exitcode 1641"
comment "ERROR_SUCCESS_REBOOT_INITIATED 1641 The installer has initiated a restart. This message is indicative of a success."
else
if ($ExitCode$ = "3010")
comment "looks good: setup program gives exitcode 3010"
comment "ERROR_SUCCESS_REBOOT_REQUIRED 3010 A restart is required to complete the install. This message is indicative of a success."
else
logError "Fatal: Setup program gives an unknown exitcode unequal zero: " + $ExitCode$
isFatalError
endif
endif
endif
endif
Code: Alles auswählen
[5] [29.08.2011 21:34:39] Execution of Winbatch_install_32
[6] [29.08.2011 21:34:39] Call "p:\install\avgantivirus\avg.exe /UILevel=silent /InstallToolbar=0 /ChangeBrowserSearchProvider=0 /InstallSidebar=0 /ParticipateProductImprovement=0 /DontRestart"
[6] [29.08.2011 21:34:39] Waiting until the called process is finished (HIER HABE ICH DIE INSTALLATION ABGEBROCHEN!)
[6] [29.08.2011 21:35:49] ExitCode 3758215212 Executed process "p:\install\avgantivirus\avg.exe /UILevel=silent /InstallToolbar=0 /ChangeBrowserSearchProvider=0 /InstallSidebar=0 /ParticipateProductImprovement=0 /DontRestart"
Danke.
Thomas_H