add prefetch item

Adds a download item to the prefetch queue. This command must reside between a begin prefetch block and an end prefetch block command. This command can specify multiple downloads separated by semicolons.

The IBM BigFix Server caches the download when the action is created, unless relevance substitution is employed.IBM BigFix Relays only collect those files that the Clients request, and the Clients only request a file if the command is inside a TRUE condition block.

Instead of listing the download items in the command line, you can put them in a file (one item per line) and then use a relevance substitution like the following:

{concatenation ";" of lines of file <your file>}

This is a common usage when specifying a file in a Fixlet site that contains the download information.

add prefetch item [name=<n>] sha1=<h1> sha256=<h2> size=<s> url=<u> [; ...]

Where:

<n>
Is an optional name, limited to alphanumeric, dashes, underlines and non-leading period characters. If no name is explicitly specified, the name will be derived from the final component of the URL (following the final slash).
<h1>
Is the required sha1 for the specified file.
<h2>
Is the required sha256 for the specified file.
<s>
Is the required file size.
<u>
Is a required url. If the name is not specified, then it will be derived from final component of the supplied URL.
[; ...]
Denotes that the command is plural; extra files can be specified, with each separated by a semicolon.

Relevance substitution is allowed with the arguments of this command; however when substitution is used, the IBM BigFix server cannot cache the download item at action creation time.

The arguments may be in any order desired, and unrecognized arguments will be ignored.

When used without relevance substitution, IBM BigFix clients and relays will collect these files by actionID and ordinal. When used with relevance substitution, clients and relays will collect these files by URL and SHA hash algorithm. To specify a download without specifying the SHA hash algorithm, use the add nohash prefetch item command.

Example

begin prefetch block
      if {name of operating system = "Windows 2000"}
            add prefetch item {"name=up.exe sha1=12 size=45 url=http://ms.com
               /hot2k.exe"}
      else
            add prefetch item {"name=up.exe sha1=12 size=45 url=http://ms.com
               /hot.exe"}
      endif
end prefetch block
wait {download path "up.exe"}

This example demonstrates a conditional download in a prefetch block. By checking the OS first, only the proper file will be prefetched, potentially saving considerable time and bandwidth.

Version 7.2 and above