Deutsch (DE-CH-AT)English (United Kingdom)

Download

WuInstall Download
1.2 Pro

Download

get full version

1.1 Free Download

License information:WuInstall 1.1. is freeware.For detailled infos about WuInstall 1.2. Pro pricing, please use our license calculator. See also WuInstall ProLicense agreement

Facebook Badge

WuInstall Documentation

Basic Options

/search

Available in: all WuInstall Versions

Searches for available updates using the windows update API. If no criteria (see /criteria) is specified, it searches for not already installed updates (IsInstalled=0 and Type='Software'). Drivers are not included in the default /search option!

If the use of a WSUS is configured (this is the case when HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU\UseWUServer is set to 1), it uses the configured WSUS Server (which is set with HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\WUServer\) to get the list of updates matching the criteria. Otherwise (when UseWUServer is set to 0), it goes directly to the Microsoft Update Site.

If there is a WSUS Server configured, WuInstall will report for example:

You are using WSUS Server http://wsus.mycompany.local:8530
Otherwise, when going to the Microsoft Update Site, it will report:
You have no WSUS Server configured
It is possible to temporarily set, reset or change the use of a WSUS for the execution time of WuInstall, see /bypass_wsus and /use_wsus.


The search for updates will start with the message

Searching for updates ... Criteria: IsInstalled=0 and Type='Software'
and will ask either the WSUS or the Microsoft Update Site for a list of available updates matching the criteria. If the criteria is invalid, WuInstall will print "Invalid criteria" and exits here, returning code 4.


Sometimes, the search might fail for some reason, in case of an error WuInstall tries the search automatically a second time. If the search fails once more, WuInstall exits with return code 1 and also displays the error code for the reason why the search failed:

Search failed ... retrying ...Search failed 2 times.
Result CODE: 0x0 0x8024402C - The proxy server or target server name cannot be resolved.

If the search was successful, WuInstall types:

Result Code: Succeeded

If no updates were found, it will report:

No Updates are available, nothing to do!
and exit with return code 2.


If updates were found, it will display the total number of updates found:

10 Updates found in total, filtering ...
Now, the updates are filtered, if there are filters specified. For details on filtering see the following options: /severity, /classification, /product, /match, /nomatch, /matchfile, /nomatchfile, /isdownloaded


If no update matches the filters, WuInstall will report:

No Updates available for specified match string / severity / product!
and exit with return code 3.


When there are updates which match the filters they are displayed in a result list like this:

1.  Definition Update for Microsoft Forefront Client Security - KB977939 (Definition 1.87.1797.0)
 Severity: Unknown
 UpdateClassification - Definition Updates
 Product - Forefront Client Security
The first line contains the position and the complete name of the update, afterwards the severity, classification and product are displayed.


When using the /search option, after listing the updates, WuInstall exits with code 0, without any further action.

only /search was specified, stopping here!
So this option is useful for just checking which updates are available (and, for example, with the criteria "IsInstalled=1" also for checking which updates are already installed) or for testing search criterias and filter options before downloading and installing.

/download

Available in: all WuInstall Versions

The /download option first of all executes a search (exactly the same one the /search option does, considering all parameters for criterias and filters).

If there are entries in the result list (updates, matching the criterias and filters, were found), it immediately starts downloading them (either from WSUS or the Microsoft Update Site), displaying:

Downloading updates ...
The updates are downloaded in exactly the same order in which they are displayed after the search.


When starting the download, WuInstall displays:

Downloading Definition Update for Microsoft Forefront Client Security - KB977939 (Definition 1.87.608.0):
It is possible to track the download progress (see the /show_progress option).


Updates, which already have been downloaded (they can be excluded in the result list of the search with the /isdownloaded option), are usually not downloaded again, so the download is "finished" immediately.

WuInstall usually (depending on OS version and system configuration) caches the downloads in the directory Windows\SoftwareDistribution\Download. Using the /download_to option instead of /download, it is also possible to put exe / msi of the downloaded updates to a certain directory for manual installation.

