dpkg | add-apt-repository | apt-cache search packagename | apt-get useful commands | apt-cache madison apache2

Show available apache versions
apt-cache madison apache2

/etc/apt/sources.list

Installing Skype

Users of 64-bit Ubuntu, should enable MultiArch if it isn't already enabled by running the command 
sudo dpkg --add-architecture i386
Since Ubuntu 10.04 (Lucid Lynx), Skype is part of the Canonical partner repository. To install Skype add the Canonical Partner Repository. You can do this by running the command 
sudo add-apt-repository "deb http://archive.canonical.com/ $(lsb_release -sc) partner"
Then install Skype via the Software-Center or via the Terminal. 

sudo apt-get update && sudo apt-get install skype

=======================================
The apt-cache command can display much of the information stored in APT's internal database. This information is a sort of cache since it is gathered from the different sources listed in the sources.list file. This happens during the apt update operation.

ubuntu@ubuntu:~/.ssh$ apt-cache search skype
libopus-dev - Opus codec library development files
libopus0 - Opus codec runtime library
empathy-skype - Skype plugin for libpurple messengers (Empathy-specific files)
pidgin-skype - Skype plugin for libpurple messengers (Pidgin-specific files)
pidgin-skype-common - Skype plugin for libpurple messengers (common files)
pidgin-skype-dbg - Skype plugin for libpurple messengers (debug symbols)
libopus-ocaml - OCaml interface to the opus library -- runtime files
libopus-ocaml-dev - OCaml interface to the opus library -- developpement files
libsipwitch-dev - secure peer-to-peer SIP VoIP server - development files
libsipwitch1 - secure peer-to-peer SIP VoIP server - shared libraries
libsipwitch1-dbg - secure peer-to-peer SIP VoIP server - debug symbols
sipwitch - secure peer-to-peer VoIP server for the SIP protocol
sipwitch-cgi - secure peer-to-peer SIP VoIP server - CGI XML-RPC interface

===========================
To list all the available packages, type the following command.
$ apt-cache pkgnames
esseract-ocr-epo
pipenightdreams
mumudvb
tbb-examples
libsvm-java
===========================
To find and list down all the packages starting with ‘vsftpd‘, you could use the following command.
$ apt-cache pkgnames vsftpd
===========================
How Do I Check Package Information?
For example, if you would like to check information of package along with it short description say (version number, check sums, size, installed size, category etc). Use ‘show‘ sub command as shown below.
$ apt-cache show netcat
Package: netcat
Priority: optional
Section: universe/net
Installed-Size: 30
Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com>
Original-Maintainer: Ruben Molina <rmolina@udea.edu.co>
===========================
How Do I Check Dependencies for Specific Packages?
Use the ‘showpkg‘ sub command to check the dependencies for particular software packages. whether those dependencies packages are installed or not. For example, use the ‘showpkg‘ command along with package-name.
$ apt-cache showpkg vsftpd
Package: vsftpd
Versions: 
2.3.5-3ubuntu1 (/var/lib/apt/lists/in.archive.ubuntu.com_ubuntu_dists_quantal_main_binary-i386_Packages)
Description Language: 
File: /var/lib/apt/lists/in.archive.ubuntu.com_ubuntu_dists_quantal_main_binary-i386_Packages
MD5: 81386f72ac91a5ea48f8db0b023f3f9b
How Do I Check statistics of Cache
The ‘stats‘ sub command will display overall statistics about the cache. For example, the following command will display Total package names is the number of packages have found in the cache.
$ apt-cache stats
Total package names: 51868 (1,037 k)
Total package structures: 51868 (2,490 k)
Normal packages: 39505
Pure virtual packages: 602
===========================
How to Update System Packages
The ‘update‘ command is used to resynchronize the package index files from the their sources specified in /etc/apt/sources.list file. The update command fetched the packages from their locations and update the packages to newer version.
$ sudo apt-get update
[sudo] password for tecmint: 
Ign http://security.ubuntu.com quantal-security InRelease                      
Get:1 http://security.ubuntu.com quantal-security Release.gpg [933 B]   
===========================
How to Upgrade Software Packages
The ‘upgrade‘ command is used to upgrade all the currently installed software packages on the system. Under any circumstances currently installed packages are not removed or packages which are not already installed neither retrieved and installed to satisfy upgrade dependencies.
$ sudo apt-get upgrade
Reading package lists... Done
Building dependency tree       
Reading state information... Done
How Do I Install or Upgrade Specific Packages?
The ‘install‘ sub command is tracked by one or more packages wish for installation or upgrading.
$ sudo apt-get install netcat

How to install Packages without Upgrading
Using sub ‘–no-upgrade‘ command will prevent already installed packages from upgrading.
$ sudo apt-get install packageName --no-upgrade
How to Upgrade Only Specific Packages
The ‘–only-upgrade‘ command do not install new packages but it only upgrade the already installed packages and disables new installation of packages.
$ sudo apt-get install packageName --only-upgrade

How Do I Install Specific Package Version?
Let’s say you wish to install only specific version of packages, simply use the ‘=‘ with the package-name and append desired version.
$ sudo apt-get install vsftpd=2.3.5-3ubuntu1
How Do I Remove Packages Without Configuration
To un-install software packages without removing their configuration files (for later re-use the same configuration). Use the ‘remove‘ command as shown.
$ sudo apt-get remove vsftpd
How Do I Completely Remove Packages
To remove software packages including their configuration files, use the ‘purge‘ sub command as shown below.
$ sudo apt-get purge vsftpd
How Can I Download, Unpack and Compile a Package
You can also download, unpack and compile the source code at the same time, using option ‘–compile‘ as shown below.
$ sudo apt-get --compile source goaccess

Comments

Popular posts from this blog

HAproxy logging

tomcat catalina coyote jasper cluster

NFS mount add in fstab _netdev instead of default | firewall-cmd --list-all