Skip to content

UpSync V2 command line options

Cristi Petruta edited this page May 6, 2022 · 1 revision

"pre-fetch"

Fetch categories from an upstream server and save them locally to a metadata source file. Must be run before fetching updates.

The upstream server endpoint is saved in the resulting file.

--master      : Fetch categories from the official Microsoft upstream server.

--endpoint    : Upstream server endpoint from where to sync categories.
                If not provided, --master is implied.

--destination : Destination file where to write the resulting metadata source file.
                If not set, a file name will be auto-generated in the current directory.

"fetch"

Fetch update metadata from an upstream server and save it to a metadata source file.

--baseline              : Required. An updates metadata source file that is the baseline.
                          For the first fetch, the baseline is the result of a pre-fetch operation.

--product-filter        : Limit syncs to a list of product IDs, separated by '+'
                          Effective only if the baseline is the result of a pre-fetch operation.

--classification-filter : Limit updates syncs to a list of classification IDs, separated by '+'
                          Effective only if the baseline is the result of a pre-fetch operation.

Notes

The upstream server endpoint is read from the baseline file.

Filters can be specified if the baseline used is the result of a pre-fetch - which does not contain any filters yet. If the baseline already contains a filter, the command line filters are ignored.

The fetch is incremental on the baseline source provided. The name of the resulting file is based on the name of the baseline file. If the baseline is master.zip, subsequent incremental files are automatically named master-1.zip, master-2.zip, etc.

Since these files are incremental changes from a baseline, lower versioned sources must exist when opening a higher versioned source. If renaming a file, all files in an incremental chain must be renamed, while keeping the version part of the name intact.

"fetch-content"

Download update content. You must fetch metadata for an update before downloading content for it.

--metadata-source       : The metadata source to use for update look-ups.

--destination           : Destination directory where to save content.    

--product-filter        : Limit syncs to a list of product IDs, separated by '+'

--classification-filter : Limit updates syncs to a list of classification IDs, separated by '+'

--id-filter             : Limit content sync to just files belonging to ids in this list.
                          '+' separated list of ids (GUID)

--title-filter          : Limit content sync to just updates that match this title (partial match).

--skip-superseded       : Do not download content for superseded updates.

--hwid-filter           : Limit content sync to driver updates that target this device hardware id

--computer-hwid-filter  : Limit content sync to driver updates that target this computer hardware id

--kbarticle-filter      : Content sync only updates that match any of the KBArticles on this list.
                          Numbers only, '+' separated

"status"

Print status information about a metadata source: upstream server source, filters used, timestamp of last sync, etc.

--source                : The metadata source to get status for.

"query":

Query updates, classifications, products, etc. in a local repository.

--source                : The metadata source to query

--products              : Limit the query to products metadata

--classifications       : Limit the query to classifications

--detectoids            : Limit the query to detectoids

--updates               : Limit the action to just update metadata (drivers or software updates)

--files                 : Query files.
                          When using this switch, only the id-filter and file-hash filters can be used.

--file-hash             : The hash of the file to look up.
                          Provide the hex string representation of the hash.

--product-filter        : Filter by a list of product IDs, separated by '+'
                          
--classification-filter : Filter by a list of classification IDs, separated by '+'

--id-filter             : Filter to a list of update IDs, separated by '+'

--title-filter          : Further filter to updates, categories, classifications or detectoids that match the
                          title (partial match)

--skip-superseded       : Filter out updates that have been superseded.

--count-only            : Count matched updates but do not display update information

--first                 : Display first x updates only

--hwid-filter           : Filter to driver updates that target this device hardware id

--computer-hwid-filter  : Filter to driver updates that target this computer hardware id

--kbarticle-filter      : Filter to software updates that match any KBArticle in this list
                          Numbers only, '+' separated

"export"

Export updates from a local repository (for importing in a WSUS instance)

--source                : The metadata source for export

--export-file           : The file to export updates to. You can use wusutil.exe on a WSUS server to import updates
                          from this file.
                    
--drivers               : Only export drivers. If not specified, all updates types are exported.

--product-filter        : Filter by a list of product IDs, separated by '+'
                          
--classification-filter : Filter by a list of classification IDs, separated by '+'

--id-filter             : Filter to a list of update IDs, separated by '+'

--title-filter          : Export updates that match this title

--hwid-filter           : Export only driver updates that target this device hardware id

--computer-hwid-filter  : Export only driver updates that target this computer hardware id

--kbarticle-filter      : Filter by a list of KBArticles
                          Numbers only, '+' separated

"run-upstream-server"

Run an upstream update server. Serves updates to downstream WSUS servers.

--source                : The metadata source to serve updates from.

--endpoint              : The host name or IP address to bind to.
                          If not provided, localhost is used.

--port                  : The port to bind the server to.
                          If not provided, defaults to 32150

--product-filter        : Filter updates served by a list of product IDs, separated by '+'
                          
--classification-filter : Filter updates served by a list of classification IDs, separated by '+'

--id-filter             : Filter updates served to a list of update IDs, separated by '+'

--title-filter          : Serve only updates that match this title

--hwid-filter           : Serve only driver updates that target this device hardware id

--computer-hwid-filter  : Serve only driver updates that target this computer hardware id

--kbarticle-filter      : Serve only updates that have a KBArticle in this list.
                          Numbers only, '+' separated

"match-driver"

Finds the best driver that matches a device by ID (and optionally a computer hardware ID) based on installed prerequisites.

This command is unwieldy since it requires a list of installed pre-requisites. To match on hardware ID and computer hardware ID without prerequisites, use the "query" command with --hwid-filter and --computer-hwid-filter options.

--source                  : The metadata source to match drivers from.

--hwid                    : The list of hardware IDs to match, in specific to generic order.
                            List of hardware IDs separated by '+' 

--computer-hwid           : The list of computer hardware IDs to match, in specific to generic order
                            List of computer hardware IDs (GUID) separated by '+'

--installed-prerequisites : List of installed prerequisites (GUIDs).
                            Each driver update has prerequisites that determine if its applicable
                            to a system. This list is used to check these prerequisites.