2013-09-13 00:34:09 +02:00
|
|
|
# Desc: Allows to update the operating system
|
|
|
|
|
|
|
|
# To fetch package list
|
|
|
|
apt-get update
|
|
|
|
|
|
|
|
# To download and install updates without installing new package.
|
2014-08-06 09:25:08 +02:00
|
|
|
apt-get upgrade
|
2013-09-13 00:34:09 +02:00
|
|
|
|
|
|
|
# To download and install the updates AND install new necessary packages
|
|
|
|
apt-get dist-upgrade
|
|
|
|
|
|
|
|
# Full command:
|
|
|
|
apt-get update && apt-get dist-upgrade
|
2013-12-03 21:20:11 +01:00
|
|
|
|
|
|
|
# To install a new package(s)
|
|
|
|
apt-get install package(s)
|
2014-04-18 11:23:23 +02:00
|
|
|
|
|
|
|
# Download a package without installing it. (The package will be downloaded in your current working dir)
|
|
|
|
apt-get download modsecurity-crs
|
|
|
|
|
|
|
|
# Change Cache dir and archive dir (where .deb are stored).
|
|
|
|
apt-get -o Dir::Cache="/path/to/destination/dir/" -o Dir::Cache::archives="./" install ...
|
2014-04-18 18:04:25 +02:00
|
|
|
|
|
|
|
# Show apt-get installed packages.
|
2014-04-21 23:15:09 +02:00
|
|
|
grep 'install ' /var/log/dpkg.log
|
2015-09-04 10:08:42 +02:00
|
|
|
|
|
|
|
# Silently keep old configuration during batch updates
|
|
|
|
apt-get update -o DPkg::Options::='--force-confold' ...
|