1024programmer Blog Build a YUM software warehouse based on file (local), ftp service and http service_weixin_45116657’s blog

Build a YUM software warehouse based on file (local), ftp service and http service_weixin_45116657’s blog

class=”markdown_views prism-atom-one-dark”>

1. Introduction to yum

(1) Introduction to yum

Yum can automatically download and install RPM packages from a specified server, automatically resolve dependencies, and install all dependent software packages at one time, without the need to download and install tediously again and again. Yum provides commands to find, install, and delete a certain, a group or even all software packages, and the commands are concise and easy to remember.

(2) yum software warehouse configuration file (/etc/yum.reops.d/rhel-source.repo)

All information of yum is stored in a configuration file called yum.reops.d directory, usually located in /etc/yum.reops.d directory, the rhel-source.repo file in this directory is The configuration file of the yum software warehouse; the following experiments are based on the modification of this configuration file;

Insert picture description here

Where:

  • name=Red Hat Enterprise Linux —–>specific yum source name
  • baseurl —–>mirror server address, you can only write a specific address;
  • enabled=1 —–>Enable warehouse, 1 is enabled, 0 is disabled;
  • gpgcheck=1—->use the public key to verify the correctness of rpm, 0 is disabled;
  • gpgcheck—->If it is 1, the downloaded rpm will be verified by gpg, and the verification key is gpgkey. Generally, your own yum source does not need to be checked.

2. Build a YUM software warehouse based on file (local), ftp service and http service

(1) Based on local Yum software repository

1.1> Configure IP and restart network service;

Insert picture description here
1.2> Check the configured IP address;

Insert picture description here
1.3> Mount: mount /dev/sr0 To the /mnt directory;

Insert picture description here
1.4> Modify the configuration file of yum;

  • baseurl=file:///mnt ——–> Change the mirror server address to the local yum source address;

Insert picture description here
1.5> Test whether the local yum software warehouse is successfully established;

Insert picture description here
Insert picture description here
1.6> For testing, use yum local warehouse to install the service;

Insert picture description here

(2) yum software warehouse based on ftp service

2.1> Lab environment:

Server IP: 192.168.10.10
.
Client IP: 192.168.10.20

2.2> Configure the server IP and restart the network service

Insert picture description here

2.3> View the configured server IP address;

Insert picture description here

2.4> Configure the client IP and restart the network service;

Insert picture description here

2.5> View the configured IP address;

Insert picture description here

2.6> Install and start the ftp service on the server side;

Insert picture description hereInsert picture description here

2.7> Check whether the FTP service is running normally

Insert picture description here

2.8> Mount /dev/sr0 to the /mnt directory;

Insert picture description here

2.9> Create a folder rhel6.5 in the /var/ftp directory, and copy the mount file to this folder Insert picture description here
<a id="210_rhelsourcereporhelsourcerepohttpsimgblogcsdnimgcn201908032In the client, open rhel-source.repo file. And modify the rhel-source.repo file as follows; Insert picture description here
2.11> Test whether the yum software warehouse is successfully established;

Insert picture description here
insert picture description here

2.12> for testing, use the yum repository to install the service;

Insert picture description here

(3)Yum software repository based on http service

3.1> Lab environment

Server: IP address 192.168.10.10

Client: IP address 192.168.10.20

3.2> Configure the server IP and restart the network service;

Insert picture description here

3.3> View the server IP after configuration

Insert picture description here

3.4> Configure the client IP and restart the network service;

Insert picture description here

3.5> View the configured client network card information;

Insert picture description here

3.6> Install and start the http service on the server side;

Insert picture description here

3.7> Check whether the http service is running normally;

Insert picture description here

3.8> Mount /dev/sr0 to the /mnt directory;

Insert picture description here

3.9> Create a folder rhel6.5 in the /var/www/html/ directory, and copy the mount file to the folder insert picture description here
3.10> In the client, open the rhel-source.repo file. And modify the rhel-source.repo file as follows;

Insert picture description here

3.11> Test whether the yum software warehouse is successfully established;

Insert picture description here
insert picture description here

3.12> for testing, use the yum warehouse installation service;

Insert picture description here

This article is from the internet and does not represent1024programmerPosition, please indicate the source when reprinting:https://www.1024programmer.com/build-a-yum-software-warehouse-based-on-file-local-ftp-service-and-http-service_weixin_45116657s-blog/

author: admin

Previous article
Next article

Leave a Reply

Your email address will not be published. Required fields are marked *

Contact Us

Contact us

181-3619-1160

Online consultation: QQ交谈

E-mail: [email protected]

Working hours: Monday to Friday, 9:00-17:30, holidays off

Follow wechat
Scan wechat and follow us

Scan wechat and follow us

Follow Weibo
Back to top
首页
微信
电话
搜索