美文网首页
制作Ambari本地yum源

制作Ambari本地yum源

作者: syhc006 | 来源:发表于2019-03-26 10:49 被阅读0次
  • 安装工具
yum install createrepo yum-utils nginx -y
  • 下载需要同步的yum源repo文件
wget -O /etc/yum.repos.d/ambari.repo http://public-repo-1.hortonworks.com/ambari/centos7/2.x/updates/2.7.3.0/ambari.repo
wget -O /etc/yum.repos.d/hdp.repo http://public-repo-1.hortonworks.com/HDP/centos7/3.x/updates/3.1.0.0/hdp.repo
wget -O /etc/yum.repos.d/hdp.gpl.repo   http://public-repo-1.hortonworks.com/HDP-GPL/centos7/3.x/updates/3.1.0.0/hdp.gpl.repo
  • 查看yum源id
yum repolist
  • 同步yum源至本地
reposync -r ambari-2.7.3.0 -p /local-yum-repository/centos7
reposync -r HDP-3.1.0.0 -p /local-yum-repository/centos7
reposync -r HDP-UTILS-1.1.0.22 -p /local-yum-repository/centos7
reposync -r HDP-GPL-3.1.0.0 -p /local-yum-repository/centos7
  • 创建源文件
createrepo -p -d -o /local-yum-repository/centos/7/os/x86_64/ /local-yum-repository/centos/7/os/x86_64/
  • 配置nginx
cat <<EOF >/etc/nginx/conf.d/local-yum-repository.conf
server{
  listen 80;
  server_name local-yum-repository;
  gzip off;
  autoindex on;
  access_log /var/log/nginx/repo-access.log;
  location /centos/7/os/x86_64 {
    alias /local-yum-repository/centos/7/os/x86_64/
  }
}
EOF
  • 启动nginx
systemctl restart nginx
  • 本地yum源repo文件
[local]
name=local yum repository
baseurl=http://local-yum-repository/centos/7/os/x86_64
enabled=1
gpgcheck=0

相关文章

  • 制作Ambari本地yum源

    安装工具 下载需要同步的yum源repo文件 查看yum源id 同步yum源至本地 创建源文件 配置nginx 启...

  • yum源的挂载

    下面是关于本地yum源,联网的yum源,添加其他yum源,三部分 制作本地YUM源 1.准备一台Linux服务器,...

  • 用createrepo本地yum源配置

    下载createrepo,用rpm包制作本地yum源 首先备份原yum源 /etc/yum.repos.d/ 新建...

  • yum本地源制作

    yum源分类 yum源 epel源(epel(Extra Packages for Enterprise Linu...

  • 12_YUM

    本地YUM源制作 YUM相关概念 什么是YUMYUM(全称为 Yellow dog Updater, Modifi...

  • CentOS 7下制作本地yum源

    CentOS 7下制作本地yum源 CentOS 7 制作本地repository的方法, 适用于没有外网访问权限...

  • centOS安装yum本地仓库

    配置yum源仓库 1.制作本地仓库 新建文件夹packages,将rpm包导入 安装制作工具 yum ...

  • Linux本地Yum源制作

    操作之前准备好以下环境: YUM是什么? YUM(全称为 Yellow dog Updater, Modified...

  • Ambari实战-5:构建Ambari私有源

    我们本篇文章主要讲述如何去同步远程服务器中的Ambari数据源到本地,并将其作为局域网yum安装源。 基本环境信息...

  • Centos Issue

    CentOS配置本地Yum源、阿里云Yum源、163Yum源、并配置Yum源的优先级

网友评论

      本文标题:制作Ambari本地yum源

      本文链接:https://www.haomeiwen.com/subject/vdvrpqtx.html