Preparing the configuration file for Ubuntu and Debian


The first step is to prepare the configuration file, which contains information (XML) that is used by the Patch Downloader utility. The configuration file must contain the download settings and patch filter information as show in the image below. You can also enter proxy server information if you are using one.


Debian config.png
Edit the sample XML configuration file (sample-debian-downloader-config.xml) provided by BMC, and add the following XML tags based on your requirements:

  1. (Optional) Add proxy information using the following XML tags:

    Example of proxy information in configuration file
    <proxy-settings>
    <port>8080</port>
    <host>127.0.0.1</host>
    <username>user</username>
    <password>password</password>
    <domain-name></domain-name>
    <proxy-type>ntlm</proxy-type>
    <protocol>http</protocol>
    </proxy-settings>
  2. Define download settings using the following XML tags:

    Example of download settings in configuration file
    <temporary-location>c:\tmp</temporary-location>
    <payload-repository-location>c:\tmp\Ubuntu</payload-repository-location>
    <download-request-retries>3</download-request-retries>
    <download-request-timeout>180000</download-request-timeout>
    <downloader-parallel-threads>50</downloader-parallel-threads> 

  3. Obtain a distribution list for Ubuntu and Debian using the following command. You can use this information when updating the configuration file with patch filter information in the next step.

    On a UNIX machine: sh debian_downloader.sh -listDists 

    On a Windows machine:{{code language="none"}}
     debian_downloader.bat -listDists
    {{/code}}


  4. Specify filters to limit the patches downloaded in the catalog. The same filters entered here must also be entered during catalog creation.

    Enter the following command to automatically add the filter information to the configuration file.


    If you are running on a UNIX machine:

    debian_downloader.sh  
    -addAptRepository
    -configFile <configFile>
    -debian <flavor>
    -osVersion <version>
    -debArch <arch>
    -debRepo <baseURL>
    <Distribution> <Component1>
    <Component2> ... <Component n>

    If you are running on a Windows machine:

    debian_downloader.bat
    -addAptRepository
    -configFile <configFile>
    -debian <flavor>
    -osVersion <version>
    -debArch <arch>
    -debRepo <baseURL>
    <Distribution> <Component1>
    <Component2> ... <Component n>


    The [confluence_table-plus] macro is a standalone macro and it cannot be used inline.

    Sample command for adding a filter to the configuration file:

    debian_downloader.bat
    -addAptRepository
    -configFile <configFile>
    -debian Ubuntu
    -osVersion 14.04
    -debArch x86
    -debRepo http://archive.ubuntu.com/ubuntu/dists/ trusty Main Restricted


    XML code of filter information appended to the <configFile>
    <subscriptions>

     <debian-update arch="x86" version="14.04" os="Ubuntu">
           <base-url>http://archive.ubuntu.com/ubuntu/</base-url>
           <distribution-list>
              <distribution name="trusty">
                 <component name="Main" /> <component name="Restricted">
                    <metadata-url> http://archive.ubuntu.com/ubuntu/dists/trusty/restricted/binaryi386/Packages.gz</metadata-url>
                    <base-payload-url> http://archive.ubuntu.com/ubuntu/
                    </base-payload-url>
                  </component>
                </distribution>
             </distribution-list>
    </debian-update>

    </subscriptions>
  5. Save the configuration file. Use the sample configuration file below as a reference:

    Click Expand source to see a sample configuration XML file
    <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
    <debian-downloader-configuration>

    <config>
    <proxy-settings>
    <port>8080</port>
    <host>127.0.0.1</host>
    <username>user</username>
    <password>password</password>
    <domain-name></domain-name>
    <proxy-type>ntlm</proxy-type>
    <protocol>http</protocol>
    </proxy-settings>
     
    <temporary-location>c:\tmp</temporary-location>
    <payload-repository-location>c:\tmp\Ubuntu</payload-repository-location>
    <download-request-retries>3</download-request-retries>
    <download-request-timeout>180000</download-request-timeout>
    <downloader-parallel-threads>50</downloader-parallel-threads>
       
    </config>

    <subscriptions>

        <debian-update arch="x86" version="14.04" os="Ubuntu">
           <base-url>http://archive.ubuntu.com/ubuntu/</base-url>
           <distribution-list>
              <distribution name="trusty">
                 <component name="Main" /> <component name="Restricted">
                    <metadata-url> http://archive.ubuntu.com/ubuntu/dists/trusty/restricted/binaryi386/Packages.gz</metadata-url>
                    <base-payload-url> http://archive.ubuntu.com/ubuntu/</base-payload-url>
                 </component>
              </distribution>
           </distribution-list>
        </debian-update>

    </subscriptions>

    </debian-downloader-configuration>

 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*