Home Operation and Maintenance Linux Operation and Maintenance How to use the domestic Alibaba Cloud yum installation source for redhat7

How to use the domestic Alibaba Cloud yum installation source for redhat7

Jun 25, 2017 am 10:04 AM
redhat use initialization Ali

This article introduces how redhat7 uses the domestic Alibaba Cloud yum installation source. The source address used corresponds to the installation source under Centos7.

When I was studying "This is how Linux should be learned" to configure the system environment redhat7, I chose a graphical interface. The yum used did not have any configuration /etc/yum.repos.d/ directory There is no configuration file, so you need to set it manually. Here are some of my steps:

1. Locate the yum configuration file

[root@linuxprobe ~]#cd /etc/yum.repos.d/

2. Check whether there is a configuration file

[root@linuxprobe yum.repos.d]#ls

The blogger’s system has just been installed without any files

3. Check whether yum is installed, what dependencies are installed and delete the yum package

##[root@linuxprobe yum.repos.d]#rpm - qa |grep yum

displays as follows:

yum-utils-1.1.31-24.el7.noarch
yum-langpacks-0.4.2-3.el7.noarch
yum-metadata-parser-1.1.4-10.el7.x86_64
yum -rhn-plugin-2.0.1-4.el7.noarch
PackageKit-yum-0.8.9-11.el7.x86_64
yum-3.4.3 -118.el7.noarch

We need to record the above, and we will need it later when installing a new yum

[root@linuxprobe yum.repos.d]#rpm -qa|grep yum|xargs rpm -e --nodeps Delete yum package

4. After the above steps are completed, we need to update Install yum and change the source address to the source address corresponding to Alibaba Cloud.

Go to the page under the address and use Ctrl+F to search for the file in step 3. Do not bring the version number: such as yum-utils-1.1.31-24.el7. noarch just search for yum-utils.

Such as yum package:

[root@linuxprobe ~]# wget

Others The method of obtaining each package is similar.

After downloading, use rpm -ivh yum-* to install the rpm package. The blogger here prompts an error, as follows:

The above command is caused by the low version of python-urlgrabber we installed, so let’s uninstall python-urlgrabber first.

5. Command to check the python-urlgrabber package

##[root@linuxprobe ~]# rpm -qa|grep python-urlgrabber

6. Execute the following command to delete the python-urlgrabber package##[root@linuxprobe ~]# rpm -qa|grep yum|xargs rpm -e --nodeps

7. Download and install

[ root@linuxprobe ~]# wget

Install python-urlgrabber

[root@linuxprobe ~]#rpm -ivh python-urlgrabber-3.10-8.el7.noarch.rpm

8.python-urlgrabber installation After completion, execute rpm -ivh yum-* to install yum to the computer.

If during the installation process it is prompted that the package resource is a dependency of our installation, then Just install it.

#9. After the package installation is completed, we still need to configure the source address of yum.

1) Locate the folder where the configuration file is located:

[root@linuxprobe~]# cd /etc/yum .repos.d/

2) Check whether there are files in the yum.repos.d folder, and obtain the Alibaba Cloud source configuration file:

[root@linuxprobe yum.repos.d]# ls

[root@linuxprobe yum.repos.d]#wget

For specific help information, please view the Alibaba Cloud help documentation.

10. Modify the value of $releasever

##The configuration file Centos-7.repo we obtained has a $releasever after it is opened. This is a yum variable. We need to replace it, otherwise the source cannot be used. If you do not replace it, you can try the yum command to see what is displayed. .

Use the following command to replace $releasever,

[root@linuxprobe ~]# sed -i 's/$releasever/7/g ' /etc/yum.repos.d/Centos-7.repo

There is a problem with getting the value of this variable $releasever. I checked some information, but it is not the same as the blogger system.

There is a yum.conf file under the /etc/ folder, which is configured with

The variable value obtained after changing to =redhat-release is 7.0-1.el7. This is the version number. I haven’t found where to handle this yet. If anyone knows, please let me know.

11. Finally execute yum makecache to generate the cache.

centos-7.repo file contains some uses that are recommended to be commented out. This address is used in the Alibaba Cloud server intranet. We It's impossible to connect to it from my own computer, so I commented this out.

##After all comments, execute yum clean all again; yum makecache

12. View the currently available warehouse yum repolist all

Two of the above pictures are not enabled. I’ll leave them to Baidu to find out what they are for. If you want to enable them, just change enabled=1 in the Centos-7.repo file.

The above is the detailed content of How to use the domestic Alibaba Cloud yum installation source for redhat7. For more information, please follow other related articles on the PHP Chinese website!

Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

How to use magnet links How to use magnet links Feb 18, 2024 am 10:02 AM

Magnet link is a link method for downloading resources, which is more convenient and efficient than traditional download methods. Magnet links allow you to download resources in a peer-to-peer manner without relying on an intermediary server. This article will introduce how to use magnet links and what to pay attention to. 1. What is a magnet link? A magnet link is a download method based on the P2P (Peer-to-Peer) protocol. Through magnet links, users can directly connect to the publisher of the resource to complete resource sharing and downloading. Compared with traditional downloading methods, magnetic

How to use mdf and mds files How to use mdf and mds files Feb 19, 2024 pm 05:36 PM

