In short
A fresh cloud VM has almost nothing installed. Nginx, Docker, Python, Git: all of it comes through the package manager. One command, the right version, and every dependency sorted for you.
Tools for installing, updating and removing software on Linux — apt on Debian/Ubuntu-based systems, yum/dnf on RHEL/CentOS-based systems — a core skill for configuring any cloud VM.

Think of it like this
The kirana store list
You don't visit five factories for atta, oil and soap. You tell the kirana uncle 'one Maggi', and he picks the right packet from his shelves and maybe reminds you about the tastemaker. A package manager is that shopkeeper for software.
Watch it happen
What apt install really does
sudo apt update
1/6First, refresh the local catalogue of what's available. This doesn't install anything yet.
The big ideas
What you need to know
One tool per family
Ubuntu and Debian use apt. Amazon Linux, RHEL and Fedora use dnf (older ones use yum). Alpine uses apk.
Update the list first
apt update refreshes what's available. apt upgrade actually installs newer versions of what you have.
Dependencies handled
The manager installs everything a package needs, at compatible versions, so you don't hunt for libraries yourself.
Signed and trusted
Repos sign their packages. Adding random third-party repos means trusting whoever runs them.
See it in code
Walk through the code
1# Ubuntu / Debian2sudo apt update3sudo apt install -y nginx git4apt list --installed | grep nginx5sudo apt remove nginx6 7# Amazon Linux 2023 / RHEL / Fedora8sudo dnf install -y nginx git9dnf list installed nginx1/3Refresh the catalogue, then install two packages in one go.
-y answers 'yes' automatically, which you need in scripts and server setup that run without a human.
Save yourself the pain
Common mistakes
Oops
Running apt install on a fresh VM and getting 'Unable to locate package'.
Do this instead
Run sudo apt update first. A new machine's package list is often empty or stale.
Oops
Using apt commands on Amazon Linux because a tutorial said so.
Do this instead
Check the OS with cat /etc/os-release, then use the matching manager: dnf there, apt on Ubuntu.
Your mission
Set up a web server from scratch
Quick check
What does sudo apt update do?
Go deeper
- 1Practice installing, updating, and removing a package using your distribution's package manager.
- 2Learn to search for available packages before installing something blindly.
- 3Practice this on both a Debian-based and RHEL-based VM if possible, to feel the syntax difference.
More topics at this stop
Stuck on this topic? Ask an Insider
Get 1:1 guidance from people who've walked this exact path — on the InsideEdge app.