The Hortonworks Community Connection is now live. A completely rebuilt Q&A forum, Knowledge Base, Code Hub and more, backed by the experts in the industry.

You will be redirected here in 10 seconds. If your are not redirected, click here to visit the new site.

The legacy Hortonworks Forum is now closed. You can view a read-only version of the former site by clicking here. The site will be taken offline on January 31,2016

Ambari Forum

Error in installattion using Ambari from a Local Repository

  • #47322
    Mitali Sodhi


    I am installing a four-node cluster using Ambari on CentOS6. I have built a local repository from where the packages can be downloaded. The local repository and the Ambari server are running on the master node in the cluster. These are the steps that I have followed till now:
    1. Set up a password-less ssh from the Ambari Server to rest of the nodes
    2. Installed and set up Apache httpd server
    3. Configured the local repository that is running on Apache httpd server. I followed the steps from here for setting up local repositories:
    Downloaded the three repos for Centos6(HDP, HDP-UTILS and Ambari)
    4. These repositories are successfully reflected on my Apache Server. Here are the details (on
    Index of /hdp

    5. Then, I download and edit the ambari.repo file accordingly. I copy this file to /etc/yum.repos.d/ folder of every node using scp. Here are the contents of it:
    name=Ambari 1.x

    name=Hortonworks Data Platform Utils Version - HDP-UTILS-

    name=Hortonworks Data Platform HDP-

    Since there were three .repo files (hdp.repo, ambari.repo and HDP.repo) so I change the baseurl in every file according to my web-server and place them in /etc/repos.d/ of each node.
    5. Then in the Ambari Installation Wizard, I fill the following entries at each step :
    a) Step 2: Install options: In this I give the URL of my local repository for CentOS6 as
    b) Step 3: Confir hosts : success on all 4
    c) Step 4: Choose services : Selected all
    d) Step 5,6,7,8 : Done
    e) Step 9 : Install, Start and Test:
    It is getting failed and I am getting this error :
    notice: Finished catalog run in 0.03 seconds err: /Stage[1]/Hdp::Snmp/Hdp::Package[snmp]/Hdp::Package::Process_pkg[snmp]/Package[net-snmp-utils]/ensure: change from absent to present failed: Execution of '/usr/bin/yum -d 0 -e 0 -y install net-snmp-utils' returned 1: Error Downloading Packages: 1:net-snmp-utils-5.5-49.el6.x86_64: failure: Packages/net-snmp-utils-5.5-49.el6.x86_64.rpm from base: [Errno 256] No more mirrors to try.

    Can anyone help me to solve this error?


  • Author
  • #47331
    Jeff Sposetti

    Do you have the base OS repos available? I believe that is where that package is available.

    What repos do you see from running “yum repolist”?

    Mitali Sodhi


    Yes, I have base OS repo available. This is what I get when on “yum repolist” :
    HDP-2.0.6 HDP
    HDP- Hortonworks Data Platform HDP-
    HDP-UTILS- Hortonworks Data Platform Utils Version – HDP-UTILS-1.1.
    amabari-1.x Ambari 1.x
    base CentOS-6 – Base
    extras CentOS-6 – Extras
    updates CentOS-6 – Updates

    Jeff Sposetti

    Thanks. What if you run “yum info net-snmp-utils”, it show that package available and in the base repo?

    Mitali Sodhi

    This is what I get on “yum info net-snmp-utils” :

    [root@node1 yum.repos.d]# yum info net-snmp-utils
    Loaded plugins: fastestmirror, security
    Loading mirror speeds from cached hostfile
    * base:
    * extras:
    * updates: [Errno 14] PYCURL ERROR 6 - "Couldn't resolve host ''"
    Trying other mirror. [Errno 14] PYCURL ERROR 6 - "Couldn't resolve host ''"
    Trying other mirror. [Errno 14] PYCURL ERROR 6 - "Couldn't resolve host ''"
    Trying other mirror.
    Trying other mirror.
    Available Packages
    Name : net-snmp-utils
    Arch : x86_64
    Epoch : 1
    Version : 5.5
    Release : 49.el6
    Size : 173 k
    Repo : base
    Summary : Network management utilities using SNMP, from the NET-SNMP project
    URL :
    License : BSD
    Description : The net-snmp-utils package contains various utilities for use with the
    : NET-SNMP network management project.
    : Install this package if you need utilities for managing your network
    : using the SNMP protocol. You will also need to install the net-snmp
    : package.

    Mitali Sodhi

    I have realized the errors are coming due to two main reasons:
    1. I am able to give the link of only repository in the first step of installation in the Ambari Install Wizard. So, the packages in that repository are getting installed. But, the packages in other repository (Amabari/HDP-UTILS) are not getting installed.

    2. “yum” command is only able to install packages from the web-server and not from local repository on giving "yum install <package_name>"
    But, it is not able to detect and install the packages from the local repository, unless I give "yum localinstall <package_name>"
    So, even if I have changed the .repo file in /etc/yum.repos.d/, still why the packages are not getting from the local repository?

    Jeff Sposetti

    On the Ambari Server, your ambari.repo should also be setup for local repositories. That .repo file includes HDP-UTILS and AMBARI repos. Make sure that file has the right repos, since that is distributed to the hosts during install.

    Mitali Sodhi


    So, the issue got resolved. The problem was in the ambari.repo file. The name of the packages were not written correctly. The .repo file that comes with the tar balls has three packages listed.
    1. [ambari-1.x]
    2. [HDP-UTILS-]
    3. [Updates-ambari-]

    While, hdp.repo in the tar ball contains :
    1. [HDP-2.x]
    2. [HDP-UTILS-]
    3. [HDP]

    So, this creates a confusion regarding the correct names that should be given to the packages while installing from the local repository. As, the local repository has three packages : HDP, HDP-UTILS and Ambari. So, the convention followed in the inbuilt ambari.repo file does not actually match with the local repo packages. The names for the packages that I followed is:
    1. [Ambari-1.4]
    2. [HDP-UTILS-]
    3. [HDP-]
    This worked for me and packages got installed. I think the guidelines to change the names of the packages should be included in the documentation as it was very difficult to debug that the installation was failing because of it. Also, these names are case sensitive. “ambari-1.4” didn’t work, but “Ambari-1.4” did. In the documentation, the sample “hdp.repo” file has “ambari-1.x” as one of the package names. This should be corrected.


The topic ‘Error in installattion using Ambari from a Local Repository’ is closed to new replies.

Support from the Experts

A HDP Support Subscription connects you experts with deep experience running Apache Hadoop in production, at-scale on the most demanding workloads.

Enterprise Support »

Become HDP Certified

Real world training designed by the core architects of Hadoop. Scenario-based training courses are available in-classroom or online from anywhere in the world

Training »

Hortonworks Data Platform
The Hortonworks Data Platform is a 100% open source distribution of Apache Hadoop that is truly enterprise grade having been built, tested and hardened with enterprise rigor.
Get started with Sandbox
Hortonworks Sandbox is a self-contained virtual machine with Apache Hadoop pre-configured alongside a set of hands-on, step-by-step Hadoop tutorials.
Modern Data Architecture
Tackle the challenges of big data. Hadoop integrates with existing EDW, RDBMS and MPP systems to deliver lower cost, higher capacity infrastructure.