HOW-TOs

Hot Swappable Filesystems, as Smooth as Btrfs

Filesystems, like file cabinets or drawers, control how your operating system stores data. They also hold metadata like filetypes, what is attached to data, and who has access to that data. For windows or macOS users Quite honestly, not enough people consider which file system to use for their computers.

How to Try Linux Without a Classical Installation

For many different reasons, you may not be able to install Linux on your computer. Maybe you are not familiar with words like partitioning and bootloader, maybe you share the PC with your family, maybe you don’t feel comfortable to wipe out your hard drive and start over, or maybe you just want to see how it looks before proceeding with a full installation. I know, it feels frustrating, but no worries, we have got you covered! In this article, we will explore several ways to try Linux out without the hassle of a classical installation.

How to Create EC2 Duplicate Instance with Ansible

Many companies like mine use AWS infrastructure as a service (IaaS) heavily. Sometimes we want to perform a potentially risky operation on an EC2 instance. As long as we do not work with immutable infrastructure it is imperative to be prepared for instant revert. One of the solutions is to use a script that will perform instance duplication, but in modern environments, where unification is an essence it would be wiser to use more common known software instead of making up a custom script. Here comes the Ansible!

TCP Analysis with Wireshark

Transmission Control is an essential aspect of network activity and governs the behavior of many services we take for granted. When sending your emails or just browsing the web you are relying on TCP to send and receive your packets in a reliable fashion. Thanks to two DARPA scientists, Vinton Cerf and Bob Kahn who developed TCP/IP in 1970, we have a specific set of rules that define how we communicate over a network. When Vinton and Bob first conceptualized TCP/IP, they set up a basic network topology and a device that can interface between two other hosts.

How to Add a Simple Progress Bar in Shell Script

At times, we need to write shell scripts that are interactive and user executing them need to monitor the progress. For such requirements, we can implement a simple progress bar that gives an idea about how much task has been completed by the script or how much the script has executed. To implement it, we only need to use the “echo” command with the following options and a backslash-escaped character.

How to Secure Your Website with OpenSSL and SSL Certificates

The Internet has become the number one resources for news, information, events, and all things social. As most people know there are many ways to create a website of your own and capture your own piece of the internet to share your stories, ideas, or even things you like with others. When doing so it is important to make sure you stay protected on the internet the same way you would in the real world. There are many steps to take in the real world to stay safe, however, in this article we will be talking about staying secure on the web with an SSL certificate.

Quick Tutorial on How to Use Shell Scripting in Linux: Coin Toss App

Simply put, a Shell Script is a program that is run by a UNIX/Linux shell. It is a file that contains a series of commands which are executed sequentially as if they were entered on the command line interface (CLI) or terminal. In this quick tutorial on Shell Scripting, we will write a simple program to toss a coin. Basically, the output of our program should be either HEADS or TAILS (of course, randomly).

How To Kill Zombie Processes on Linux

Killing Zombies! Also known as “defunct” or “dead” process – In simple words, a Zombie process is one that is dead but is present in the system’s process table. Ideally, it should have been cleaned from the process table once it completed its job/execution but for some reason, its parent process didn’t clean it up properly after the execution.

How To Upgrade From Fedora 32 To Fedora 33 [CLI & Graphical Methods]

Last week, a Red Hat-sponsored community project, Fedora, announced the availability of Fedora 33 Beta. It is a prerelease version of the upcoming Fedora 33 Linux distribution, whose final stable version will arrive in the last week of October. Fedora 33 is one of the exciting releases as it contains the fundamental shift of the default filesystem from ext4 to btrfs for all Fedora desktop editions and spins, along with other new features and visual changes. Here are some of the key updates that Fedora 33 Beta includes:

Installing Ubuntu with Two Hard Drives

Many computers these days come with two hard drives, one SSD for fast boot speeds, and one that can be used for storage. My Dell G5 gaming laptop is a great example with a 128GB NAND SSD and a 1TB SSD. When building out a Linux installation I have a few options. Option 1: Follow the steps and install Ubuntu on one SSD hard drive for quick boot times and better speed performance when opening files or moving data. Then mounting the second drive and copying files to it when I want to backup files or need to move files off the first drive.

Linux vs. Windows: What's the difference in 2022?

For users who are looking to try something new, or who are tired of their Mac OS or Windows operating systems, now just might be the time to switch to something else. The Mac OS system currently uses a UNIX core, which would make switching from Mac OS to Linux a fairly smooth transition. Windows users, on the other hand, will need to make some adjustments. The following tutorial will compare the Linux operating system to Microsoft Windows.

Oops! Debugging Kernel Panics

A look into what causes kernel panics and some utilities to help gain more information. Working in a Linux environment, how often have you seen a kernel panic? When it happens, your system is left in a crippled state until you reboot it completely. And, even after you get your system back into a functional state, you're still left with the question: why? You may have no idea what happened or why it happened. Those questions can be answered though, and the following guide will help you root out the cause of some of the conditions that led to the original crash.

Digging Through the DevOps Arsenal: Introducing Ansible

If you need to deploy hundreds of server or client nodes in parallel, maybe on-premises or in the cloud, and you need to configure each and every single one of them, what do you do? How do you do it? Where do you even begin? Many configuration management frameworks exist to address most, if not all, of these questions and concerns. Ansible is one such framework.

Build a Versatile OpenStack Lab with Kolla

Hone your OpenStack skills with a full deployment in a single virtual machine. It's hard to go anywhere these days without hearing something about the urgent need to deploy on-premises cloud environments that are agile, flexible and don't cost an arm and a leg to build and maintain, but getting your hands on a real OpenStack cluster—the de facto standard—can be downright impossible.

The Bash Trap Command

  If you've written any amount of bash code, you've likely come across the trap command. Trap allows you to catch signals and execute code when they occur. Signals are asynchronous notifications that are sent to your script when certain events occur. Most of these notifications are for events that you hope never happen, such as an invalid memory access or a bad system call. However, there are one or two events that you might reasonably want to deal with. There are also "user" events available that are never generated by the system that you can generate to signal your script. Bash also provides a psuedo-signal called "EXIT", which is executed when your script exits; this can be used to make sure that your script executes some cleanup on exit.

Bash Shell Games: Let's Play Go Fish!

How to begin developing a computer version of the popular card game. Between the previous 163 columns I've written here in Linux Journal and the dozens of games I programmed and explored during the creation of my Wicked Cool Shell Scripts book, I've written a lot of Bash shell games. The challenge is to find one that's simple enough where a shell script will work, but isn't so simple that it ends up being only a half-dozen lines.

What Does It Take to Make a Kernel?

The kernel this. The kernel that. People often refer to one operating system's kernel or another without truly knowing what it does or how it works or what it takes to make one. What does it take to write a custom (and non-Linux) kernel?