Table of Contents
Repositories
On Ubuntu, Software is getting installed via so called packages. Most of these packages are organized in repositories. A repository is basically a list of available software packages it is responsible for, normally located on a remote computer (therefore it often has a website-like address). The repository is providing information about packages for your OS (where to download the software, who created it and stuff like that).
The Advanced Packaging Too (APT) has got a lists with addresses of repositories it should keep track of (=it is mirroring them on your local machine). Where and how these lists are managed is covered on this page.
Terms
Launchpad
PPA
The repository address syntax
Every repository address consists of the following:
- Type:
deb
ordeb-src
.
deb
-repositories are distributing binary packages,deb-src
are distributing the source code of the binary packaes (useful if you want to compile the software at your own, helping you to resolve dependencies and getting all needed source code). If you do not want to compile software on your own, you do not need anydeb-src
repositories in general (you may use#
within.list
files to comment unneeded repositories out). - Location: Normally a web address like
http://de.archive.ubuntu.com/ubuntu
.
cdrom:
,ftp://
,file:
andcopy:
locations are also possible. - Distribution: The lowercase codename of your Ubuntu distribution (e.g.
karmic
,jaunty
orlucid
).
This makes it possible for the repository to serve the correct version of a package for the Ubuntu version you are using. If you are note sure about the codename of your Ubuntu, have a look at “How to check which Ubuntu release is installed (including codename)”.
Example of a complete repository address:
deb http://archive.canonical.com/ubuntu karmic partner
Where does Ubuntu store the repositories it should keep track of?
apt
is the Ubuntu package manager and therefore responsible to communicate with the repositories. To store the used repositories, .list
files are used:
/etc/apt/sources.list
is the central repository list. You should not touch this file!
The list was created when you installed your system, enabling you to basically use your OS. Changing this file is a bad idea because it may gets overwritten when you are updating the system.- User-generated
*.list
files within the/etc/apt/sources.list.d/
directory are considered automatically.
E.g. utilities likeadd-apt-repository
are placing.list
files in here.
If you want to add a third-party repository, see “Adding new repositories”.