How to use mdf files and mds files With the continuous advancement of computer technology, we can store and share data in a variety of ways. In the field of digital media, we often encounter some special file formats. In this article, we will discuss a common file format - mdf and mds files, and introduce how to use them. First, we need to understand the meaning of mdf files and mds files. mdf is the extension of the CD/DVD image file, and the mds file is the metadata file of the mdf file.

Alibaba Cloud announced that the 2024 Yunqi Conference will be held in Hangzhou from September 19th to 21st. Free application for free tickets Alibaba Cloud announced that the 2024 Yunqi Conference will be held in Hangzhou from September 19th to 21st. Free application for free tickets Aug 07, 2024 pm 07:12 PM

According to news from this website on August 5, Alibaba Cloud announced that the 2024 Yunqi Conference will be held in Yunqi Town, Hangzhou from September 19th to 21st. There will be a three-day main forum, 400 sub-forums and parallel topics, as well as nearly four Ten thousand square meters of exhibition area. Yunqi Conference is free and open to the public. From now on, the public can apply for free tickets through the official website of Yunqi Conference. An all-pass ticket of 5,000 yuan can be purchased. The ticket website is attached on this website: https://yunqi.aliyun.com/2024 /ticket-list According to reports, the Yunqi Conference originated in 2009 and was originally named the First China Website Development Forum. In 2011, it evolved into the Alibaba Cloud Developer Conference. In 2015, it was officially renamed the "Yunqi Conference" and has continued to successful move

What software is crystaldiskmark? -How to use crystaldiskmark? What software is crystaldiskmark? -How to use crystaldiskmark? Mar 18, 2024 pm 02:58 PM

CrystalDiskMark is a small HDD benchmark tool for hard drives that quickly measures sequential and random read/write speeds. Next, let the editor introduce CrystalDiskMark to you and how to use crystaldiskmark~ 1. Introduction to CrystalDiskMark CrystalDiskMark is a widely used disk performance testing tool used to evaluate the read and write speed and performance of mechanical hard drives and solid-state drives (SSD). Random I/O performance. It is a free Windows application and provides a user-friendly interface and various test modes to evaluate different aspects of hard drive performance and is widely used in hardware reviews

How to download foobar2000? -How to use foobar2000 How to download foobar2000? -How to use foobar2000 Mar 18, 2024 am 10:58 AM

foobar2000 is a software that can listen to music resources at any time. It brings you all kinds of music with lossless sound quality. The enhanced version of the music player allows you to get a more comprehensive and comfortable music experience. Its design concept is to play the advanced audio on the computer The device is transplanted to mobile phones to provide a more convenient and efficient music playback experience. The interface design is simple, clear and easy to use. It adopts a minimalist design style without too many decorations and cumbersome operations to get started quickly. It also supports a variety of skins and Theme, personalize settings according to your own preferences, and create an exclusive music player that supports the playback of multiple audio formats. It also supports the audio gain function to adjust the volume according to your own hearing conditions to avoid hearing damage caused by excessive volume. Next, let me help you

How to use NetEase Mailbox Master How to use NetEase Mailbox Master Mar 27, 2024 pm 05:32 PM

NetEase Mailbox, as an email address widely used by Chinese netizens, has always won the trust of users with its stable and efficient services. NetEase Mailbox Master is an email software specially created for mobile phone users. It greatly simplifies the process of sending and receiving emails and makes our email processing more convenient. So how to use NetEase Mailbox Master, and what specific functions it has. Below, the editor of this site will give you a detailed introduction, hoping to help you! First, you can search and download the NetEase Mailbox Master app in the mobile app store. Search for "NetEase Mailbox Master" in App Store or Baidu Mobile Assistant, and then follow the prompts to install it. After the download and installation is completed, we open the NetEase email account and log in. The login interface is as shown below

How to use Baidu Netdisk app How to use Baidu Netdisk app Mar 27, 2024 pm 06:46 PM

Cloud storage has become an indispensable part of our daily life and work nowadays. As one of the leading cloud storage services in China, Baidu Netdisk has won the favor of a large number of users with its powerful storage functions, efficient transmission speed and convenient operation experience. And whether you want to back up important files, share information, watch videos online, or listen to music, Baidu Cloud Disk can meet your needs. However, many users may not understand the specific use method of Baidu Netdisk app, so this tutorial will introduce in detail how to use Baidu Netdisk app. Users who are still confused can follow this article to learn more. ! How to use Baidu Cloud Network Disk: 1. Installation First, when downloading and installing Baidu Cloud software, please select the custom installation option.

BTCC tutorial: How to bind and use MetaMask wallet on BTCC exchange? BTCC tutorial: How to bind and use MetaMask wallet on BTCC exchange? Apr 26, 2024 am 09:40 AM

MetaMask (also called Little Fox Wallet in Chinese) is a free and well-received encryption wallet software. Currently, BTCC supports binding to the MetaMask wallet. After binding, you can use the MetaMask wallet to quickly log in, store value, buy coins, etc., and you can also get 20 USDT trial bonus for the first time binding. In the BTCCMetaMask wallet tutorial, we will introduce in detail how to register and use MetaMask, and how to bind and use the Little Fox wallet in BTCC. What is MetaMask wallet? With over 30 million users, MetaMask Little Fox Wallet is one of the most popular cryptocurrency wallets today. It is free to use and can be installed on the network as an extension

See all articles