Posts Tagged ‘apt’

Debian(Ubuntu) Package Management Hack

Tuesday, February 19th, 2008

For those of us using the Debian package management systems, i.e. anyone using “apt-get” or Synaptic for management, there’s a better way to organize your repository sources. Here’s a simple tutorial to keep your repository lists more organized.

read more | digg story

My Current APT sources.list File

Saturday, February 9th, 2008

I currently run Debian lenny/sid using the Linux kernel ver. 2.6.24-1

I use the Linux packages MythTV and Webmin on all my systems, these require additional source entries in the APT file sources.list it should reside in the /etc/apt/ directory.

#stable=etch,testing=lenny,untested=sid
deb http://ftp.tiscali.nl/debian/ stable main contrib non-free
deb http://ftp.tiscali.nl/debian/ testing main contrib non-free
deb http://ftp.tiscali.nl/debian/ unstable main contrib non-free
deb http://ftp.tiscali.nl/debian/ experimental main contrib non-free

#deb-src http://ftp.tiscali.nl/debian/ stable main contrib non-free

#deb-src http://ftp.tiscali.nl/debian/ testing main contrib non-free

#deb-src http://ftp.tiscali.nl/debian/ unstable main contrib non-free

#deb-src http://ftp.tiscali.nl/debian/ experimental main contrib non-free
deb http://security.debian.org/ stable/updates main
deb http://security.debian.org/ testing/updates main
#deb-src http://security.debian.org/ stable/updates main

#deb-src http://security.debian.org/ testing/updates main

deb http://www.debian-multimedia.org/ unstable main

deb http://download.webmin.com/download/repository sarge contrib

Note the leading # omitting the deb-src lines - I only once needed to use apt-get source, when it was required I simply temporarily removed the leading # from the deb-src lines ran apt-get update and installed the source code required.

The experimental source in the list wont be used unless specified e.g. apt-get -t experimental install package_name - KDE4 can be install via APT using this method e.g. apt-get -t experimental install kde4-minimal

After adding a few extra sources to the sources.list file, running apt-get update will more than lightly give out the following error:

Reading Package Lists… Error!
E: Dynamic MMap ran out of room

This can be suppressed by creating/editing the file /etc/apt/apt.conf and including the following code:

APT::Cache-Limit 102582912;

^The number after Cache-Limit can be set higher(if needed)

Acquire::http::Proxy "http://192.168.1.150:3142/";

^If you would like to cache all the packages you download like me install apt-cacher somewhere or something similar, then add the proxy address and port as above on a new line in your apt.conf file.

APT::Default-Release "unstable";

^Not required but a great way to keep your base system running a stable release, and still have the ability to install testing or unstable packages is to use the above(although it would make more sense to have stable or testing here instead of unstable)

Here is my full apt.conf file:

Acquire::http::Proxy "http://192.168.1.150:3142/";
APT::Cache-Limit 102582912;
APT::Default-Release "unstable";

EDIT(24/03/09):Once sources.list and apt.conf is in place run

apt-get update ; apt-get install debian-multimedia-keyring ; apt-get update

Now your ready to upgrade.

Stop APT(Advanced packaging tool for debian) from giving GPG errors

Saturday, February 2nd, 2008

Since Debian’s 0.6 version of apt package signatures have been checked. Adding a new repository source e.g.

deb http://packages.kirya.net/debian/ sid main contrib non-free

to your /etc/apt/sources.list file and running the command apt-get update you would most probably get the following error in the output :

W: GPG error: http://packages.kirya.net sid Release: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY EEFB43B2FBABB737
W: You may want to run apt-get update to correct these problems

Now the repositories website is the first place I would look for instructions to import the key, if this is not an option I would try this :
Required Packages:

apt-get install debian-archive-keyring apt-key

run as root(or use sudo):

sudo gpg --keyserver hkp://wwwkeys.eu.pgp.net --recv-keys EEFB43B2FBABB737

this gave me:

gpg: requesting key FBABB737 from hkp server wwwkeys.eu.pgp.net

use the key from the output to run:

sudo gpg --armor --export FBABB737 | sudo apt-key add -

If all goes well output should be: OK
Now run

apt-get update

and enjoy the new repository :)

I’m not sure how correct this method is but so far for me it has worked without any issues.