CentOS Configuration local Yum source

Source: Internet
Author: User
Tags gpg

[[Email protected] ~] #ls/media/dvd/#查看 System CD

[[Email protected] ~] #mkdir/home/yum_packupages/centos/#创建一个存放系统光盘数据文件夹

[[Email protected] ~] #cp/media/dvd/centos/*/home/yum_packupages/centos/#复制系统光盘数据到本地

[[Email protected] ~] #cd/etc/yum.repos.d/#进入配置 Directory

[[email protected] yum.repos.d]# LS # View configuration Files

Centos-base.repo Centos-debuginfo.repo Centos-media.repo Centos-vault.repo

Centos-cr.repo Centos-fasttrack.repo Centos-sources.repo

[Email protected] yum.repos.d]# vim centos-base.repo #修改配置 File

[Base]

name=centos-$releasever-base

baseurl=file:///home/yum_packages/centos/#yum源目录, image file Directory to store

Enabled=1 #是否用该yum源, 0 is disabled, 1 is used

Gpgcheck=1 #检查GPG-key,0 for no check, 1 for inspection

Gpgkey=file:///etc/pki/rpm-gpg/rpm-gpg-key-centos-7 #本地yum源密钥, Gpgcheck No configuration required when =0

[[email protected] YUM.REPOS.D] #yum list #检查 If Yum is available, a list of installation packages is available

[email protected] yum.repos.d]# Yum install ftp* #yum本 To install

CentOS Configuration local Yum source

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.