Installing Dependencies for Hue

Loading Filters ... 6.3.4 6.3.3 6.3.1 6.3.0 6.2.1 6.2.0 6.1.1 6.1.0 6.0.1 6.0.0 5.16 5.15 5.14 5.13 5.12 5.11 5.10 5.9 5.8 5.7 5.6 5.5 5.4 5.3 5.2 5.1 5.0 6.3.4 6.3.3 6.3.2 6.2.1 6.2.0 6.1.1 6.1.0 6.0.1 6.0.0 5.16 5.15 5.14 5.13 5.12 5.11 5.10 5.9 5.8 5.7 5.6 5.5 5.4 5.3 5.2 5.1 5.0

This page is only required when upgrading to CDH 6 or higher and one of the following is true:

  • Hue is installed on a RHEL 6 or compatible host.
  • Hue is using PostgresSQL.

(RHEL 6 Compatible Only) Install Python 2.7 on Hue Hosts

Hue in CDH 6 requires Python 2.7.5 or lower, which is included by default in RHEL 7 compatible operating systems (OSes).

RHEL 6
  1. Make sure that you have access to the Software Collections Library. For more information, see the Red Hat knowledge base article, How to use Red Hat Software Collections (RHSCL) or Red Hat Developer Toolset (DTS)?.
  2. Install Python 2.7.5:
    sudo yum install python275
  3. Verify that Python 2.7.5 is installed:
    source /opt/rh/python27/enable
    python --version
CentOS 6
  1. Enable the Software Collections Library:
    sudo yum install centos-release-scl
  2. Install the Software Collections utilities:
    sudo yum install scl-utils
  3. Install Python 2.7.5:
    sudo yum install python27
  4. Verify that Python 2.7.5 is installed:
    source /opt/rh/python275/enable
    python --version
Oracle Linux 6
  1. Download the Software Collections Library repository:
    sudo wget -O /etc/yum.repos.d/public-yum-ol6.repo http://yum.oracle.com/public-yum-ol6.repo
  2. Edit /etc/yum.repos.d/public-yum-ol6.repo and make sure that enabled is set to 1, as follows:
    [ol6_software_collections]
    name=Software Collection Library release 3.0 packages for Oracle Linux 6 (x86_64)
    baseurl=http://yum.oracle.com/repo/OracleLinux/OL6/SoftwareCollections/x86_64/
    gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-oracle
    gpgcheck=1
    enabled=1

    For more information, see Installing the Software Collection Library Utility From the Oracle Linux Yum Server in the Oracle documentation.

  3. Install the Software Collections utilities:
    sudo yum install scl-utils
  4. Install Python 2.7.5:
    sudo yum install python27
  5. Verify that Python 2.7.5 is installed:
    source /opt/rh/python27/enable
    python --version

Installing the psycopg2 Python Package

Hue in CDH 6 requires version 2.5.4 or higher of the psycopg2 Python package for connecting to a PostgreSQL database. The psycopg2 package is automatically installed as a dependency of Cloudera Manager Agent, but the version installed is often lower than 2.5.4.

If you are installing or upgrading to CDH 6 and using PostgreSQL for the Hue database, you must install psycopg2 2.5.4 or higher on all Hue hosts as follows. These examples install version 2.7.5 (2.6.2 for RHEL 6):

RHEL 7 Compatible
  1. Install the python-pip package:
    sudo yum install python-pip
  2. Install psycopg2 2.7.5 using pip:
    sudo pip install psycopg2==2.7.5 --ignore-installed
RHEL 6 Compatible
  1. Make sure that you have installed Python 2.7. You can verify this by running the following commands:
    source /opt/rh/python27/enable
    python --version
  2. Install the python-pip package:
    sudo yum install python-pip
  3. Install the postgresql-devel package:
    sudo yum install postgresql-devel
  4. Install the gcc* packages:
    sudo yum install gcc*
  5. Install psycopg2 2.6.2 using pip:
    sudo bash -c "source /opt/rh/python27/enable; pip install psycopg2==2.6.2 --ignore-installed"
Ubuntu / Debian
  1. Install the python-pip package:
    sudo apt-get install python-pip
  2. Install psycopg2 2.7.5 using pip:
    sudo pip install psycopg2==2.7.5 --ignore-installed
SLES 12
Install the python-psycopg2 package:
sudo zypper install python-psycopg2