Debian image source server setup

Source: Internet
Author: User

How to Create a Debian image website? There has been a special Introduction On Debian's official website: http://www.debian.org/mirror/ftpmirror

Before you create an image for Debian, you must consider the following: to what extent are you preparing for the Debian image, or how big is your hard disk? Do some Debian resources that we rarely use require images? If the entire Debian image requires about GB of hard disk space, the woody sarge Sid software for each CPU architecture adds up to about 6-8 GB.

[Edit]

Method 1: Use debmirror for simple implementation

The official solution is based on the rsync software, and the webpage also provides ready-to-use scripts for website images. However, implementation is troublesome and often fails. Using debmirror for Debian images should be simpler.

Debmirror is a German Debian website image tool written in Perl, Which is simpler and more convenient to use. By default, debmirror uses FTP (rsync or HTTP) to obtain all Debian content to the local disk, then, the local machine is set to a valid apt source through the system's HTTP server or FTP server. Other customers modify their Debian system's/etc/sources. the list file points to the machine.

Let's take a look at the specific process:

1. Install debmirror Software

#apt-get install debmirror

2. Run the debmirror software to obtain the Debian software package.

Before that, you need to decide the directory where your Debian software package is stored on the hard disk. This is a required parameter for running debmirror. For example:

 #debmirror /mydebian

It means to mirror the entire Debian to the/mydebian directory of my computer with all the default parameters. Ah, 100g! How long will it take to download! Obviously it is unrealistic. We need to use some other parameters to adjust our image process. There are many optional parameters for debmirror. You can:

#man debmirror

To view, the following describes several important:

-V: detailed steps to display the image. It is best to choose from and keep abreast of the trend of debmirror.
-H: from which the Debian software package is downloaded. The default value is ftp.debian.org. In China, I 'd like to use debian.cn99.com.
-D: determines the Debian version of the image. I like tolerance and select sarge. All are selected by default.
-S: determines which part of the image Debian, that is, select one of main, contrib, and non-free. All are selected by default.
-A: select the computer architecture mode. The default value is i386.
-- Nosource: by default, debmirror downloads the source code of the Debian package together. This parameter prohibits the download of the source code.

If I want to be the simplest Debian source, from the fastest Debian website around me, the main software packages of the Sid, Sarge, testing, unstable, and stable of the image i386, arm, and amd64 computers also contain the source code. The downloaded package is placed in the debmirror directory and is release. when the download of the GPG and release files is incorrect, ignore and continue. The download command is:

debmirror -v -e http -h ftp.tw.debian.org -a i386,arm,amd64 -d
sid,sarge,testing,unstable,stable --ignore-release-gpg
--ignore-missing-release --nosource /debmirror

3. settings after download
I want to publish my Debian image via HTTP, first add a sentence after my httpd. conf:

Alias /debmirror /mydebian

Restart the Apache server with # apachectl restart.

4. Client Modification
Modify the/etc/APT/sources. list file and add or retain the file only:

deb http://your_ip/debmirror sarge main

Use # apt-Get update to update.

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.