Currently there are above 45,000 packages in Debian repository and even more in Ubuntu. Both of them has much larger software collection than any other GNU/Linux distributions.
But there is a problem, due to slow Debian/Ubuntu release cycle softwares are somewhat outdated, though this is fine in most cases.
This problem is more with a third party software that is closed source or not officially available at by Debian/Ubuntu repository, like non-free graphics drivers, third party themes, fonts etc.
There are many possible solutions, like
- Use a rolling release distribution like Arch Linux or Gentoo .
- Compile the latest software from source .
- Use Debian testing or unstable repository .
etc. etc. But none of them is the best solution and not good for a stable everyday use workstation.
So how can you enjoy a latest software in Debian stable or Ubuntu ? The answer is Debian backports and Ubuntu PPAs .
Contents
what is Debian backports ?
Debian backports are basically packages from the next Debian release, i.e. Debian testing packages adjusted and recompiled for usage on Debian stable.
The packages are well tested in Debian stable , but there is a risk of incompatibilities with other components in Debian stable. read more about Debian backports here.
what is Ubuntu PPA ?
The word PPA stands for Personal Package Archive , an Ubuntu specific repository hosted by Launchpad . PPAs mainly contain updated third binary packages and packages provided by a team or by many individual persons.
Before continue, lets have a look on the /etc/apt/sources.list file, this part is taken from our apt for beginners tutorial.
The /etc/apt/sources.list file contains a list of software package source, one of the most vital file for installing or updating anything with apt. The sources.list file could have many active sources and a supports a wide range of of source media like a HTTP or FTP server, from a local filesystem, a CD/DVD ROM even from a SSH server. The entries in sources.list file normally looks like bellow.
file type: Or archive type, the first word of each line , either deb or deb-src , deb for pre-compiled binary packages and deb-src for original software source code file with some debian specific components. The deb file type is most used.
repository URL: This is the URL from where software packages will be downloaded. It may be different for different type of sources.
distribution: Your Current distribution name, like sid , stretch , jessie , wheezy
etc. for Debian and precise , trusty
etc. for Ubuntu.
Component: Type of software sources, like main , contrib , non-free , universe , multiverse
etc.
main : The Debian main software source, which contains only Debian specific free softwares only, no third party dependency.
contrib : Contributed by other projects, may have third party dependency.
non-free : This repository contains closed source and reverse engineered closed source software, like non-free graphics drivers, Win-RAR , NTFS-3G etc. etc.
universe : This repositary is Ubuntu specific, contains a mix of free and non-free software.
multiverse : This one is Ubuntu specific too, contains a large software collection, these softwares are not maintained by Ubuntu.
After changing any line of /etc/apt/sources.list file, running apt-get update
is necessary to make the changes available.
Install latest backported software in Debian
first add the backport repositary
If you are running Debian stable, currently jessie , add the bellow line to /etc/apt/sources.list file .
deb http://ftp.us.debian.org/debian jessie-backports main contrib non-free
if you are using Debian old stable , i.e. whezzy , then add
deb http://ftp.us.debian.org/debian wheezy-backports main contrib non-free
You could use any repository mirror of your choice, from this list . Now run sudo apt-get update
to make changes available,
Then install your desired software,
sudo apt-get -t whezzy-backports install your_package_name # exemple sudo apt-get -t whezzy-backports install linux-image-3.16.0-0.bpo.4-amd64 # install backported Linux kernel 3.16
To remove a Debian backports repository , remove or comment out (add a # before the line) correct line in the /etc/apt/sources.list file.
how to install latest software from Ubuntu PPA
PPA repositories are managed with add-apt-repository and ppa-purge , no need to manually edit the /etc/apt/sources.list
file.
To add a PPA repository, run the command listed below.
sudo add-apt-repository ppa:(ppa_source/ppa_name) # example sudo add-apt-repository ppa:ubuntu-x-swat/x-updates # the above is the PPA for latest Ubuntu Xorg repository
Now run sudo apt-get update
to make changes available, then install your desired software.
How to remove a PPA
Remove a PPA with ppa-purge command.
sudo ppa-purge ppa:(ppa_source/ppa-name) # example sudo ppa-purge ppa:ubuntu-x-swat/x-updates
This command will remove a PPA and packages from this PPA will be replaced by default Ubuntu packages. Read more about Ubuntu package management here.
Conclusion
Hope this tutorial will help you to install latest software in Ubuntu or Debian, If you need any further assistance just leave a comment, we’d be happy to assist you.
Feel free to share this tutorial with your friends.
Leave a Reply