How do I find packages to install via apt-get

259,981

Solution 1

I always use packages.ubuntu.com

Also you can use apt-cache search for command-line searching. Or you can use the GUI package manager (Ubuntu Software Center / Synaptic) for searching software.

Solution 2

If you search for "nvidia settings".

apt-cache search nvidia settings

The output is:

nvidia-settings - Werkzeug für die Konfiguration des NVIDIA-Grafiktreibers
nvidia-settings-updates - Tool of configuring the NVIDIA graphics driver

You see 2 packages nvidia-settings and nvidia-settings-updates.

To find the related binary to the package nvidia-settings.

dpkg -L nvidia-settings | grep bin

The output is:

/usr/bin
/usr/lib/nvidia-settings/bin
/usr/lib/nvidia-settings/bin/nvidia-settings

nvidia-settings is the binary name to start the program.

Solution 3

With binaries in particular there is an application that is automatically run if you run a command that is not installed. For example,

$ bonnie++
The program 'bonnie++' is currently not installed.  You can install it by typing:
sudo apt-get install bonnie++

Other than that, there are searches: apt-cache search <query> or aptitude search <query> which can be preferable if you want to get really involved with filters.

Solution 4

You can try the program 'aptitude' from the command line. It is a graphical package manager. Remember to append sudo to the program to do any real installations. 'sudo aptitude'. You can also use aptitude just like apt-get; "sudo aptitude install". I prefer apt-get for single packages that I know the names for.

Also, are you just on a command line? If you have a desktop you can use System -> Preferences -Synaptic, or the Ubuntu Software Center. They function nearly the same however they have a simpler package search.

Solution 5

I think, you are referring to the binary program name included in the package. I use this technique to find this:

simply type dpkg -L <package-name> in a terminal, it will display all files installed by that package, then you can recognize the binary program names by looking at their location. Usually programs are installed in /usr/bin directory or /sbin directory.

Let's see an example:

anwar@edubuntu-lenovo:~$ dpkg -L gnome-screenshot 
/.
/usr
/usr/bin
/usr/bin/gnome-screenshot
/usr/share
/usr/share/GConf
/usr/share/GConf/gsettings
/usr/share/GConf/gsettings/gnome-screenshot.convert
/usr/share/applications
/usr/share/applications/gnome-screenshot.desktop
/usr/share/man
/usr/share/man/man1
/usr/share/man/man1/gnome-screenshot.1.gz
/usr/share/gnome-screenshot
/usr/share/gnome-screenshot/gnome-screenshot.ui
/usr/share/glib-2.0
/usr/share/glib-2.0/schemas
/usr/share/glib-2.0/schemas/org.gnome.gnome-screenshot.gschema.xml
/usr/share/doc
/usr/share/doc/gnome-screenshot
/usr/share/doc/gnome-screenshot/copyright
/usr/share/doc/gnome-screenshot/NEWS.gz
/usr/share/doc/gnome-screenshot/changelog.Debian.gz

Note that, the program name of gnome-screenshot package is gnome-screenshot.

You asked

Is there any standard way to know the <packageName> for the desired program?

Sometimes the terminal can tell your the package name required to be installed to have a desired program. It happens when the program is in Standard repository and you have enabled those repository.

For example, If I type gnome-documents when no such package is installed, the terminal will tell be this:

anwar@edubuntu-lenovo:~$ gnome-documents
The program 'gnome-documents' is currently not installed.  You can install it by typing:
sudo apt-get install gnome-documents

But, in this case, I should at least know the program name

Share:
259,981

Related videos on Youtube

Ricardo Deano
Author by

Ricardo Deano

Love all things front-end web programming. Also forced to use svn,sql and other stuff for my daily job :-)

Updated on September 17, 2022

Comments

  • Ricardo Deano
    Ricardo Deano almost 2 years

    After doing a man apt-get and cursory Google search it's not clear how I find new programs to install (from the internet) using apt-get (which is amazingly powerful and simple coming from another Linux distro).

    I'm using Ubuntu Server 8.04 LTS (an inherited system used for some random work), so no GUI.

    Anyone have quick advice here?

  • msw
    msw almost 14 years
    I find the Software Center most useful with Google a close second when I know what I want but don't know a package name. (And the Meerkat Software Center is new, improved and more Googly).
  • Ricardo Deano
    Ricardo Deano almost 14 years
    Is the software center new to Lucid Lynx? I have an older image I inherited (Ubuntu Server 8.04 LTS)
  • Ricardo Deano
    Ricardo Deano almost 14 years
    Hmm.. just tested this doesn't seem to work, when I double tab, it seems to want to complete the command with a local file (ex: i see .aptitude .bashrc .bash_history ... )
  • NightwishFan
    NightwishFan almost 14 years
    r00fus - It became included in Ubuntu 9.10 I believe.
  • dv3500ea
    dv3500ea almost 14 years
    That's strange, I get Display all 39603 possibilities? (y or n) which gives a list of packages.
  • Sam
    Sam almost 12 years
    Yah it is similar but not same Because he just wants to find new programs/packages... While in my case I know the package names and I want to know there apt-get names...i.e. as in the example I know the package name: "NVIDIA X Server Settings"(actual name) And want to know apt-get name: "nvidia-settings"
  • Adi Shavit
    Adi Shavit almost 6 years
    How do I "import" a package from packages.ubuntu.com?
  • Pablo Bianchi
    Pablo Bianchi over 2 years
    Also there is just apt search ...