First of all, you must create a YUM warehouse for machine A. When machine A updates YUM through the external network, it is actually placed on a similar server, but it uses the public network. As for your other servers accessing A to update source C, it is actually the same as A. Accessing the external network is the same, but it is changed to the internal network. The specific process is as follows: 1. Server A uses root privileges
yum install createrepo
Create the warehouse directory after installation
createrepo -v /var/pub/yum/CentOS/
The above means that the directory of the warehouse is /var/pub/yum/CentOS/. You need to copy the package you want to update to this directory for use by other machines. Generate repodata data
First of all, you must create a YUM warehouse for machine A. When machine A updates YUM through the external network, it is actually placed on a similar server, but it uses the public network. As for your other servers accessing A to update source C, it is actually the same as A. Accessing the external network is the same, but it is changed to the internal network. The specific process is as follows:
1. Server A
uses root privileges
Create the warehouse directory after installation
The above means that the directory of the warehouse is /var/pub/yum/CentOS/. You need to copy the package you want to update to this directory for use by other machines.
Generate repodata data
Enter the /var/pub/yum/CentOS/repodata/ directory
Create a YUM source configuration file
2. Server B
Download localyum.repo and put it in the directory /etc/yum.repo.d/
Update and install
If you don’t understand something, keep asking me, or Google how to make a local yum source server