How VPS - How to use/setup VPS
  • Home
  • Management guides
    • Web servers software
      • Directadmin
      • Hocvps Script
      • Centmin Mod
      • CWP
      • Kloxo-MR
      • Plesk
    • Control Panels
    • Securing VPS/Servers
      • SSL Certificates
      • Upgrading
      • Authentication
  • Operating System
    • CentOS
    • Fedora
    • Debian
    • Linux
    • Arch
    • BSD
    • CoreOS
  • Reviews
  • Coupon
    • Domain Coupon
    • Hosting Coupon
No Result
View All Result
  • Home
  • Management guides
    • Web servers software
      • Directadmin
      • Hocvps Script
      • Centmin Mod
      • CWP
      • Kloxo-MR
      • Plesk
    • Control Panels
    • Securing VPS/Servers
      • SSL Certificates
      • Upgrading
      • Authentication
  • Operating System
    • CentOS
    • Fedora
    • Debian
    • Linux
    • Arch
    • BSD
    • CoreOS
  • Reviews
  • Coupon
    • Domain Coupon
    • Hosting Coupon
No Result
View All Result
How VPS - How to use/setup VPS
No Result
View All Result
Home Operating System Linux

15 Examples of How to Use New Advanced Package Tool (APT) in Ubuntu/Debian

How VPS by How VPS
November 2, 2018
in Linux, Operating System
0
0
SHARES
33
VIEWS
Share on FacebookShare on Twitter

Contents

  1. 1. Installing a Package
  2. 2. Find Location of Installed Package
  3. 3. Check All Dependencies of a Package
  4. 4. Search for a Package
  5. 5. View Information About Package
  6. 6. Verify a Package for any Broken Dependencies
  7. 7. List Recommended Missing Packages of Given Package
  8. 8. Check Installed Package Version
  9. 9. Update System Packages
  10. 10. Upgrade System
  11. 11. Remove Unused Packages
  12. 12. Clean Old Repository of Downloaded Packages
  13. 13. Remove Packages with its Configuration Files
  14. 14. Install .Deb Package
  15. 15. Find Help While Using APT
  16. Summary

One important thing to master under Linux System/Server Administration is package management using different package management tools.

Different Linux distributions install applications in a pre-compiled package that contain binary files, configuration files and also information about the application’s dependencies.

Read Also: Learn 25 ‘apt-get’ and ‘apt-cache’ Command Examples in Debian based Systems

Package management tools help System/Server Administrators in many ways such as:

  1. Downloading and installing software
  2. Compile software from source
  3. Keeping track of all software installed, their updates and upgrades
  4. Handling dependencies
  5. and also keeping other information about installed software and many more

In this guide, we are going to look at 15 examples of how to use the new APT (Advanced Package Tool) on your Ubuntu Linux systems.

APT is a command-line based tool that is used for dealing with packages on a Ubuntu based Linux systems. It presents a command line interface to the package management on your system.

1. Installing a Package

You can install a package as follows by specify a single package name or install many packages at once by listing all their names.

$ sudo apt install glances
15 Examples of How to Use New Advanced Package Tool (APT) in Ubuntu/Debian

Install a Package

2. Find Location of Installed Package

The following command will help you to list all the files that are contained in a package called glances (advance Linux monitoring tool).

$ sudo apt content glances
15 Examples of How to Use New Advanced Package Tool (APT) in Ubuntu/Debian

Find Installed Package Files Location

3. Check All Dependencies of a Package

This will help you to display raw information about dependencies of a particular package that you specify.

$ sudo apt depends glances
15 Examples of How to Use New Advanced Package Tool (APT) in Ubuntu/Debian

Check Dependencies of Package

4. Search for a Package

The search option searches for the given package name and show all the matching packages.

$ sudo apt search apache2
15 Examples of How to Use New Advanced Package Tool (APT) in Ubuntu/Debian

Search For a Package

5. View Information About Package

This will help you display information about package or packages, run the command below by specifying all the packages that you want to display information about.

