Linux is an open-source operating system (OS), just like Windows or Android.
Linux takes many forms, called distros. Here are some common ones:
Mainstream Use (Desktop or Server)
Security
- Kali Linux (website)
Elite 1337
pr0s usage
Of all the distros, Ubuntu is one of the most widely used distros, powering web servers, computers and other devices (such as IoT devices or robots).
Ubuntu is actually an (more user-friendly?) offshoot of Debian. They share many similarities, including apt
and the dpkg
package manager (more on that later).
Fedora is the other kid on the block, also very modern and pretty. It has a good reputation for security.
Ubuntu and Fedora are actually bankrolled by commercial companies. Canonical makes money supporting commercial users of Ubuntu, while Fedora's development is ultimately channelled into Red Hat's commercial product, Red Hat Enterprise Linux (RHEL), which is used when security and stablity is paramount (think medical, government or miliary).
An analogy is the App Store. It's where you go to for "packages", which may take the form of actual "apps" like Firefox that have a graphical interface (GUI), command line tools like htop
, or libraries that another package (such as python) might depend on.
In Ubuntu and Debian, the package manager is apt
. To install a package, eg. Firefox, execute the command sudo apt install firefox
.
The command is executed in the terminal (command line). To open Terminal, either press CTRL``ALT``T
or find Terminal in the Applications menu. If you have already connected via SSH (next section), you're staring at the Terminal.
Here's the breakdown:
sudo
-- admin rightsapt
-- package managerinstall
-- the "action" (another example ispurge
, which uninstalls a package completely)firefox
-- the package in question. You can actually list more than one package, likesudo apt install htop firefox chromium-browser
to installhtop
, Firefox and Chromium (open-source version of Google Chrome). If you can't really recall the name of the package, you can hit theTAB
button for a list of suggestions.
There are two ways of connecting to a remote Linux machine (such as a web server, or a Raspberry Pi running on the network):
- SSH (secure shell) - command line
- VNC (virtual network computing) - graphical desktop interface
SSH is more commonly used and almost universally present on Linux machines. It gives you access to the command line interface (terminal).
Command from Linux or macOS: ssh pi@10.12.147.144
:
ssh
-- call SSHpi
-- the user name you want to login as10.12.147.144
-- the address of the Linux device
Execute the command and type in your password. Note: the password will not appear as you type it in.
On Windows, you have to use PuTTY.
VNC is more user friendly but usually requires a seperate install and configuration.