Yum of Fedora

Source: Internet
Author: User
Tags gpg

Fedora updates Yum instead of APT-get, and the software type is RPM (RedHat Package Manager)

 

Install RPM fusion software Repository

 

Command:

 

Su-// switch to the root user and enter the password

Rpm-IVH

Http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-stable.noarch.rpm


Rpm-IVH

Http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-stable.noarch.rpm


Yum update
// This step will last for a long time

 

 

 

 

Below is the official fedora5 software library

Http://download.fedora.redhat.com/pub/fedora/linux/core/5/

A large number of officially recognized software packages are provided, which are usually included in the CD.

Http://download.fedora.redhat.com/pub/fedora/linux/extras/5/

The additional software package officially provided, which does not provide all other support.

 

1. Set yum
That is, set/etc/yum. conf.
[Main]
Cachedir =/var/Cache/Yum cache directory
Keepcache = 0 determine whether the cache file is to be saved
Debuglevel = 2 debugging level
Logfile =/var/log/yum. Log location
Pkgpolicy = newest try to request the latest version of the software package
Distroverpkg = RedHat-release determine the Linux release information downloaded by yum
Tolerant = 1 indicates whether Yum is "tolerant" during compilation. If it is set to 1, yum ignores many errors.

Exactarch = 1 is useful when yum is updated. It is used to determine whether to update the i686 software package on i386. If option 1 is selected, it is not updated (too many functions need to be set ).
Time is also very troublesome)
The obsoletes = 1 option is described in detail in Yum (8). It is a command line parameter. We can check it later.
Gpgcheck = 1 check whether gpg gnu Privacy Guard can be used for encryption
Plugins = 1 indicates whether the plug-in is displayed. It is necessary to set it to 1. This option is 0 by default.
Metadata_expire = 1800
# Put your repos here or in separate files named file. Repo
# In/etc/yum. Repos. d
Here the so-called repos is actually a software library, you can open/etc/yum. Repos. D to see

C: add the yum software library
Open/etc/yum. Repos. D and you will see the official fedora software library by default.
[Root @ localhost documents] # cd/etc/yum. Repos. d/
[Root @ localhost yum. Repos. d] # ls
Fedora-core.repo
Fedora-extras-development.repo fedora-legacy.repo
Fedora-updates-testing.repo
Fedora-development.repo fedora-extras.repo
Fedora-updates.repo
The preparation for adding a software library is to clarify the exact location of the software library you want to add GPG key, (GNU private guard
Is a key method that implements opengpg standards and Free Software Defined in rfc2440. GPG provides command line applications that can be easily integrated into other applications)
Open a repo and check it out.
Explanation
[Core]
Name = Fedora Core $ releasever-$ basearch
Name. $ Releasever is actually your fedora version. $ basearch is i386 for me.

# Baseurl = http://download.fedora.redhat.com/pub/fedora/linux/core/?releasever/#basearch/ OS/
Basic address

Export List = http://fedora.redhat.com/download/mirrors/fedora-core-#releasever
Image list
Enabled = 1 whether the repo is activated
Gpgcheck = 1 whether to enable GPG check
Gpgkey = file: // etc/pki/rpm-GPG-key-Fedora
File: // etc/pki/rpm-GPG/RPM-GPG-KEY this is the address of the GPG key
[Core-debuginfo]
Name = Fedora Core $ releasever-$ basearch-Debug

Baseurl = Signature/
Enabled = 0
Gpgcheck = 1
Gpgkey = file: // etc/pki/rpm-GPG-key-Fedora
File: // etc/pki/rpm-GPG/RPM-GPG-KEY
[Core-source]
Name = Fedora Core $ releasever-Source

Baseurl = http://download.fedora.redhat.com/pub/fedora/linux/core/?releasever/source/srpms/
Enabled = 0
Gpgcheck = 1
Gpgkey = file: // etc/pki/rpm-GPG-key-Fedora
File: // etc/pki/rpm-GPG/RPM-GPG-KEY


Currently, the yum method I know is not necessarily accurate. Yum checks baseurl, repodata, and repomd. xml. If this index file is not found
Failed. Therefore, pay attention to the addition of the software library, especially the 3rd-party software library.

Now we have added a software library named rpm.livna.org.
Write according to the above format
[Livna]
Name = livna $ releasever-$ basearch
Baseurl = http://rpm.livna.org/fedora/5/i386/ of course you can use it here
Http://rpm.livna.org/fedora/?releasever/?basearch/

Enabled = 1
Gpgcheck = 1
Gpgkey = http://rpm.livna.org/RPM-LIVNA-GPG-KEY-i386
Save as livna. repo.
Currently, yum install mplayer
Download an mplayer. (It is very suitable for a guy like mplayer dual, but the operability is too bad)
Note: 1. Check whether/repodata/repomd. xml. exists under your selected base address.

2. You can also download the gpgkey to a local file. It is usually stored in the file: // etc/pki/rpm-GPG/directory.
Yum Command Parameters
Install
Yum install software name
List
Yum list I less
Search
Yum provides software name
Single software upgrade
Yum Update Software name
Upgrade all
Yum Update (this command takes a very long time. I am afraid it will take a week)
Delete the installed software package
Yum clean packages (this command will delete all the packages you saved in the/var directory)
D: Use yum for automatic updates.
First, yum is a service.
[Root @ localhost ~] # Chkconfig -- list yum
Yum 0: Close 1: Close 2: Close 3: Close 4: Close 5: Close 6: Close
Then let him run automatically in 3 and 5 modes.
[Root @ localhost ~] # Chkconfig -- level 35 Yum on
[Root @ localhost ~] # Chkconfig -- list yum
Yum 0: Disable 1: Disable 2: Disable 3: Enable 4: Disable 5: Enable 6: Disable
In this way, you can automatically run Yum at startup. (If you haven't updated it for too long, do not use this method)

 

 

 

Use RPM to install and manage software packages
Describes the parameters.
-U upgrade, including installation
-F Refresh: all updates, excluding Installation
-V displays detailed information,-VV displays more detailed information
-H: displays the file release progress.
-- Force force installation. Here, force installation does not ignore dependencies, but forces the installation of old versions or old software packages.
-- Nodeps ignores dependencies, Which is unreliable.
-- Ignorearch can be ignored by the Host Architecture. Is it really useful?
-E: delete a software package.
-Q query Software Package
-QA: list all installed software packages
-QF file: list the packages that the file belongs.
-Qi is used to list detailed information about the software package.
-QR codes are used to list dependencies of all software packages.
-Ql: list all files of a software package
-QD: list all files of the software package
-QC: list all the setting files of the software package.
-Qd lists information about uninstalled software packages.

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.