Using an Internal Parcel Repository

You can create a parcel repository for Cloudera Manager by either hosting an internal repository or by manually copying the repository files to the Cloudera Manager host.

Hosting an Internal Parcel Repository

To host an internal repository, you must install or use an existing web server on an internal host that is reachable by the Cloudera Manager host, and then download the repository files to the web server host.

Installing a Web Server

The repository is typically hosted using HTTP on a host inside your network. If you already have a web server in your organization, you can skip to Downloading and Publishing the Parcel Repository.

An easy web server to install is the Apache HTTP Server.

Install Apache HTTP Server

You may need to respond to some prompts to confirm you want to complete the installation.
OS Command
RHEL compatible sudo yum install httpd
SLES sudo zypper install httpd
Ubuntu sudo apt-get install httpd

Starting Apache HTTPD

OS Command
RHEL compatible sudo service httpd start
SLES sudo service apache2 start
Ubuntu sudo service apache2 start

Downloading and Publishing the Parcel Repository

  1. Download the parcel and manifest.json files for your OS distribution from:
    • CDH 5: Impala, Kudu, Spark 1, and Search are included in the CDH parcel.
      • CDH - https://username:password@archive.cloudera.com/p/cdh5/parcels/
      • Accumulo - - https://username:password@archive.cloudera.com/p/accumulo-c5/parcels/
      • GPL Extras - https://username:password@archive.cloudera.com/p/gplextras5/parcels/
    • CDS 2 Powered by Apache Spark for CDH 5:
      • The exact parcel name is dependent on the OS. You can find all the parcels at https://username:password@archive.cloudera.com/p/spark2/parcels/.
    • Cloudera Navigator Key Trustee Server:
      • Go to the Key Trustee Server download page. Select Parcels from the Package or Parcel drop-down menu, and click DOWNLOAD NOW. This downloads the Key Trustee Server parcels and manifest.json files in a .tar.gz file. Extract the files with the tar xvfz filename.tar.gz command.
    • Cloudera Navigator Key Trustee KMS and HSM KMS: (Cloudera Navigator HSM KMS is included in the Key Trustee KMS parcel).
      • Go to the Key Trustee KMS download page. Select Parcels from the Package or Parcel drop-down menu, and click DOWNLOAD NOW. This downloads the Key Trustee KMS parcels and manifest.json files in a .tar.gz file. Extract the files with the tar xvfz filename.tar.gz command.
    • Sqoop Connectors:
      • https://archive.cloudera.com/sqoop-connectors/parcels/
  2. Move the .parcel and manifest.json files to the web server directory, and modify the file permissions. The hosted .sha1 files are not used by Cloudera Manager when it obtains the parcels from a web server. Instead, it extracts the SHA1 hashes provided in manifest.json. For example:
    sudo mkdir -p /var/www/html/cloudera-parcels/cdh5/<cdh5_version>/
    sudo mv *.parcel* /var/www/html/cloudera-parcels/cdh5/<cdh5_version>/
    sudo mv manifest.json /var/www/html/cloudera-parcels/cdh5/<cdh5_version>/
    sudo chmod -R ugo+rX /var/www/html/cloudera-parcels/cdh5/<cdh5_version>/
    Replace <cdh5_version> with your CDH version (for example, 5.14.0). After moving the files and changing permissions, visit http://<web_server>/cloudera-parcels/cdh5/<cdh5_version> to verify that you can access the parcel. If you do not see anything, your web server may have been configured to not show indexes.

Configuring the Cloudera Manager Server to Use the Parcel URL for Hosted Repositories

  1. Use one of the following methods to open the parcel settings page:
    • Navigation bar
      1. Click in the top navigation bar or click Hosts and click the Parcels tab.
      2. Click the Configuration button.
    • Menu
      1. Select Administration > Settings.
      2. Select Category > Parcels .
  2. In the Remote Parcel Repository URLs list, click the addition symbol to open an additional row.
  3. Enter the path to the parcel. For example: http://<web_server>/cdh5/<cdh5_version>
  4. Click Save Changes to commit the changes.

Using a Local Parcel Repository

To use a local parcel repository, complete the following steps:
  1. Open the Cloudera Manager web UI and navigate to the Parcels page.
  2. Select Configuration and verify that you have a Local Parcel Repository path set. By default, the directory is /opt/cloudera/parcel-repo.
  3. Remove any Remote Parcel Repository URLs you are not using, including ones that point to Cloudera archives.
  4. Add the parcel you want to use to the local parcel repository directory that you specified.
  5. In the command line, navigate to the local parcel repository directory.
  6. Create a SHA1 hash for the parcel you added and save it to a file named <parcel_name>.parcel.sha.
    For example, the following command generates a SHA1 hash for the parcel CDH-5.14.0-1.cdh5.14.0.p0.24-el7.parcel:
    sha1sum CDH-5.14.0-1.cdh5.14.0.p0.24-el7.parcel | awk '{ print $1 }' > CDH-5.14.0-1.cdh5.14.0.p0.24-el7.parcel.sha
  7. Change the ownership of the parcel and hash files to cloudera-scm:
    sudo chown cloudera-scm:cloudera-scm *.parcel.*
  8. In the Cloudera Manager web UI, navigate to the Parcels page.
  9. Click Check for New Parcels.
  10. When the new parcel appears, download, distribute, and activate the parcel.