Tip: Set a local update source for Fedora Linux 8

Source: Internet
Author: User
Tags rsync

 

After the installation of coreora Core8 is complete, you must use yum to update and add the yum update source. The update that comes with the system is extremely slow and impossible.

The following describes how to use httpd.

Install the httpd package:

# Yum install httpd

# Chkconfig httpd on

# Service httpd start or #/etc/init. d/httpd start

Install the createrepo Toolkit:

# Yum install createrepo

Then create the fedora8 package directory and update the package directory:

# Mkdir-p/var/www/html/yum/base/8/i386

# Mkdir-p/var/www/html/yum/updates/8/i386

If a CD is available, copy all rpm software packages to the/var/www/html/yum/base/8/i386 directory:

# Cd/misc/cd/Packages; cp-V */var/www/html/yum/base/8/i386

# Cd

Or go to the terminal:

       
        rsync -avrt rsync://ftp-stud.hs-esslingen.de/fedora/linux/releases/8/Everything/i386/os/Packages//var/www/html/yum/base/8/i386
       

Note that the red part must be a/symbol;

Run the createrepo command:

# Createrepo/var/www/html/yum/base/8/i386

This command will create a repodata folder in the/var/www/html/yum/base/8/i386 Directory, which contains the following files:

# Ls-l/var/www/html/yum/base/8/i386/repodata/

Total 9268

-Rw-r -- 1 root 2227275 2008-01-12 21:11 filelists.xml.gz

-Rw-r -- 1 root 6487453 2008-01-12 21:11 other.xml.gz

-Rw-r -- 1 root 747714 2008-01-12 21:11 primary.xml.gz

-Rw-r -- 1 root 951 2008-01-12 21:11 repomd. xml

Next, go to the/var/www/html/yum/updates/8/i386 directory and download the latest rpm package in the rsync directory:

Rsync-avrt rsync: // ftp-stud.hs-esslingen.de/fedora/linux/updates/8/ I #/ -- exclude = debug // var/www/html/yum/updates/8/i386

Set crontab to automatically download the latest software package:

23 4 */2 **/usr/bin/rsync-avrt

Rsync: // ftp-stud.hs-esslingen.de/fedora/linux/updates/8/ I/

-- Exclude = debug // var/www/html/yum/updates/8/i386

Finally, go to the/etc/yum. repos. d/directory and create a file ending with repo, as shown below:

       
        [base-local]name=Fedora $releasever - $basearchfailovermethod=prioritybaseurl=http://192.168.0.100/yum/base/$releasever/$basearch#mirrorlist=http://mirrors.fedoraproject.org/mirrorlist?repo=fedora-$releasever&arch=$basearchenabled=1gpgcheck=0[updates-local]name=Fedora $releasever - $basearch - Updatesfailovermethod=prioritybaseurl=http://192.168.0.100/yum/updates/$releasever/$basearch/#mirrorlist=http://mirrors.fedoraproject.org/mirrorlist?repo=updates-released-f$releasever&arch=$basearchenabled=1gpgcheck=0
       

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.