When the download of an update fails for some reason, WuInstall displays

Download failed!
and the error code and reason why the download failed. WuInstall then immediately exits with return code 1 without downloading the subsequent pending downloads in the result list.


When all updates in the result list have been successfully downloaded, WuInstall displays

Downloading finished, listing downloaded updates and counting...
Result Code: Succeeded
only /download was specified, stopping here
and exits with return code 1.

/download_to directory

Available in: WuInstall Pro

It does almost exactly the same as /download, but furthermore this option copies the updates to the specified directory, usually in msi or exe format.

These updates can be installed manually afterwards.

After downloading an update to the update cache (usually Windows\SoftwareDistribution\Download), WuInstall displays for example

Copying download to c:\my_updates...
and displays an "OK" if successful, otherwise an error code.

Most updates are update bundles, which means there are multiple sub-updates, each will create a separate installation file in the directory.

WuInstall will display for each bundle:

Copying bundle .NET 4 Client x86 (Win7)  ....  OK

With update bundles it is quite likely to have more installation exe / msi files than updates.

If copying an update file to a directory fails, WuInstall just displays the error code like this:

Copying bundle Microsoft .NET Framework 4 Client Profile Language Packs x86  .... Error: 0x80246007
but it does not force WuInstall to abort the entire process, it continues with the next update in the result list (or the next sub-update in the bundle) in any case.


The option /download_to can also be used to copy updates which are already in the download cache to a directory (with /isdownloaded 1).

/install

Available in: all WuInstall Versions

This option first executes exactly the same as /download (=searching and downloading updates) and then starts installing the downloaded updates.

Before installation, the downloaded updates are listed and checked if they have been downloaded properly and if they are ready to be installed. Furthermore, it is listed if the Eula is known ("Eula Accepted: true") - otherwise, see /autoaccepteula option.

This looks for example like this:

Install was specified. Beginning Install
   Portuguese (Brazil) Language Pack - Windows 7 (KB972813), Eula Accepted: true
   Danish Language Pack - Windows 7 (KB972813), Eula Accepted: true
1 Updates are ready to be installed!
Beginning install ...

Now, the installation starts, all updates are installed in one single step. It is possible to track the installation progress (see the /show_progress option).

If the installation fails for some reason, WuInstall prompts

Install failed!
and immediately exits with code 1 and shows the error code.


In case the installation ran through, WuInstall enumerates the result for every single update and finally the overall result code:

Enumerating result for every single update
 1. Portuguese (Brazil) Language Pack - Windows 7 (KB972813): Result Code: Succeeded
 2. Danish Language Pack - Windows 7 (KB972813): Result Code: Succeeded
Overall Result Code: Succeeded

Afterwards, it is checked if one or more updates need a reboot.

Install or Download finished, reboot required: NO´
If yes, WuInstall exits with code 10, otherwise with code 0.

/uninstall

Available in: WuInstall Pro

This option uninstalls updates from a machine.

The /uninstall option automatically searches for already installed updates offline (see /offline option) with the criteria "IsInstalled=1" and uninstalls them. All filter options (e.g. /match, /product, /severity, ...) are available to specifically select updates to be uninstalled.

Typing just WuInstall /uninstall without any filter options is not advised!

For example, to uninstall KB2251419 use: wuInstall /uninstall /match KB2251419

You are using WSUS Server http://mywsus.local:8530

Searching offline for already installed updates...

Searching for updates ... Criteria: (IsInstalled=1)
Result Code: Succeeded

96 Updates found in total, filtering ...
Listing those matching search expression:  'KB2251419'


1. Security Update for Microsoft Office Word 2007 (KB2251419)
 Severity: Critical
 Product - Office 2007
 UpdateClassification - Security Updates

 Uninstalling Updates ... Successful
Enumerating result for every single update
 1. Security Update for Microsoft Office Word 2007 (KB2251419): Result Code: Succeeded

