Enabling collaboration with setgid directory

Create and configure setgid directories for collaboration – RHCSA Objective Preparation

GNU/Linux filesystem permissions and rights are the basis of the system’s security, and one of it’s principles is the clear separation of rights to files and folders. In a heavily multiuser environment, such as a school’s server, file rights prevent a user by default to accidentally delete or overwrite another’s documents. However, there are use cases where multiple users need to access (read, write, and even delete) other user’s files – such may be the case in the above mentioned school server, where students work on the same project. In this section of RHCSA exam preparation we will learn how to create an environment for such collaboration, using the setgid (set groupID) technique. Note that while we perform these steps on a recent operating system, the setgid isn’t a new thing, and you will find it in any and all distributions.

In this tutorial you will learn:

  • How to add users to a supplementary group
  • How to use set-GID on a directory
  • How to check proper ownership within the set-GID directory
  • How to use the special directory as a member of the group

Read more

Adding swap space to the system

Add new partitions, logical volumes, and swap to a system non-destructively – RHCSA Objective Preparation

Disk and space management is an essential knowledge of a sysadmin. It is his or her everyday job to handle disk issues. As part of the RHCSA exam preparation, we will learn how to add new space of various types to the system, using the tools provided by RHEL8. We already covered many of these tasks, and in this tutorial we will focus on adding new space without harming the data contained in the system.

In this tutorial you will learn:

  • How to add new partitions to RHEL8
  • How to add new logical volumes to RHEL8
  • How to add swap to RHEL8

Read more

Creating new physical volume with LVM

Using LVM to manage physical volumes, volume groups, and logical volumes – RHCSA Objective Preparation

As part of the RHCSA exam preparation, we already learned how to manage partitions on disk. Partitions are useful to separate disk space (for example, separating database-related files from webserver-related files), but we have a much more flexible solution that can separate or aggregate storage space.

This solution is called LVM, the Logical Volume Manager. LVM allows us to see multiple disks as one filesystem, thus overcoming the limitations of a physical disk’s site. We can also create software mirroring on disks to protect or data written to the filesystem. In this tutorial we’ll cover the basics: we’ll manage the three layers of LVM, physical volumes, volume groups and logical volumes.

In this tutorial you will learn:

  • How to create and remove physical volumes
  • How to assign physical volumes to volume groups
  • How to create and delete logical volumes

Read more

Mounting filesystem by label

Configure systems to mount file systems at boot by universally unique ID (UUID) or label – RHCSA Objective Preparation

While in the desktop world we rarely change our hard drive – and that mostly indicated by hardware failure – in the server world it isn’t uncommon for the underlying storage environment to change over time.

In a SAN (Storage Area Network) environment, for High Availability, a server can reach it’s storage trough many paths, in reality distributed and mirrored to multiple disks in the storage network. If some paths change, the server needs to identify the “disk” again. That’s why it is recommended to use special identifiers set on the device, and mount by these identifiers, not by device name which may change. In this part of RHCSA exam preparation tutorial, we’ll add a new disk to our test machine, and configure mounting by UUID (Universally Unique IDentifier) and by label.

In this tutorial you will learn:

  • How to get UUID of a given device
  • How to get and set label of a device
  • How to mount device by UUID
  • How to mount device by label

Read more

Manual page of the ln command

Create hard and soft links – RHCSA Exam Preparation

In this part of RHCSA exam preparation we will turn our attention to links. There are two types of link, hard links and soft links. In this article we will talk about how to create and remove links and will also discuss some basic background behind both, the hard links and the soft links.

In this tutorial you will learn:

  • What are symbolic (soft) links
  • What are hard links
  • How to create a symbolic link
  • How to create a hard link
  • How to remove link

Read more

Change default runlevel target on RHEL 8 system

Boot systems into different targets manually – RHCSA Objective Preparation

In this part of RHCSA exam preparation you will learn how to manually change into a different boot targets. This article will also teach you how to set a default boot targets to automatically boot into graphical or multi-user target on Red Hat Enterprise Linux system.

In this tutorial you will learn:

  • How to check default boot target
  • How to manually switch between different targets
  • How to set default boot to multi-user target
  • How to set default boot to graphical target

Read more

Creating 1 GB partition with fdisk

How to list, create, delete partitions on MBR and GPT disks – RHCSA Objective Preparation

Disk partitions are the basis of storing our data on disks. To be able to handle partitions, in this part of RHCSA exam preparation tutorial we will add an empty disk to our test RHEL 8 system, and create, list, and delete a new partition on it. First we will use the classic MBR (Master Boot Record) setup, then we’ll do the same on GPT (GUID Partitioning Table) setup. GPT is a more advanced partitioning technique that allows large partitions, whereas MBR is limited to 2 TB disk space per partition. So if that doesn’t seem like a very limiting size at the moment, think of the trend of disk usage, which may be not that much from the end user perspective, but certainly it is from the Linux system administration job perspective.

In this tutorial you will learn:

  • How to create a new MBR partition using fdisk
  • How to list classic partitions using fdisk
  • How to delete partition using fdisk
  • How to create GPT partition using gdisk
  • How to list GPT partitions
  • How to delete GPT partitions

Read more