zoukankan      html  css  js  c++  java
  • ambari安装Zeppelin Notebook提示ES源找不到问题解决

    说明:因为曾经在ambari集成metron hcp,安装有ES。这样ES的yum源同时写入配置文件保存在数据库(表:repo_version中)

    这造成在安装其他组件是一直提示下面问题:

    stderr:   /var/lib/ambari-agent/data/errors-9286.txt
    
    Traceback (most recent call last):
      File "/var/lib/ambari-agent/cache/common-services/ZEPPELIN/0.6.0.2.5/package/scripts/master.py", line 448, in <module>
        Master().execute()
      File "/usr/lib/python2.6/site-packages/resource_management/libraries/script/script.py", line 329, in execute
        method(env)
      File "/var/lib/ambari-agent/cache/common-services/ZEPPELIN/0.6.0.2.5/package/scripts/master.py", line 49, in install
        self.install_packages(env)
      File "/usr/lib/python2.6/site-packages/resource_management/libraries/script/script.py", line 693, in install_packages
        retry_count=agent_stack_retry_count)
      File "/usr/lib/python2.6/site-packages/resource_management/core/base.py", line 155, in __init__
        self.env.run()
      File "/usr/lib/python2.6/site-packages/resource_management/core/environment.py", line 160, in run
        self.run_action(resource, action)
      File "/usr/lib/python2.6/site-packages/resource_management/core/environment.py", line 124, in run_action
        provider_action()
      File "/usr/lib/python2.6/site-packages/resource_management/core/providers/package/__init__.py", line 54, in action_install
        self.install_package(package_name, self.resource.use_repos, self.resource.skip_repos)
      File "/usr/lib/python2.6/site-packages/resource_management/core/providers/package/yumrpm.py", line 51, in install_package
        self.checked_call_with_retries(cmd, sudo=True, logoutput=self.get_logoutput())
      File "/usr/lib/python2.6/site-packages/resource_management/core/providers/package/__init__.py", line 86, in checked_call_with_retries
        return self._call_with_retries(cmd, is_checked=True, **kwargs)
      File "/usr/lib/python2.6/site-packages/resource_management/core/providers/package/__init__.py", line 98, in _call_with_retries
        code, out = func(cmd, **kwargs)
      File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 72, in inner
        result = function(command, **kwargs)
      File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 102, in checked_call
        tries=tries, try_sleep=try_sleep, timeout_kill_strategy=timeout_kill_strategy)
      File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 150, in _call_wrapper
        result = _call(command, **kwargs_copy)
      File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 303, in _call
        raise ExecutionFailed(err_msg, code, out, err)
    resource_management.core.exceptions.ExecutionFailed: Execution of '/usr/bin/yum -d 0 -e 0 -y install zeppelin_2_6_0_3_8' returned 1.  One of the configured repositories failed (ES-Curator-5.x),
     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. Disable the repository, 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 ES-Curator-5.x
    
         4. 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=ES-Curator-5.x.skip_if_unavailable=true
    
    failure: repodata/repomd.xml from ES-Curator-5.x: [Errno 256] No more mirrors to try.
    http://packages.elastic.co/curator/5/centos/7/repodata/repomd.xml: [Errno 12] Timeout on http://packages.elastic.co/curator/5/centos/7/repodata/repomd.xml: (28, 'Connection timed out after 30178 milliseconds')
    http://packages.elastic.co/curator/5/centos/7/repodata/repomd.xml: [Errno 12] Timeout on http://packages.elastic.co/curator/5/centos/7/repodata/repomd.xml: (28, 'Connection timed out after 30027 milliseconds')
    http://packages.elastic.co/curator/5/centos/7/repodata/repomd.xml: [Errno 12] Timeout on http://packages.elastic.co/curator/5/centos/7/repodata/repomd.xml: (28, 'Connection timed out after 30177 milliseconds')
    http://packages.elastic.co/curator/5/centos/7/repodata/repomd.xml: [Errno 12] Timeout on http://packages.elastic.co/curator/5/centos/7/repodata/repomd.xml: (28, 'Connection timed out after 30026 milliseconds')
    http://packages.elastic.co/curator/5/centos/7/repodata/repomd.xml: [Errno 12] Timeout on http://packages.elastic.co/curator/5/centos/7/repodata/repomd.xml: (28, 'Connection timed out after 30678 milliseconds')
    http://packages.elastic.co/curator/5/centos/7/repodata/repomd.xml: [Errno 12] Timeout on http://packages.elastic.co/curator/5/centos/7/repodata/repomd.xml: (28, 'Connection timed out after 30026 milliseconds')
    http://packages.elastic.co/curator/5/centos/7/repodata/repomd.xml: [Errno 12] Timeout on http://packages.elastic.co/curator/5/centos/7/repodata/repomd.xml: (28, 'Connection timed out after 30025 milliseconds')
    http://packages.elastic.co/curator/5/centos/7/repodata/repomd.xml: [Errno 12] Timeout on http://packages.elastic.co/curator/5/centos/7/repodata/repomd.xml: (28, 'Connection timed out after 30179 milliseconds')
    http://packages.elastic.co/curator/5/centos/7/repodata/repomd.xml: [Errno 12] Timeout on http://packages.elastic.co/curator/5/centos/7/repodata/repomd.xml: (28, 'Connection timed out after 30028 milliseconds')
    http://packages.elastic.co/curator/5/centos/7/repodata/repomd.xml: [Errno 12] Timeout on http://packages.elastic.co/curator/5/centos/7/repodata/repomd.xml: (28, 'Connection timed out after 30175 milliseconds')
    

    查看ambri HDP-2.6 stackversion配置,多出如下项(红框):

    查看/var/lib/ambari-server/resources/stacks/HDP/2.6/repos/repoinfo.xml没有相关配置信息

    查看数据库ambari->repo_version的filed repositories信息如下:

    [{"OperatingSystems/ambari_managed_repositories":"true","OperatingSystems/stack_name":"HDP","OperatingSystems/stack_version":"2.6","repositories":[{"Repositories/default_base_url":"","Repositories/base_url":"","Repositories/mirrors_list":"","Repositories/repo_name":"CURATOR","Repositories/unique":"false","Repositories/repo_id":"ES-Curator-5.x","Repositories/repository_version_id":"2","Repositories/stack_name":"HDP","Repositories/latest_base_url":"","Repositories/os_type":"redhat7","Repositories/stack_version":"2.6","href":"http://172.17.0.160:8080/api/v1/stacks/HDP/versions/2.6/repository_versions/2/operating_systems/redhat7/repositories/ES-Curator-5.x","hasError":"false","Repositories/initial_base_url":"http://packages.elastic.co/curator/5/centos/7"},{"Repositories/default_base_url":"","Repositories/base_url":"http://172.17.0.160/hcp/","Repositories/mirrors_list":"","Repositories/repo_name":"METRON","Repositories/unique":"false","Repositories/repo_id":"HCP-1.4.0.0-38","Repositories/repository_version_id":"2","Repositories/stack_name":"HDP","Repositories/latest_base_url":"","Repositories/os_type":"redhat7","Repositories/stack_version":"2.6","href":"http://172.17.0.160:8080/api/v1/stacks/HDP/versions/2.6/repository_versions/2/operating_systems/redhat7/repositories/HCP-1.4.0.0-38","hasError":"false","Repositories/initial_base_url":"http://172.17.0.160/hcp/"},{"Repositories/default_base_url":"","Repositories/base_url":"http://172.17.0.160/HDF/centos7/","Repositories/mirrors_list":"","Repositories/repo_name":"HDF","Repositories/unique":"false","Repositories/repo_id":"HDF-3.0","Repositories/repository_version_id":"2","Repositories/stack_name":"HDP","Repositories/latest_base_url":"","Repositories/os_type":"redhat7","Repositories/stack_version":"2.6","href":"http://172.17.0.160:8080/api/v1/stacks/HDP/versions/2.6/repository_versions/2/operating_systems/redhat7/repositories/HDF-3.0","hasError":"false","Repositories/initial_base_url":"http://172.17.0.160/HDF/centos7/"},{"Repositories/default_base_url":"","Repositories/base_url":"http://172.17.0.160/HDP/centos7/","Repositories/mirrors_list":"","Repositories/repo_name":"HDP","Repositories/unique":"false","Repositories/repo_id":"HDP-2.6","Repositories/repository_version_id":"2","Repositories/stack_name":"HDP","Repositories/latest_base_url":"","Repositories/os_type":"redhat7","Repositories/stack_version":"2.6","href":"http://172.17.0.160:8080/api/v1/stacks/HDP/versions/2.6/repository_versions/2/operating_systems/redhat7/repositories/HDP-2.6","hasError":"false","Repositories/initial_base_url":"http://172.17.0.160/HDP/centos7/"},{"Repositories/default_base_url":"","Repositories/base_url":"http://172.17.0.160/HDP-UTILS-1.1.0.21/","Repositories/mirrors_list":"","Repositories/repo_name":"HDP-UTILS","Repositories/unique":"false","Repositories/repo_id":"HDP-UTILS-1.1.0.21","Repositories/repository_version_id":"2","Repositories/stack_name":"HDP","Repositories/latest_base_url":"","Repositories/os_type":"redhat7","Repositories/stack_version":"2.6","href":"http://172.17.0.160:8080/api/v1/stacks/HDP/versions/2.6/repository_versions/2/operating_systems/redhat7/repositories/HDP-UTILS-1.1.0.21","hasError":"false","Repositories/initial_base_url":"http://172.17.0.160/HDP-UTILS-1.1.0.21/"},{"Repositories/default_base_url":"","Repositories/base_url":"","Repositories/mirrors_list":"","Repositories/repo_name":"ELASTICSEARCH","Repositories/unique":"false","Repositories/repo_id":"elasticsearch-5.x","Repositories/repository_version_id":"2","Repositories/stack_name":"HDP","Repositories/latest_base_url":"","Repositories/os_type":"redhat7","Repositories/stack_version":"2.6","href":"http://172.17.0.160:8080/api/v1/stacks/HDP/versions/2.6/repository_versions/2/operating_systems/redhat7/repositories/elasticsearch-5.x","hasError":"false","Repositories/initial_base_url":"https://artifacts.elastic.co/packages/5.x/yum"},{"Repositories/default_base_url":"","Repositories/base_url":"","Repositories/mirrors_list":"","Repositories/repo_name":"KIBANA","Repositories/unique":"false","Repositories/repo_id":"kibana-5.x","Repositories/repository_version_id":"2","Repositories/stack_name":"HDP","Repositories/latest_base_url":"","Repositories/os_type":"redhat7","Repositories/stack_version":"2.6","href":"http://172.17.0.160:8080/api/v1/stacks/HDP/versions/2.6/repository_versions/2/operating_systems/redhat7/repositories/kibana-5.x","hasError":"false","Repositories/initial_base_url":"https://artifacts.elastic.co/packages/5.x/yum"}],"OperatingSystems/repository_version_id":"2","OperatingSystems/os_type":"redhat7","href":"http://172.17.0.160:8080/api/v1/stacks/HDP/versions/2.6/repository_versions/2/operating_systems/redhat7","selected":"true"}]
    

    删除es的对应项

    [{"OperatingSystems/ambari_managed_repositories":"true","OperatingSystems/stack_name":"HDP","OperatingSystems/stack_version":"2.6","repositories":[{"Repositories/default_base_url":"","Repositories/base_url":"http://172.17.0.160/hcp/","Repositories/mirrors_list":"","Repositories/repo_name":"METRON","Repositories/unique":"false","Repositories/repo_id":"HCP-1.4.0.0-38","Repositories/repository_version_id":"2","Repositories/stack_name":"HDP","Repositories/latest_base_url":"","Repositories/os_type":"redhat7","Repositories/stack_version":"2.6","href":"http://172.17.0.160:8080/api/v1/stacks/HDP/versions/2.6/repository_versions/2/operating_systems/redhat7/repositories/HCP-1.4.0.0-38","hasError":"false","Repositories/initial_base_url":"http://172.17.0.160/hcp/"},{"Repositories/default_base_url":"","Repositories/base_url":"http://172.17.0.160/HDF/centos7/","Repositories/mirrors_list":"","Repositories/repo_name":"HDF","Repositories/unique":"false","Repositories/repo_id":"HDF-3.0","Repositories/repository_version_id":"2","Repositories/stack_name":"HDP","Repositories/latest_base_url":"","Repositories/os_type":"redhat7","Repositories/stack_version":"2.6","href":"http://172.17.0.160:8080/api/v1/stacks/HDP/versions/2.6/repository_versions/2/operating_systems/redhat7/repositories/HDF-3.0","hasError":"false","Repositories/initial_base_url":"http://172.17.0.160/HDF/centos7/"},{"Repositories/default_base_url":"","Repositories/base_url":"http://172.17.0.160/HDP/centos7/","Repositories/mirrors_list":"","Repositories/repo_name":"HDP","Repositories/unique":"false","Repositories/repo_id":"HDP-2.6","Repositories/repository_version_id":"2","Repositories/stack_name":"HDP","Repositories/latest_base_url":"","Repositories/os_type":"redhat7","Repositories/stack_version":"2.6","href":"http://172.17.0.160:8080/api/v1/stacks/HDP/versions/2.6/repository_versions/2/operating_systems/redhat7/repositories/HDP-2.6","hasError":"false","Repositories/initial_base_url":"http://172.17.0.160/HDP/centos7/"},{"Repositories/default_base_url":"","Repositories/base_url":"http://172.17.0.160/HDP-UTILS-1.1.0.21/","Repositories/mirrors_list":"","Repositories/repo_name":"HDP-UTILS","Repositories/unique":"false","Repositories/repo_id":"HDP-UTILS-1.1.0.21","Repositories/repository_version_id":"2","Repositories/stack_name":"HDP","Repositories/latest_base_url":"","Repositories/os_type":"redhat7","Repositories/stack_version":"2.6","href":"http://172.17.0.160:8080/api/v1/stacks/HDP/versions/2.6/repository_versions/2/operating_systems/redhat7/repositories/HDP-UTILS-1.1.0.21","hasError":"false","Repositories/initial_base_url":"http://172.17.0.160/HDP-UTILS-1.1.0.21/"}],"OperatingSystems/repository_version_id":"2","OperatingSystems/os_type":"redhat7","href":"http://172.17.0.160:8080/api/v1/stacks/HDP/versions/2.6/repository_versions/2/operating_systems/redhat7","selected":"true"}]
    

    重启ambari-server,在查看:

      

      

      

  • 相关阅读:
    C#24种设计模式汇总
    传智播客C++视频学习笔记(5)
    传智播客C++视频学习笔记(3)
    传智播客C++视频学习笔记(1)
    Learning hard 网络编程
    Learning hard 学习笔记
    男人和女人 访问者模式
    其实你不懂老板的心 解释器模式
    项目多也别傻做 享元模式
    git常用命令
  • 原文地址:https://www.cnblogs.com/idvcn/p/9104122.html
Copyright © 2011-2022 走看看