Overall Result Code: Succeeded

The /uninstall option only works with updates which have been installed using a WSUS.

Otherwise it usually gives the error code 0x80240028 - WU_E_UNINSTALL_NOT_ALLOWED (The update could not be uninstalled because the request did not originate from a WSUS Server).

There are also some updates which fail to be uninstalled with WuInstall because of internal dependencies.

Reboot / Shutdown options

/reboot [nseconds]

Available in: all WuInstall Versions

This option initiates a system reboot with a delay of the specified number of seconds (nseconds) after the execution of WuInstall.

If no time is specified, 10 seconds are used by default.

At the start of WuInstall execution, the message

/reboot specified, system reboots after WuInstall with 10 seconds delay
is displayed. WuInstall is executed according to the specified parameters (also, just WuInstall /reboot alone is possible), and after the execution of WuInstall, the message
Rebooting after 10 seconds ...
is displayed. WuInstall exits with return code 5 and the system will reboot after the specified delay in ANY CASE, regardless of the outcome of WuInstall.


If initiating the reboot fails for some reason, the error code is displayed

Reboot failed, Error Code: 1271
and WuInstall exits with code 6.

/reboot_if_needed [nseconds]

Available in: WuInstall Pro

Does exactly the same as /reboot, the only difference is that a reboot is triggered only when a reboot is required (when it exits with a return code 1 or 11).

If a reboot is needed, the /reboot_if_needed options generates the output

reboot_if_needed specified, rebooting

If no reboot is needed, WuInstall puts:

no reboot needed, so system will not reboot ...

/shutdown [nseconds]

Available in: WuInstall Pro

/shutdown is similar to /reboot, but instead of rebooting the system, it shuts down. The default number of the the delay seconds is 10, and the shutdown is done in ANY CASE, regardless the result of WuInstall.

At the beginning of WuInstall it is displayed:

/shutdown specified, system system shuts after WuInstall with 10 seconds delay

And when WuInstall has finished

Shutdown after 10 seconds ...

If the shutdown was initiated successfully, WuInstall exits with code 5, otherwise it displays an error code and exits with code 6.

Caching Options

/install_cache cache_dir

Available in: WuInstall Pro

This feature uses a shared cache directory to prevent machines in a local network from downloading updates more than once.

The /install_cache option first of all executes the online search (exactly the same one as the /search option does, considering all parameters for criterias and filters).

The parameter cache_dir should be a folder on a local network share where multiple machines have access to.

Before downloading the updates from the result list, WuInstall checks in the cache_dir if the update has already been downloaded there by another machine. If the update is not the cache folder, WuInstall downloads the update (from the configured download location - WSUS and/or windowsupdate.com) and puts it into the cache directory, in a subfolder which has the same name as the Update ID.

If the update is present in the folder (if there is a subdirectory with the Update ID), WuInstall tries do copy the update from this shared cache folder to the local update cache. If this fails for some reason, WuInstall deletes the subdirectory in the shared cache folder (because there is apparently something wrong with the update) and downloads the update directly from the Internet.

For example, the first machine calls:

wuInstall /install_cache p:\temp
and the update "Windows Malicious Software Removal Tool - August 2010 (KB890830)" is not yet present in the cache directory.
First of all, the cache is checked for a directory with the same name as the Update-ID (in this case 20110b11-6dd2-4153-a76d-e660ec78ebed), and the update is not found:
Checking cache for update: Windows Malicious Software Removal Tool - August 2010 (KB890830)
Update Windows Malicious Software Removal Tool - August 2010 (KB890830) Multi-Lingual - Delta not found in cache directory p:\temp\20110b11-6dd2-4153-a76d-e660ec78ebed

So, the update will be downloaded from the configured location (here, the Windows Update site) and copied into the cache folder:

Update bundle not found, downloading...
Copying downloads directly...
Downloading: http://download.windowsupdate.com/msdownload/update/software/uprl/2010/08/windows-kb890830-v3.10-delta_b6366a428af17c9c7c524ebd15aafe3608d3fa39.exe to p:\temp\20110b11-6dd2-4153-a76d-e660ec78ebed/windows-kb890830-v3.10-delta_b6366a428af17c9c7c524ebd15aafe3608d3fa39.exe ... 
OK
Download OK

After the download is finished, WuInstall checks the cache again and finds the just downloaded update there and copies it to the local cache of the machine (the local cache is usually following directory: Windows\SoftwareDistribution\Download)

Checking cache again...
Update Windows Malicious Software Removal Tool - August 2010 (KB890830) Multi-Lingual - Delta found in cache directory, copying to local cache... OK

After that, the download of the update is finished and it is installed.

Later, another machine (which also needs the KB890830 update) also calls:

wuInstall /install_cache p:\temp

Now, the update is present in the cache directory and is copied from there without downloading it from the Internet or WSUS Server (which apparently saves a lot of Internet bandwidth since the cache directory is in the local network):

Checking cache for update: Windows Malicious Software Removal Tool - August 2010 (KB890830)
Update Windows Malicious Software Removal Tool - August 2010 (KB890830) Multi-Lingual - Delta found in cache directory, copying to local cache...
OK

/download_cache cache_dir

Available in: WuInstall Pro

This option does the same as /install_cache, but only downloads the updates, without installing them (which can be used for example to populate the cache with updates, without installing them).

Criteria Options

/criteria "query string"

Available in: all WuInstall Versions

Specifies the criteria with which the updates are searched on the server (Windows Update Site or WSUS).

If no criteria is specified, WuInstall searches by default for software (no drivers!) which has not yet been installed. So the default criteria is: IsInstalled=0 and Type='Driver'.

When an invalid criteria was specified, the search fails and WuInstall exits with code 4.

Invalid criteria !

When the criteria was valid, e.g. when you type wuInstall /search /criteria "IsInstalled=1", WuInstall displays

Searching for updates ... Criteria: IsInstalled=1
and includes only updates in the result list, which match this criteria.


For more details on criteria see http://msdn.microsoft.com/en-us/library/aa386526%28VS.85%29.aspx

/driveronly

Available in: WuInstall Pro

Searches only for drivers which have not yet been installed. Equivalent to the criteria (IsInstalled=0 and Type='Driver').

/includedriver

Available in: WuInstall Pro

Searches for software and drivers which have not yet been installed. Equivalent to criteria (Type='Software' and IsInstalled=0) or (Type='Driver' and IsInstalled=0)

/alltypes

Available in: WuInstall Pro

Searches for all types of updates which have not yet been installed. Equivalent to criteria (IsInstalled=0).

Filter Options

/classification update_classification

Available in: WuInstall Pro

Each update has a certain classification. It is possible to filter results of a search (which match the specified criteria) by classifications.

Classifications are:

  • Critical Updates: Broadly released fixes for specific problems addressing critical, non-security related bugs.
  • Updates: Broadly released fixes for specific problems addressing non-critical, non-security related bugs.
  • Update Rollups: Cumulative set of hotfixes, security updates, critical updates, and updates packaged together for easy deployment. A rollup generally targets a specific area, such as security, or a specific component, such as Internet Information Services (IIS).
  • Security Updates: Broadly released fixes for specific products, addressing security issues.
  • Service Packs: Cumulative sets of all hotfixes, security updates, critical updates, and updates created since the release of the product. Service packs might also contain a limited number of customer-requested design changes or features.
  • Feature Packs: New feature releases, usually rolled into products at the next release.
  • Definition Updates: Updates to virus or other definition files.

You can combine classifications by just combining the letters:
C (Critical Updates)
U (Updates)
R (Update Rollups)
S (Security Updates)
E (Service Packs)
F (Feature Packs)
D (Definition Updates)

For example WuInstall /search /criteria "IsInstalled=1" /classification CRSE generates the following output:

Searching for updates ... Criteria: IsInstalled=1
Result Code: Succeeded

96 Updates found in total, filtering ...
Listing those matching following classifications:
Critical Updates
Update Rollups
Security Updates
Service Packs

/severity severity_level

Available in: WuInstall Pro

Each security update has a certain severity level. It is possible to filter results of a search (which match the specified criteria) by severity levels.

Severity levels are:

  • Critical: A security issue whose exploitation could allow the propagation of an Internet worm without user action.
  • Important: A security issue whose exploitation could result in compromise of the confidentiality, integrity, or availability of users' data, or of the integrity or availability of processing resources.
  • Moderate: Exploitation is mitigated to a significant degree by factors such as default configuration, auditing, or difficulty of exploitation.
  • Low: A security issue whose exploitation is extremely difficult, or whose impact is minimal.
  • Unknown: all updates, which are not a security update.

You can combine severity levels by just combining the letters:
C (Critical)
I (Important)
M (Moderate)
L (Low)
U (Unknown)

So the command WuInstall /search /severity CIU filters the result list of the search to contain only updates with severity Critical, Important and Unknown:

Searching for updates ... Criteria: IsInstalled=0 and Type='Software'
Result Code: Succeeded

30 Updates found in total, filtering ...
Listing those matching following severities:
Critical
Important
Unknown

/product "product_name"

Available in: WuInstall Pro

Each update belongs to a product (for example Office 2007, Windows 7, Forefront Client Security, ...). It is also possible to filter results of a search (which match the specified criteria) by a product name.

No wildcards are possible, the product name has to be an exact match. Currently, you can only filter one product.

So for example the command wuInstall /search /criteria IsInstalled=1 /product "Forefront Client Security" gives the following output:

Searching for updates ... Criteria: IsInstalled=1
Result Code: Succeeded

96 Updates found in total, filtering ...
Listing product:  'Forefront Client Security'

/match "regexp"

Available in: all WuInstall Versions

This option filters each update in the result list if the title of an update matches the search string specified with the regexp parameter (in WuInstall Pro, also regular expressions are possible).

You can search, for example, just for all updates matching KB890830 with: WuInstall /search /match KB890830 /criteria IsInstalled=1

Searching for updates ... Criteria: IsInstalled=1
Result Code: Succeeded

96 Updates found in total, filtering ...
Listing those matching search expression:  'KB890830'


1. Windows Malicious Software Removal Tool - August 2010 (KB890830)
 Severity: Unknown
 UpdateClassification - Update Rollups
 Product - Windows 7

With using regular expressions, you can do some more complex queries. For a good explanation of regular expressions see http://www.cs.tut.fi/~jkorpela/perl/regexp.html

For example, searching for all updates that match "Internet Explorer 8", the Term "Language" or "KB89", you type:
WuInstall /search /match "(Language|KB93|Internet Explorer)"

Searching for updates ... Criteria: IsInstalled=1
Result Code: Succeeded

96 Updates found in total, filtering ...
Listing those matching search expression:  '(Language|KB89|Internet Explorer)'


1. Update for Microsoft Office Language Pack 2007 (for Office Outlook 2007 with
Business Contact Manager ) (KB946307)
 Severity: Unknown
 UpdateClassification - Critical Updates
 Product - Office 2007

2. Update for Internet Explorer 8 Compatibility View List for Windows 7 (KB98263
2)
 Severity: Unknown
 UpdateClassification - Updates
 Product - Windows 7

3. Update for Internet Explorer 8 Compatibility View List for Windows 7 (KB98266
4)
 Severity: Unknown
 UpdateClassification - Updates
 Product - Windows 7

4. Cumulative Security Update for Internet Explorer 8 for Windows 7 (KB2183461)

 Severity: Critical
 UpdateClassification - Security Updates
 Product - Windows 7

5. Windows Malicious Software Removal Tool - August 2010 (KB890830)
 Severity: Unknown
 UpdateClassification - Update Rollups
 Product - Windows 7