$ sudo apt show firefox
15 Examples of How to Use New Advanced Package Tool (APT) in Ubuntu/Debian

Show Package Information

6. Verify a Package for any Broken Dependencies

Sometimes during package installation, you may get errors concerning broken package dependencies, to check that you do not have these problems run the command below with the package name.

$ sudo apt check firefox
15 Examples of How to Use New Advanced Package Tool (APT) in Ubuntu/Debian

Check Package for Broke Dependencies

7. List Recommended Missing Packages of Given Package

$ sudo apt recommends apache2
15 Examples of How to Use New Advanced Package Tool (APT) in Ubuntu/Debian

View Recommended Missing Packages

8. Check Installed Package Version

The ‘version’ option will show you the installed package version.

$ sudo apt version firefox
15 Examples of How to Use New Advanced Package Tool (APT) in Ubuntu/Debian

Check Installed Package Version

9. Update System Packages

This will help you to download a list of packages from different repositories included on your system and updates them when there are new versions of packages and their dependencies.

$ sudo apt update
15 Examples of How to Use New Advanced Package Tool (APT) in Ubuntu/Debian

Update System Packages

10. Upgrade System

This helps you to install new versions of all the packages on your system.

$ sudo apt upgrade
15 Examples of How to Use New Advanced Package Tool (APT) in Ubuntu/Debian

Upgrade System

11. Remove Unused Packages

When you install a new package on your system, it’s dependencies are also installed and they use some system libraries with other packages. The after removing that particular package, it’s dependencies will remain on the system, therefore to remove them use autoremove as follows:

$ sudo apt autoremove
15 Examples of How to Use New Advanced Package Tool (APT) in Ubuntu/Debian

Remove Unwanted Packages

12. Clean Old Repository of Downloaded Packages

The option ‘clean’ or ‘autoclean’ remove all old local repository of downloaded package files.

$ sudo apt autoclean 
or
$ sudo apt clean
15 Examples of How to Use New Advanced Package Tool (APT) in Ubuntu/Debian

Clean Package Repository

13. Remove Packages with its Configuration Files

When you run apt with remove, it only removes the package files but configuration files remain on the system. Therefore to remove a package and it’s configuration files, you will have to use purge.

$ sudo apt purge glances
15 Examples of How to Use New Advanced Package Tool (APT) in Ubuntu/Debian

Remove Package Configuration Files

14. Install .Deb Package

To install a .deb file, run the command below with the filename as an argument as follows:

$ sudo apt deb atom-amd64.deb
15 Examples of How to Use New Advanced Package Tool (APT) in Ubuntu/Debian

Install Deb Package

15. Find Help While Using APT

The following command will list you all the options with it’s description on how to use APT on your system.

$ apt help
15 Examples of How to Use New Advanced Package Tool (APT) in Ubuntu/Debian

APT Command Help

Summary

Always remember that good Linux package management, can help you avoid breaking your system. There are so many other package management tools that you can use in Linux.

You can share with us what you use and your experience with it. I hope the article is helpful and for any additional information, leave a comment in the comment section.

Source: tecmint.com

Tags: Linux Commandslinux guidelinux vps setup guide
How VPS

How VPS

Related Posts

Failed to download metadata for repo 'appstream' on Centos 8
CentOS

How to fix error: Failed to download metadata for repo ‘appstream’ on Centos 8

February 25, 2022
How to Install Apache Tomcat 8 on CentOS 7
Linux

How to Install Apache Tomcat 8 on CentOS 7?

February 11, 2020
Install Arch Linux With Btrfs Snapshotting
Uncategorized

Install Arch Linux With Btrfs Snapshotting

February 13, 2020
Next Post
Backing Up Your Data

Backing Up Your Data

How to Use LUKS for Full Disk Encryption on Linux

How to Use LUKS for Full Disk Encryption on Linux

How to Change Linux Partition Label Names on EXT4 / EXT3 / EXT2 and Swap

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Follow Us

  • 121 Followers
  • 87.2k Followers

Recommended

How to Install PHP 7.3 on an Arch Linux Webserver

4 years ago

