In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)06/02 Report--
Editor to share with you how to set the iso file as the local yum source for CentOS, I believe most people do not know much about it, so share this article for your reference, I hope you can learn a lot after reading this article, let's go to know it!
Problems and ideas
Because the server cannot access the Internet, you can only upload the image file of the iso system to the server, and then set the iso file as the local yum source. Only in this way can yum be updated and installed.
Solution and steps
Upload iso files using the zmodem protocol, which limits the size of uploaded files to a maximum of 4G files. Therefore, you need to split the files less than 4G first, and then merge the files on the server.
Split file split-b 3072m CentOS-7-x86_64-DVD-1810.iso CentOS-7-x86_64-DVD-1810.iso-
View the split file:
Ls-1 zhangyalin staff 4588568576 7 15 18:00 CentOS-7-x86_64-DVD-1810.iso-rw-r--r-- 1 zhangyalin staff 3221225472 7 15 18:02 CentOS-7-x86_64-DVD-1810.iso-aa-rw-r--r-- 1 zhangyalin staff 1367343104 7 15 18:02 CentOS-7-x86_64-DVD-1810.iso-ab
Use the rz command in the zmodem protocol to upload files to the server, and then merge the files.
Merge file cat CentOS-7-x86_64-DVD-1810.iso-* > CentOS-7-x86_64-DVD-1810.iso mount image mkdir / mnt/isomount-o loop CentOS-7-x86_64-DVD-1810.iso / mnt/iso
Verify image mount:
Df-h configure yum source
Back up the Yum source configuration:
Cd / etc/yum.repos.d/rename .repo .repo.bak *
Create a new yum local source configuration:
Vim CentOS-Local.repo
Specific configuration content:
[local] name=CentOS-Localbaseurl= file:///mnt/isogpgcheck=1enabled=1gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
List the sources available for yum:
Yum repolist all problem you can try to add-- skip-broken option to solve this problem yum clean all above is all the content of the article "how to set the iso file as the local yum source for CentOS", thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.