/nomatch "regex"

Available in: WuInstall Pro

This is quite the opposite of the /match option: it filters out all the updates that do match the regular expression and displays the rest (=the updates which do NOT match).

Obviously it is very useful for excluding certain updates.

For example, to filter out all updates that do not contain the words "Microsoft" or "Windows" (there are not many updates that do so ...) use:
WuInstall /search /criteria "IsInstalled=1" /nomatch (Windows|Microsoft)

Searching for updates ... Criteria: IsInstalled=1
Result Code: Succeeded

96 Updates found in total, filtering ...
Listing those NOT matching search expression:  '(Windows|Microsoft)'


1. MSXML 6.0 RTM Security Update  (925673)
 Severity: Critical
 UpdateClassification - Security Updates
 Product - SQL Server Feature Pack

2. Update for Business Contact Manager for Outlook 2007 (KB946140)
 Severity: Unknown
 UpdateClassification - Critical Updates
 Product - Office 2007

3. Security Update for SQL Server 2005 Service Pack 3 (KB970892)
 Severity: Critical
 UpdateClassification - Security Updates
 Product - SQL Server 2005

4. Update Rollup 10 for Exchange Server 2007 Service Pack 1 (KB981407)
 Severity: Unknown
 Product - Exchange Server 2007
 UpdateClassification - Update Rollups

Of course, /match and /nomatch can also be combined.

/matchfile file

Available in: WuInstall Pro

With the /matchfile option you can specify multiple /match parameters.

Just write the desired update matches (regular expressions are supported) into a file and specify this file as the matchfile.

For example, create the file "updateList.txt" with the following content:

Security State Assessment 1.0
KB963671
KB975467
.NET Framework 3.5 SP1 Security

The match entries are separated with a newline. The file has to be either in UTF-8, ANSI or DOS character set. UTF-16 is not supported.

WuInstall lists all the updates in the result list, which match AT LEAST ONE of the lines in the file.

If you type WuInstall /search /matchfile c:\updateList.txt, WuInstall gives for example the following result list:
95 Updates found in total, filtering ...
Listing those matching search expressions in file:  'c:\updateList.txt'


1. Update for Microsoft Script Editor Help (KB963671)
 Severity: Unknown
 Product - Office 2007
 UpdateClassification - Updates

2. Security Update for Windows 7 (KB975467)
 Severity: Important
 UpdateClassification - Security Updates
 Product - Windows 7

3. Definition Update for Microsoft Forefront Client Security (Security State Assessment 1.0.1710.103 Full)
 Severity: Unknown
 UpdateClassification - Definition Updates
 Product - Forefront Client Security

4. Microsoft .NET Framework 3.5 SP1 Security Update for Windows 7 x86 (KB979916)
 Severity: Important
 UpdateClassification - Security Updates
 Product - Windows 7

This option is useful when you keep a central list of updates to be rolled out on your machines in a shared directory (use this list as the matchfile).

/nomatchfile file

Available in: WuInstall Pro

/nomatchfile is quite the opposite of the /matchfile option: use it if you want to specify multiple /nomatch paramters (if you want to exclude a list of updates).

WuInstall lists all the updates in the result list, which match NONE of the lines in the file.

Just write the update matches that should be excluded (regular expressions are supported) into a file and specify this file as the nomatchfile.

For example, create the file "exclude.txt" with the following content:

Windows
Microsoft
925673
Office

The exclude entries are separated with a newline. The file has to be either in UTF-8, ANSI or DOS character set. UTF-16 is not supported.

If you type WuInstall /search /nomatchfile c:\exclude.txt, WuInstall puts out for example the following result list:

95 Updates found in total, filtering ...
Listing those NOT matching search expressions in file:  'c:\exclude.txt'


1. Update for Business Contact Manager for Outlook 2007 (KB946140)
 Severity: Unknown
 UpdateClassification - Critical Updates
 Product - Office 2007

