Mohamed Abd El Fatah Mohamed Abd El Fatah - 1 month ago 4x
Linux Question

Installing programs on Linux terminal

When I tried to install arduino on ubuntu, arduino site says that I can install it through terminal by typing these commands

sudo apt-get update && sudo apt-get install arduino arduino-core

And generally in Linux Debian we can install programs using terminal by typing

sudo apt-get install ${program-name}

The question is how could I know the ${program-name} needed to install without going to the program installation guide to copy the code?


The apt-cache command line tool is used for searching apt software package cache. In simple words, this tool is used to search software packages, collects information of packages and also used to search for what available packages are ready for installation on Debian or Ubuntu based systems.

To find out the package name and with it description before installing, use the ‘search‘ flag. Using “search” with apt-cache will display a list of matched packages with short description. Let’s say you would like to find out description of package ‘vsftpd‘, then command would be.


apt-cache search SearchTerm
$ apt-cache search vsftpd

The possible output would be:

vsftpd - lightweight, efficient FTP server written for security
ccze - A robust, modular log coloriser
ftpd - File Transfer Protocol (FTP) server
yasat - simple stupid audit tool

To find and list down all the packages starting with ‘vsftpd‘, you could use the following command.

$ apt-cache pkgnames vsftpd

You may also want to run the results through a more, or even a grep. For instance:

apt-cache search firefox | grep plugin