RFC: disable WSUS and Windows 10 updates (my first package. Alpha!)
Verfasst: 22 Jul 2019, 11:30
Hello,
I am new to OPSI packaging and build a really simple package and now I would like to get comments and suggestions on how to do it better or nicer. All the experts here will probably not like what I did, but it kind of works for me. The other solutions to this problem had issues.
It disables the WSUS key and runs Windows 10 Update, but it looks really ugly.
All I have right now is this setup.opsiscript:
I would like to add a nice text and maybe a logo, a working progress bar would be nice ... but probably hard. Any hints?
I am new to OPSI packaging and build a really simple package and now I would like to get comments and suggestions on how to do it better or nicer. All the experts here will probably not like what I did, but it kind of works for me. The other solutions to this problem had issues.
It disables the WSUS key and runs Windows 10 Update, but it looks really ugly.
All I have right now is this setup.opsiscript:
Code: Alles auswählen
[Actions]
DosInAnIcon_batch
[DosInAnIcon_batch]
@echo off
setlocal
rem wsus-client-delete.cmd
rem
rem (c) 2009 c't & Lars Titze
rem
echo Auto-Update-Dienst anhalten
"%windir%\system32\net.exe" stop "wuauserv" || (
echo Bitte starten Sie das Skript mit Adminstartorrechten.
pause
exit /b 2
)
echo Registry-Datei erzeugen
(
echo Windows Registry Editor Version 5.00
echo [-HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate]
echo [-HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU]
) > "%temp%\wsus-client-delete.reg"
echo Registy anpassen
"%windir%\Regedit.exe" /s "%temp%\wsus-client-delete.reg"
if ""=="%debug%" (
echo Registry-Datei entfernen
erase "%temp%\wsus-client-delete.reg"
)
echo Auto-Update-Dienst starten
"%windir%\system32\net.exe" start "wuauserv"
REM These two commands do not need a path
usoclient ScanInstallWait
usoclient StartInstall
REM Wait 40 mins to allow all the installs to complete
timeout /T 2400
ShutdownWithUpdates.exe /r /f