2. Security Update for SQL Server 2005 Service Pack 3 (KB970892)
 Severity: Critical
 UpdateClassification - Security Updates
 Product - SQL Server 2005

3. Update Rollup 10 for Exchange Server 2007 Service Pack 1 (KB981407)
 Severity: Unknown
 Product - Exchange Server 2007
 UpdateClassification - Update Rollups

/isdownloaded 1|0

Available in: WuInstall Pro

This options filters updates which have already been downloaded to the local cache.

You can call for example WuInstall with the /download options combined with some filters to download all available updates:

30 Updates found in total, filtering ...
Listing those matching search expression:  'Greek'


1. Greek Language Pack - Windows 7 (KB972813)
 Severity: Unknown
 UpdateClassification - Updates
 Product - Windows 7 Language Packs

Downloading updates ...
Downloading Greek Language Pack - Windows 7 (KB972813):
and then later use:
WuInstall /install /isdownloaded 1
You will get following output:
30 Updates found in total, filtering ...
Listing only updated which are already downloaded


1. Greek Language Pack - Windows 7 (KB972813)
 Severity: Unknown
 UpdateClassification - Updates
 Product - Windows 7 Language Packs

Deleting updates manually from the local download cache (usually Windows\SoftwareDistribution\Download) might cause this option to work incorrectly, because even deleted they are still considered as downloaded.

WSUS Options

/bypass_wsus

Available in: WuInstall Pro

The bypass_wsus option bypasses any configured WSUS and forces WuInstall to access the Windows Update site.

If a WSUS is configured, WuInstall changes the registry key HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU, Value UseWuServer from 1 to 0, which means that no WSUS should be used.

If you type wuInstall /search /bypass_wsus and a WSUS is configured, the output is:

You are using WSUS Server http://mywsus.local:8530
bypass_wsus specified, bypassing WSUS ... successful!


After the execution of WuInstall, the initial state is restored by resetting the UsWuServer value to 1.

bypass_wsus specified, reactivating WSUS ... successful!

When the execution of WuInstall is aborted for some reason before WuInstall can reset the registry value, it have to be reset manually!

/use_wsus wsus_address

Available in: WuInstall Pro

The /use_wsus option works similar to the bypass_wsus option, but you can specifiy another WSUS which is valid during the execution of WuInstall (or it allows you to switch from no WSUS at all to a certain WSUS).

WuInstall manipulates the following registry keys:

  • HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU\UseWuServer: is set to 1
  • HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\WUServer: is set to the specified wsus_address
  • HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\WUStatusServer: is set to the specified wsus_address
and stores the initial values for resetting them after WuInstall has finished.


For example, if you have WSUS http://mywsus.local:8530 configured, and want to go to the WSUS http://mywsus2.local:8530, you type: wuInstall /search /use_wsus http://mywsus2.local:8530 and WuInstall puts out:

You are using WSUS Server http://mywsus.local:8530
use_wsus specified ....  WUServer and WUStatusServer successfully set to http://mywsus2.local:8530

