Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

Unable to install HDP 3.1.0.3 with Ambari on offline repository

Unable to install HDP 3.1.0.3 with Ambari on offline repository

New Contributor

I am trying to install HDP 3.1.0.1 with Ambari using offline repository and have Completed all prerequisites including:

  • hosts entries, hostname, firewall disabled, iptables etc
  • Java update, MySQL installation with connector, HTTP service installation.
  • Repository creation for offline HDP, HDP UTILS, AMBARI and modified .repo files properly to point local url.

After all above prerequisites I can see web folders from browser, can perform wget to copy files, but when try to install yum install ambari-server get following error.

*********************************************************************************************************************************************

[root@hdf03 ~]# yum install ambari-server

Loaded plugins: fastestmirror, langpacks

Loading mirror speeds from cached hostfile

* base: centos.excellmedia.net

* extras: centos.excellmedia.net

* updates: centos.excellmedia.net

ambari-2.7.3.0 | 790 B 00:00:00 http://hdf03.ufm/repo/ambari/centos7/2.7.3.0-139/repodata/repomd.xml: [Errno -1] Error importing repomd.xml for ambari-2.7.3.0: Damaged repomd.xml file Trying other mirror. One of the configured repositories failed (ambari Version - ambari-2.7.3.0), and yum doesn't have enough cached data to continue. At this point the only safe thing yum can do is fail. There are a few ways to work "fix" this:

1. Contact the upstream for the repository and get them to fix the problem.

2. Reconfigure the baseurl/etc. for the repository, to point to a working upstream. This is most often useful if you are using a newer distribution release than is supported by the repository (and the packages for the previous distribution release still work). 3. Run the command with the repository temporarily disabled yum --disablerepo=ambari-2.7.3.0 ...

4. Disable the repository permanently, so yum won't use it by default. Yum will then just ignore the repository until you permanently enable it again or use --enablerepo for temporary usage: yum-config-manager --disable ambari-2.7.3.0 or subscription-manager repos --disable=ambari-2.7.3.0 5. Configure the failing repository to be skipped, if it is unavailable.

Note that yum will try to contact the repo. when it runs most commands, so will have to try and fail each time (and thus. yum will be be much slower). If it is a very temporary problem though, this is often a nice compromise: yum-config-manager --save --setopt=ambari-2.7.3.0.skip_if_unavailable=true failure: repodata/repomd.xml from ambari-2.7.3.0: [Errno 256] No more mirrors to try. http://hdf03.ufm/repo/ambari/centos7/2.7.3.0-139/repodata/repomd.xml: [Errno -1] Error importing repomd.xml for ambari-2.7.3.0: Damaged repomd.xml file

************************************************************************************************************************************

Can any body help me where I am missing something or doing wrong because in another installation when I connected to open internet it worked fine even it was also offline repository.

What I have learned from previous installations local repositories url are not resolved during installation while same url are accessible using browser.

3 REPLIES 3
Highlighted

Re: Unable to install HDP 3.1.0.3 with Ambari on offline repository

Super Collaborator

Hi @Naeem Ullah Khan,

it's looks like an issue with proxy-server. if you are using proxy-server please add in /etc/yum.conf

Re: Unable to install HDP 3.1.0.3 with Ambari on offline repository

Super Mentor

@Naeem Ullah Khan

Please define your Network proxy server details inside the "/etc/yum.conf" file something like following [proxy=http://yourproxy.test.com:80]:

# cat /etc/yum.conf 
[main] 
cachedir=/var/cache/yum/$basearch/$releasever 
keepcache=0 
debuglevel=2 
logfile=/var/log/yum.log 
exactarch=1 
obsoletes=1 
gpgcheck=1 
plugins=1 
installonly_limit=3 
proxy=http://yourproxy.test.com:80


Then perform "yum clean all" and then try installing packages again.

# yum clean all

.


Also please verify if you are able to make the curl call to the same URL using proxy? If the proxy is being used then in the Output of the curl call you should see the header info if the proxy is being used or not?

# curl -iLv http://hdf03.ufm/repo/ambari/centos7/2.7.3.0-139/repodata/repomd.xml


If the above call is not working then please add the Environment variable in your "~/.bash_profile"

export http_proxy=http://yourproxy.test.com:80
export https_proxy=${http_proxy}

.

Re: Unable to install HDP 3.1.0.3 with Ambari on offline repository

New Contributor

Dear Jay,

Thank you for your reply I was already thinking you will reply as I am one of your followers. I have tried the steps you suggested but problem is still there.

Yes I am using proxy and yum install was working fine on this proxy for update, mysql server and ntp but now producing error while I have not made any change in the system except setup local repository on /var/www/htmo/repo folder and created .repo files for offline repositories.

It looks there is some url resolution issue using proxy but I am unable to find it. But as I already mentioned that when I use IP address having internet access without proxy same local urls are resolved and are accessible to yum command.

Hope you can understand my problem.