快速配置百胜本地源

  <强>本文档将教会大家快速配置百胜源,这种方法很适合新创建的   Linux系统,特别是RHEL7系列的   Linux系统。      <强>首先把系统镜像挂载过来:   

  快速配置百胜本地源

  

在右下角的光盘标志这里右键,然后点击连接,桌面就会出现镜像图标。   
然后再执行创建   脚本的   命令创建   脚本。

  <>以前vim  rhel7.repo.sh   #在打开的文件中添加以下内容:   # !/bin/bash   cd /etc/yum.repos.d   cat 祝辞,rhel7.repo  & lt; & lt;好吧   (rhel7),   name=rhel7   baseurl=文件:///媒体/光盘   启用=1   gpgcheck=0   好吧   mkdir  -p /媒体/光盘   mount /dev/cdrom /媒体/光盘   echo “/dev/cdrom /媒体/cdrom  iso9660  defaults  0, 0“,在在/etc/fstab   yum  clean    yum  makecache      <强>写完脚本后记得赋予脚本执行权限:   <>以前chmod  755年,rhel7.repo.sh或者chmod  + x  rhel7.repo.sh      <>强赋予脚本执行权限后再运行脚本:   <>以前bash  rhel7.repo.sh 或者。/rhel7.repo.sh      <>强测试:   
 [root@localhost 桌面)#,yum  install  -y  httpd
  Loaded 插件:,langpacks,,产品id,, search-disabled-repos,订阅管理器
  却,能够system  is  not  registered 用Red  Hat  Subscription 管理又是;你还要use  subscription-manager 用寄存器。
  Resolving 依赖关系
  ——在Running  transaction 检查
  ——→,Package  httpd.x86_64  0:2.4.6 - 40. - el7  will  be 安装
  ——祝辞,Finished  Dependency 决议
  Dependencies 解决============================================================================================================,Package ,,,,,,,,,,,,,, Arch ,,,,,,,,,,,,,,,,,,, Version ,,,,,,,,,,,,,,,,,,,,,,, Repository ,,,,,,,,,,,,,的大?===========================================================================================================安装:
  ,httpd ,,,,,,,,,,,,,,,, x86_64 ,,,,,,,,,,,,,,,,, 2.4.6-40.el7 ,,,,,,,,,,,,,,,,,, rhel7 ,,,,,,,,,,,,,,,,,, 1.2 M
  Transaction 总结============================================================================================================Install , 1包
  Total  download 大小:1.2,米
  Installed 大小:3.7,米
  Downloading 包:
  Running  transaction 检查
  Running  transaction 测试
  Transaction  test 成功了
  Running 事务
  Installing 才能:httpd - 2.4.6 - 40. - el7.x86_64 ,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, 1/1 
  Verifying 才能;,:,httpd - 2.4.6 - 40. - el7.x86_64 ,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, 1/1 
  安装:
  0:2.4.6 httpd.x86_64 才能;40. - el7 ,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
  完成了! 
     <强>总结   

  <强>最后出现完成!说明httpd安装成功,同时也说明了百胜仓库配置成功!   
注:我用的系统是RedHat7,用其他Linux系统的话只需要改百胜仓库名称即可。

  

本文原创地址:   https://www.linuxprobe.com/quickly-configure-yum.html   

快速配置百胜本地源