After the execution of WuInstall, the initial state is restored (in this example, the WSUS is reset to http://mywsus.local:8530)

use_wsus specified, deactivating WSUS again
resetting  WUServer to http://mywsus.local:8530, WUStatusServer to http://mywsus.local:8530 ... successful!

When the execution of WuInstall is aborted for some reason before WuInstall can reset the registry values, they have to be reset manually!

Other Options

/autoaccepteula

Available in: WuInstall Pro

For some updates, an EULA (End-User License Agreement) has to be accepted by the user. With the option /autoaccepteula, all EULAs are accepted automatically before installing.

So the update installation works without any user interaction, the process can be completely unattended.

This works only when WuInstall is called by an Administrator or a power user account.

/logfile file-to-log

Available in: WuInstall Pro

This options logs the console output of WuInstall to the specified logfile (each output line also contains the current timestamp).

For example, to logg all already installed downloads:

WuInstall /search /criteria "IsInstalled=1" /logfile "c:\data\WuInstallLog.txt"
WuInstallLog.txt contains for example the following lines:
2010/08/24-08:10:37   Searching for updates ... Criteria: IsInstalled=1
2010/08/24-08:10:40  
2010/08/24-08:10:40 Result Code: Succeeded
2010/08/24-08:10:40   50 Updates found in total, filtering ...
2010/08/24-08:10:40   1. German Language Pack - Windows 7 (KB972813)   Severity: Unknown
2010/08/24-08:10:40   UpdateClassification - Updates  Product - Windows 7 Language Packs
2010/08/24-08:10:40   2. Windows Server Update Services 3.0 SP2 (KB972455)   Severity: Unknown
2010/08/24-08:10:40   UpdateClassification - Service Packs  Product - Windows 7
2010/08/24-08:10:40   3. French Language Pack - Windows 7 (KB972813)   Severity: Unknown
2010/08/24-08:10:40   UpdateClassification - Updates  Product - Windows 7 Language Packs

This option is obviously very useful when testing and debugging WuInstall scripts or when running WuInstall with a scheduled job or on remote machines.

/maxruntime minutes

Available in: WuInstall Pro

This option starts a timer with the specified number of minutes at the start of WuInstall and exits WuInstall (if it is not finished until the timer expires) with exit code 12. It exits at any case, no matter how far the execution WuInstall is.

For example, with /maxruntime 5, WuInstall exits after 5 minutes displaying

Maxruntime timeout elapsed: 5, exiting process!

This option is intended for machines, where downloads take a lot of time or machines which hang for some reason, to avoid WuInstall from running endlessly long.

Use this option with caution, especially when using the /use_wsus or /bypass_wsus options!

/simple_error

Available in: WuInstall Pro

With this option, WuInstall returns 0 for any success and 1 for any error, regardless of the reason.

Which means, if the return code would be 0, 2, 3, 5 or 10, WuInstall returns 0 and displays the message

Simple result specified, returning 0 for success!

In any other case (the remaining codes 1, 4, 6, 11, 12), WuInstall returns 1 and displays the message

Simple result specified, returning 1 for error!

/show_progress

Available in: WuInstall Proc

This option shows the progress for the download of every single update and the installation of the updates, using asynchronous downloads / installation.

On some machines under certain circumstances, the /show_progress option might cause problems, so use it only when manually testing scripts or searching for problems on a single workstation. It is not advised to use it in automated scripts on different workstations.

/offline

Available in: WuInstall Pro

This options makes WuInstall NOT connecting to the WSUS Server or Microsoft Update site when searching updates, instead it searches offline.

This option is quite useful for searching already installed updates. The criteria "IsInstalled=1" and the /uninstall option automatically trigger an offline search.

For example, check if the Update KB982214 is installed on a machine:

wuInstall /search /criteria "IsInstalled=1" /offline /match "KB982214"
/offline specified, searching offline...

Searching for updates ... Criteria: IsInstalled=1
Result Code: Succeeded

96 Updates found in total, filtering ...
Listing those matching search expression:  'KB982214'


1. Security Update for Windows 7 (KB982214)
 Severity: Important
 UpdateClassification - Security Updates
 Product - Windows 7

When not using IsInstalled=1, the search result list usually contains the updates found at the last online search.

Return Codes

0... successful, no reboot required
1... at least one error occured, no reboot required
2... no more updates availabe
3... no updates available that match your search (in combination with /severity, /classification, /product, /criteria, /match, /nomatch, /matchfile, /nomatchfile)
4... invalid criteria specified (in combination with /criteria)
5... reboot/shutdown initialized successful (in combination with /reboot or /shutdown)
6... reboot/shutdown failed (in combination with /reboot or /shutdown)
10... successful, reboot required
11... at least one error occured, reboot required
12... timeout reached (in combination with /maxtruntime)