Debian Update source Format explanation

Source: Internet
Author: User

After installing the Debian operating system, the first thing you do is probably to modify the Source.list file, or you can not update the software online, then source.list files in the specific meaning of each configuration item you understand it. Here is my source.list file as an example for you to explain.

Deb Http:// main Non-free contribdeb Wheezy-proposed-updates main Non-free contribdeb-src Http:// main Non-free CONTRIBDEB-SRC main Non-free contrib

Each line can be divided into four parts, in other words, when you update a software online, Debian is following these four options (exactly the latter three) instructions to find the software to install for you:

Deb    ###   ftp address                         ###  version Code   ###  qualifiers deb    ###  Wheezy    ###   main Non-free contrib

of which, 1. The first part

The first part is Deb or DEB-SRC, where the former represents the location of the software, which represents the location of the source code for the Software 2. Part Two

The second part for your FTP mirror URL, to my example, I was using the mainland faster than the NetEase mirror. When you open this link in a browser, you will find the following:


The/dists/directory contains a "release" (distributions), which is a regular way to obtain a Debian release (releases) and a released version (pre-releases) package. Some old packages and packages.gz files are still inside.

The/pool/directory is the physical address of the package. Packages are placed in a large pool, sorted by source package name. For ease of management, the pool directory is categorized by attributes ("main", "contrib", and "Non-free"), and the categories are archived under the first letter of the source code name. These directories contain files that are binary packages running on a variety of system architectures, generating source packages for these binary packages. You can execute the command apt-cache showsrc mypackagename, see the ' Directory: ' line to find out where each package resides. For example: The Apache package is stored in the pool/main/a/apache/directory. In addition, because of the large number of lib* packages, they are archived in a special way: for example, libpaper packages are stored in pool/main/libp/libpaper/.

There are also directories:/tools/: Used to create boot disks, disk partitions, compress/unzip files, and start Linux under DOS for a handyman. /doc/:

Basic Debian documentation, such as FAQ, error Reporting system guidance, etc... /indices/:

Maintain personnel files and overloaded files. /project/:

Most of the resources for developers, such as: project/experimental/

This directory contains software packages and tools that are in development, both in the alpha test phase. Users should not use these software because even experienced users can be messed up. 3. Part III

The third section indicates your Debian version number (note that it is not the version number of the software, but the version of Debian itself), and some people call it a horizontal division of the Debian package (this is a relatively image), how to write a specific item, you can refer to http:// The contents of the page (pictured below), in general, by the version of the old--> new degree there are several major categories: Oldstable,stable,testing,sid

1.oldstable as the name suggests, is the previous stable distribution, in this case oldstable is a link to the Debian6.0.8 directory, the contents of the two exactly the same.

2.stable is the current stable distribution, for each Debian, each stable release will have a code, such as Debian 6 is called Squeeze,debian 7 is called wheezy, because in the author of this article when the stable version is Debian7, So stable is a link to wheezy.

3.testing refers to the currently in the test phase of the Debian release, such as Wheezy down the development is Jessie, so testing refers to the Jessie directory, it is a link jessie.

4.unstable that's the unstable version, but we don't see the unstable directory in this list, but there's also a code name: SID, we know that most of the release versions of Debian come from the role names in Toy Story, And Sid was the bad kid in the neighborhood who was destroying toys. So the unstable this unstable software directory named SID, which software is generally the latest, stability, security and stability is debatable, if you want to do experiment mice, can use the software here. After a period of testing, the software may go into the next phase of the testing directory to appear in the next Debian release, or it will be abandoned outright. 4. Part Fourth

Well, from a horizontal perspective on the Debian release, now we go into these directories and look at what's inside (take the stable directory for example):

We will find that each directory will include contrib, main, non-free and so on several directories, then these directories are what dongdong.

look at the distribution of Debian software in a vertical view: Main, contrib, Non-free, non-us
Because Debian is not a non-profit organization, but the organization is rigorous, a complete set of software management methods. Based on its adherence to the software free degree, there are some limitations to the entry of different copyright packages.
Here are some brief descriptions of them:
MainThe most basic and primary software in Debian that complies with the Free Software specification (packages).
ContribThe head software can operate in Debian, even though it is free software but mostly dependent on Non-free software.
Non-freeSoftware that is not part of the free software category.
non-usThe software in this category comes from non-US regions, where patents and encryption may be involved. And so on.
Marillatcorresponding {sensitive word} Marillat software warehouse, including MPlayer, transcode, etc.
Rarewarecorresponding to the of the software warehouse, including many sound programs, such as Lame, musepack, beep Media Player and so on.
USTCSome packages corresponding to DEBIAN@USTC maintenance, such as MULE-GBK, Gaim-openq, SCIM, stardictdicts, patched xpdf, Irssi, Xmms.
Corresponds to Blackdown java. including J2re, J2SDK, Mozilla Java plugin.
FireflyMatching packages that have been patched Firefly, including fontconfig Mozilla mozilla-firefoxpango1.0 Qt-x11-free xft
MiscCorresponding to other unclassified packages, including Nvidia-kernel,winex3, Rox, Chmsee, etc.5. On the mixing problem of source

It is generally not recommended to mix stable, testing and unstable sources. Because many software have different degree of dependency, forced results will result in more software dependencies, repel problems, and ultimately may affect the system stability and the entire software upgrade system normal operation.
The need to move the source from low to advanced is very simple, just modify the source in the sources.list. But conversely, demotion is an almost impossible task ... If you're using a high version of Debian, And in the Source.list file is configured with a low version, then when you install the software online is likely to find a lot of software dependencies problems can not be resolved, when these problems, it is necessary to think about whether to modify the Source.list file in the version of the problem 6. Modify your sources.list on Demand

Debian has its own unique version of the system, the entire system has three versions, respectively, stable version (Stable), beta (testing) and unstable version (UNSTABLE/SID). Each release is a stable version, and the beta is a new stability after a period of testing that shows no problems. Because the stable version is updated, in order to facilitate the distinction between the stable version of different periods, each version has its own unique code name (codename), now the stable version called Wheezy (DEBIAN7), the beta version called Jessie. And the unstable version of the code is always SID.
The writing of Sources.list
Find the directory containing both dists and pool , and write down the address, such as;

2) Open Dists, which contains the name of the directory, write it down. For example,,dists/contains wheezy, testing, etc. Write down these catalogue names.

3) Open the pool directory to see which components are included in the directory, such as Main, contrib, Non-free;

4) Writing format:deb<1 down the address ><2 down the directory name ><3 down the name >, such as:
Deb Http:// wheezy man contrib non-free 7. Update package list information, upgrade Debian

After you modify/etc/apt/sources.list, you will typically run the following two commands for an update upgrade:
sudo apt-get update
sudo apt-get dist-upgrade
Update-Retrieve updated package list information
Dist-upgrade-Release upgrade
The first command updates only the package list information, so it will be done quickly.
The second command is a comprehensive update of the release, which typically downloads hundreds of trillion new packages.
In fact, after running the first command system will prompt you to update the upgrade. Because the source has been modified, all changes to this update may be very large, such as installing a package may remove too many other packages, all systems will prompt you to run "sudo apt-get dist-upgrade" for a full upgrade Or use the "tag all packages for Upgrade" feature in Package Manager to upgrade. The two effects are the same.

This article is original, reproduced please indicate the source:

Reference Links:



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: 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.