
Errata for Using and Administering Linux — 1st Edition
Using and Administering Linux: Additional information
This section of the errata contains information about some significant things that have changed since this series was first published.
Btrfs Filesystem
Fedora 33 became available in October 2020 and changes the default filesystem for new installations from the EXT4 filesystem to the BTRFS (B-Tree filesystem). Upgrades from to Fedora 33 from earlier releases maintain the existing EXT4 filesystems and do not change them.
Chapter 19 of Volume 1 of Using and Administering Linux discusses the EXT4 filesystem and Chapter 1 of Volume2 covers Logical Volume Management (LVM). This change to Btrfs as the default filesystem does not affect the accuracy of those chapters and they are still valid for EXT4 and LVM. Be sure to follow the directions in Chapter 5 of Volume 1 and use LVM for the partitioning scheme and select EXT4 for the filesystem types for all partitions except /boot.
The article, Choose between Btrfs and LVM-ext4, at Fedora Magazine has a short but good explanation of the similarities and differences between the two systems.
Download problems using wget
It was brought to my attention by reader Benjamin Robertson that experiments that use the wget command to download files from GItHub result in unusable files. This is due to an error in the URL and can easily be corrected.
For example, the command:
wget https://github.com/Apress/using-and-administering-linux-volume-2/blob/master/Experiment_6-1.txt
Should be:
wget https://github.com/Apress/using-and-administering-linux-volume-2/raw/master/Experiment_6-1.txt
Note that /blob/ should be changed to /raw/ in the above URL as well as others that use the wget command. The known instances of this problem are in:
- Volume 1, Experiment 12-1
- Volume 2, Experiment 6-1
- Volume 2, Experiment 6-3
- Volume 2, Experiment 17-1
- Volume 3, Experiment 17-1
This problem does not occur when the wget command is used with other sites such as RPMFusion and WordPress. It only occurs with GitHub.
Volume 1 — Zero to SysAdmin: Getting Started
General errata
- In Chapter 4, Preparation, Page 103, step 17 of creating the VM in a Linux environment, the change group (chgrp) command should be # chgrp vboxusers /Experiments/ which makes the group ownership of the /Experiments directory vboxusers instead of root. This prevents errors when attempting to create the virtual disk for StudentVM1. Thanks to Paolo Giuliani for bringing this error to my attention.
- The Btrfs filesystem is now the default for new installations. If you follow the directions in Chapter 5 for storage partitioning as shown in Figure 5-1, all of the experiments in all three volumes of this course will work as expected. You will just need to select LVM for the partitioning system.
- Figure 16-4, systemd targets on Page 472 has been revised to make the systemd targets the primary column and sorted in a manner that makes more sense for systemd.
- Experiment 16-4 has the student alter the /etc/defalt/grub configuration file to change the GRUB boot menu delay, and to remove rhgb and quiet from the kernel command line. It also has the student change the kernel variable GRUB_DISABLE_RECOVERY from true to false. This last change no longer causes each kernel to have a recovery boot option. The rest of this experiment works as it should regardless of the setting of this variable. This experiment is still valuable despite the fact that this one part no longer works as it once did.
- Figure 16-5 has rendered poorly in all the hardcopy and electronic versions. This image is correct and should render well.
- Figure 19-2 is incomplete. Check this revised version or download from my website, or from the Apress GitHub repository.
VirtualBox installation error
On page 79 of volume one, when trying to install virtual box but you may see the following error.
nothing provided python (abi) = 3.8 needed by virtualBox-6.1-6.1.18_142142_fedora32-1.x86_64.
This is a relatively new problem and can occur when some older Python libraries don’t get updated and get out of step with VirtualBox requirements. I have started using the “All distributions” (AMD) download which is at the bottom of the Linux distributions list of the VirtualBox Linux downloads page. This version seems to work well and has resolved the error shown above.
Thanks to “JJ” for bringing this to my attention.
Revised systemd target list
The following table replaces Figure 16-4 in the first edition of Using and Administering Linux: Volume 1 – Zero to SysAdmin: Getting Started on Page 472. The original shows the SystemV runlevels in the leftmost column and is sorted in the historical SystemV sequence. In this replacement I have made the systemd targets the primary column and sorted them in a sequence that makes more sense for systemd. In general, targets with higher levels of functionality are at the top of the table and those with the least functionality are at the bottom.
systemd targets | SystemV runlevel | target aliases | Description |
default.target | This target is always aliased with a symbolic link to either multi-user.target or graphical.target. systemd always uses the default.target to start the system. The default.target should never be aliased to halt.target, poweroff.target, or reboot.target. | ||
graphical.target | 5 | runlevel5.target | Multi-user.target with a GUI. |
4 | runlevel4.target | Unused. Runlevel 4 was identical to runlevel 3 in the SystemV world. This target could be created and customized to start local services without changing the default multi-user.target. | |
multi-user.target | 3 | runlevel3.target | Multiuser with all services running but command line interface (CLI) only. |
2 | runlevel2.target | Multiuser, without NFS but all other non-GUI services running. | |
rescue.target | 1 | runlevel1.target | A basic system including mounting the filesystems with only the most basic services running and a rescue shell on the main console. |
emergency.target | S | No services are running; filesystems are not mounted. This is the most basic level of operation with only an emergency shell running on the main console for the user to interact with the system. Single user mode in SystemV. | |
halt.target | Halts the system without powering it down. | ||
reboot.target | 6 | runlevel6.target | Reboot |
poweroff.target | 0 | runlevel0.target | Halts the system and turns the power off. |
The revised version of the figure is used in the second edition of this book
Correct Figure 16-5 in Volume 1, 1st Edition
Updated March 24, 2020
Figure 16-5 in Volume 1 of my book, Using and Administering Linux: Volume 1 – Zero to SysAdmin: Getting Started, has rendered poorly in all the paperback and electronic versions of the 1st edition. The following image is correct and should render well.
Note that this diagram is from a more recent release of Fedora than the one in the book, and it has more detail than previous versions of this man page. This more recent man page also contains some flowcharts that describe some additional processes:
- User Manager startup
- Initial RAM disk startup INITRD
- System Manager shutdown
Be sure to read the man page of your distribution and release for specific details of your environment.
cryptsetup-pre.target
|
(various low-level v
API VFS mounts: (various cryptsetup devices...)
mqueue, configfs, | |
debugfs, ...) v |
| cryptsetup.target |
| (various swap | | remote-fs-pre.target
| devices...) | | | |
| | | | | v
| v local-fs-pre.target | | | (network file systems)
| swap.target | | v v |
| | v | remote-cryptsetup.target |
| | (various low-level (various mounts and | | |
| | services: udevd, fsck services...) | | remote-fs.target
| | tmpfiles, random | | | /
| | seed, sysctl, ...) v | | /Revised Figure 2-6 in Volume 3
| | | local-fs.target | | /
| | | | | | /
\____|______|_______________ ______|___________/ | /
\ / | /
v | /
sysinit.target | /
| | /
______________________/|\_____________________ | /
/ | | | \ | /
| | | | | | /
v v | v | | /
(various (various | (various | |/
timers...) paths...) | sockets...) | |
| | | | | |
v v | v | |
timers.target paths.target | sockets.target | |
| | | | v |
v \_______ | _____/ rescue.service |
\|/ | |
v v |
basic.target rescue.target |
| |
________v____________________ |
/ | \ |
| | | |
v v v |
display- (various system (various system |
manager.service services services) |
| required for | |
| graphical UIs) v v
| | multi-user.target
emergency.service | | |
| \_____________ | _____________/
v \|/
emergency.target v
graphical.target
Corrected Figure 19-2
This is the corrected version of Figure 19-2 in Using and Administering Linux: Volume 1 – Zero to SysAdmin: Getting Started. I apologize for any inconvenience.
Figure 19-2 provides a list of the standard, well known, and defined top-level Linux directories and their purposes. These directories are listed in alphabetical order.
Directory | Part of / | Description |
---|---|---|
/ (root filesystem) | Yes | The root filesystem is the top-level directory of the filesystem. It must contain all of the files required to boot the Linux system before other filesystems are mounted. After the system is booted, all other filesystems are mounted on standard, well defined, mount points as subdirectories of the root filesystem. |
/bin | Yes | The /bin directory contains user executable files.1 |
/boot | No | Contains the static bootloader and kernel executable and configuration files required to boot a Linux computer. |
/dev | Yes | This directory contains the device files for every hardware device attached to the system. These are not device drivers, rather they are files that represent each device on the computer and facilitate access to those devices. |
/etc | Yes | Contains a wide variety of system configuration files for the host computer. |
/home | No | Home directory storage for user files. Each user has a subdirectory in /home. |
/lib | Yes | Contains shared library files that are required to boot the system. |
/media | No | A place to mount external removable media devices such as USB thumb drives that may be connected to the host. |
/mnt | No | A temporary mountpoint for regular filesystems (as in not removable media) that can be used while the administrator is repairing or working on a filesystem. |
/opt | No | Optional files such as vendor supplied application programs should be located here. |
/proc | Virtual | Virtual filesystem used to expose access to internal kernel information and editable tuning parameters. |
/root | Yes | This is not the root (/) filesystem. It is the home directory for the root user. |
/sbin | Yes | System binary files. These are executables used for system administration. |
/selinux | Virtual | This filesystem is only used when SELinux is enabled. |
/sys | Virtual | This virtual filesystem contains information about the USB and PCI busses and the devices attached to each. |
/tmp | No | Temporary directory. Used by the operating system and many programs to store temporary files. Users may also store files here temporarily. Note that files stored here may be deleted at any time without prior notice. |
/usr | No | These are shareable, read only files including executable binaries and libraries, man[ual] files, and other types of documentation. |
/usr/local | No | These are typically shell programs or compiled programs and their supporting configuration files that are written locally and used by the SysAdmin or other users of the host. |
/var | No | Variable data files are stored here. This can include things like log files, MySQL and other database files, web server data files, email inboxes, and much more. |
Figure 19-2: The top level of the Linux Filesystem Hierarchical Standard.
1Note that /bin and /sbin are now just links to /usr/bin and /usr/sbin, respectively.
Volume 2 — Zero to SysAdmin: Advanced Topics
Experiment 6-1 revised download URL
- In experiment 6-1, the download URL is incorrect. It should be github.com/Apress/using-and-administering-linux-volume-2/raw/master/Experiment_6-1.txt
Chapter 12 in Volume 2 Needs some Additional Preparation.
Due to some changes to the NetworkManager since this chapter was written in 2019, it is necessary to do a little preparation so that some experiments in Chapter 12 will work – specifically the experiments that relate to the interface configuration files. If you are using Fedora 36 or later, all that is necessary is to install one package that will provide support for the now deprecated interface configuration files.
Run this command as the root user.
[root@studentvm1 ~]# dnf -y install NetworkManager-initscripts-ifcfg-rh
It is possible that another change in the future will remove this package from the Fedora repository. Regardless of that, most of this chapter will remain valid and should not be skipped.
I am writing a new Chapter, NetworkManager, which covers NetworkManager, its commands, and its configuration keyfiles in some detail. I am unsure if Apress will issue a second edition of these books or a fourth volume to contain at least four new chapters that I currently have in progress.
Volume 3 — Zero to SysAdmin: Network Services
General errata
- In Chapter 2, the experiments still work and the nmcli commands do create the proper network interface configurations. The nmcli command now creates network keyfiles in the /etc/NetworkManager/system-connections directory. It no longer created network interface configuration files in the /etc/sysconfig/network-scripts directory. When you are instructed to look for the interface configuration files, look for the keyfiles in the /etc/NetworkManager/system-connections directory.
- There is an error in Figure 2-6. The interface and connection names should both be enp0s8. See the revised Figure 2-6 below.
- The nmcli command just under Figure 2-6 should be:
[root@studentvm2 ~]# nmcli connection add save yes type ethernet ifname enp0s8 con-name enp0s8 ip4 192.168.56.1/24
This sets the IP address for the local virtual network on StudentVM2. - The
dig
command in Experiment 2-4 contains an erroneous result. The Server line near the bottom of the output from that command should be;; SERVER: 10.0.2.1#53(10.0.2.1)
- In Experiment 3-2, I have skipped an important step as was pointed out to me by a student in France. Add the following to the middle of Page 28 and replace the iplink command with it. “If StudentVM1 is running, power it off now. In the VirtualBox Manager, open the Settings dialog for StudentVM1. Go to the Network page and ensure that the Adapter 1 tab is selected. Set the Attached To: selection box to Host-only Adapter. This connects Adapter 1 to the new internal network we have created and removes it from the original network serviced by the virtual router. Start the StudentVM1 host. Nothing further will need to be done to obtain an IP address from the newly configured DHCP server. Login to StudentVM1, open a terminal session and su – to root. On StudentVM1, verify connectivity to the StudentVM2 server using the ping command. The -c option specifies the number of ping requests to send, in this case 2. We need to specify the IP address of the server because we do not yet have a name server on this network. [root@studentvm1 ~]# ping 192.168.56.1 -c2 “
- Experiment 4-5 starting on Page 51 contains some inconsistencies. The listing of the /etc/sysconfig/iptables file shows a rule to accept DNS requests on port 53 using only TCP. On Page 52, the result of the iptables-save command shows a rule that accepts DNS queries on UDP. In fact, IPTables should have rules for DNS port 53 for both UDP and TCP. This article explains.
- In Chapter 14, the installation and configuration procedure for TigerVNC has changed somewhere between Fedora 30 and 33. I am currently working on a revision to this procedure.
Revised Figure 2-6
Config item | Option name | Value | Description |
---|---|---|---|
Network type | type | ethernet | This could also be various types of VPN, or bonded connections. Those options are outside the scope of this course. |
Interface name | ifname | enp0s8 | This is the name of the interface as displayed by the nmcli device command. |
Connection name | con-name | enp0s8 | This is the name of the connection that will be used in commands. It will be part of the interface configuration file name. I like to keep this name short for ease of typing. I use the NIC name to make identification easy. |
IPV4 address | ipv4 | 192.168.56.1 | The static IP V4 address we assign to this interface. |
Gateway IPV4 Address | gw4 | N/A | The default route through the virtual router. |
IPV4 DNS servers | ipv4.dns | N/A | Up to three DNS server IP addresses, Be sure to use the double quotes. |
Figure 2-6 in Volume 3 has been revised as shown below.