15 Basic ‘ls’ Command Examples in Linux

4 years ago
Hostgator Review

Hostgator Review

4 years ago

10 Useful Sudoers Configurations for Setting ‘sudo’ in Linux

4 years ago

Instagram

    Please install/update and activate JNews Instagram plugin.

Categories

  • Arch
  • Authentication
  • Backups
  • BSD
  • Centmin Mod
  • CentOS
  • Control Panels
  • CoreOS
  • CWP
  • Debian
  • Directadmin
  • Encryption
  • Fedora
  • Firewalls
  • Hocvps Script
  • Hosting providers
  • Kloxo-MR
  • Linux
  • Mitigations
  • Operating System
  • Plesk
  • Reviews
  • Securing VPS/Servers
  • Security Patches
  • SSL Certificates
  • Uncategorized
  • Upgrading
  • VPS/Servers management guides
  • Vulnerability Detection
  • Web servers software
  • Webhosting Control Panel

Topics

Apache Web Server Bluehost Review 2019 Bluehost Review 2020 Bluehost Review 2021 Centmin Mod CentminMod centos install htop fsck htop install HTTP DoS attack Install Snort on an Ubuntu install Zabbix on CentOS install Zabbix on CentOS 7 Linux Commands linux guide linux install htop linux vps setup guide MariaDB MariaDB Error Mysql mysqld error optimize MariaDB optimize Mysql snort Ubuntu
No Result
View All Result

Highlights

Top Free Web Hosting Control Panels To Manage VPS/Dedicated Servers

Webmin Reviews

Virtualmin Reviews

CentOS Web Panel Reviews

Ajenti Reviews

ISPConfig Reviews

Trending

Failed to download metadata for repo 'appstream' on Centos 8
CentOS

How to fix error: Failed to download metadata for repo ‘appstream’ on Centos 8

by How VPS
February 25, 2022
0

I tried to update some extensions by use yum on centOs which I specified in Dockerfile. After...

How to Fix MySQL Error "Plugin 'InnoDB' registration as a STORAGE ENGINE failed"?

How to Fix MySQL Error “Plugin ‘InnoDB’ registration as a STORAGE ENGINE failed”?

November 17, 2020
How to optimize Mysql or MariaDB

How to optimize Mysql or MariaDB

November 3, 2020
Top Free Web Hosting Control Panels To Manage VPS/Dedicated Servers

Top Free Web Hosting Control Panels To Manage VPS/Dedicated Servers

February 17, 2020
Webmin Reviews

Webmin Reviews

February 17, 2020
How VPS – How to use/setup VPS

We bring you the best Premium WordPress Themes that perfect for news, magazine, personal blog, etc. Visit our landing page to see all features & demos.
LEARN MORE »

Recent News

  • How to fix error: Failed to download metadata for repo ‘appstream’ on Centos 8 February 25, 2022
  • How to Fix MySQL Error “Plugin ‘InnoDB’ registration as a STORAGE ENGINE failed”? November 17, 2020
  • How to optimize Mysql or MariaDB November 3, 2020

Categories

  • Arch
  • Authentication
  • Backups
  • BSD
  • Centmin Mod
  • CentOS
  • Control Panels
  • CoreOS
  • CWP
  • Debian
  • Directadmin
  • Encryption
  • Fedora
  • Firewalls
  • Hocvps Script
  • Hosting providers
  • Kloxo-MR
  • Linux
  • Mitigations
  • Operating System
  • Plesk
  • Reviews
  • Securing VPS/Servers
  • Security Patches
  • SSL Certificates
  • Uncategorized
  • Upgrading
  • VPS/Servers management guides
  • Vulnerability Detection
  • Web servers software
  • Webhosting Control Panel

[mc4wp_form]

© 2018 JNews - City News Magazine WordPress theme. All rights belong to their respective owners.
JNews is a top selling 2018 WordPress News, Blog, Newspaper & Magazine Theme.

No Result
View All Result
  • Home

© 2023 JNews - Premium WordPress news & magazine theme by Jegtheme.