Acknowledgments xi Introduction xxxiii Part I: Getting Started 1 Chapter 1: Starting with Linux 3 Understanding What Linux Is 4 Understanding How Linux Differs from Other Operating Systems 6 Exploring Linux History 6 Free-flowing UNIX culture at Bell Labs 7 Commercialized UNIX 9 Berkeley Software Distribution arrives 9 UNIX Laboratory and commercialization 10 GNU transitions UNIX to freedom 11 BSD loses some steam 13 Linus builds the missing piece 13 OSI open source definition 14 Understanding How Linux Distributions Emerged 16 Choosing a Red Hat distribution 17 Using Red Hat Enterprise Linux 17 Using Fedora 18 Choosing Ubuntu or another Debian distribution 19 Finding Professional Opportunities with Linux Today 20 Understanding how companies make money with Linux 21 Becoming Red Hat certified 22 RHCSA topics 23 RHCE topics 24 Summary 26 Chapter 2: Creating the Perfect Linux Desktop 29 Understanding Linux Desktop Technology 30 Starting with the Fedora GNOME Desktop Live image 32 Using the GNOME 3 Desktop 33 After the computer boots up 33 Navigating with the mouse 34 Navigating with the keyboard 38 Setting up the GNOME 3 desktop 41 Extending the GNOME 3 desktop 42 Using GNOME shell extensions 42 Using the GNOME Tweak Tool 44 Starting with desktop applications 45 Managing files and folders with Nautilus 45 Installing and managing additional software 46 Playing music with Rhythmbox 48 Stopping the GNOME 3 desktop 49 Using the GNOME 2 Desktop 49 Using the Metacity window manager 50 Changing GNOME''s appearance 52 Using the GNOME panels 53 Using the Applications and System menus 54 Adding an applet 54 Adding another panel 55 Adding an application launcher 55 Adding a drawer 56 Changing panel properties 57 Adding 3D effects with AIGLX 58 Summary 60 Exercises 61 Part II: Becoming a Linux Power User 63 Chapter 3: Using the Shell 65 About Shells and Terminal Windows 66 Using the shell prompt 67 Using a terminal window 68 Using virtual consoles 69 Choosing Your Shell 69 Running Commands 70 Understanding command syntax 71 Locating commands 74 Recalling Commands Using Command History 76 Command-line editing 77 Command-line completion 79 Command-line recall 80 Connecting and Expanding Commands 82 Piping between commands 82 Sequential commands 83 Background commands 83 Expanding commands 84 Expanding arithmetic expressions 84 Expanding variables 85 Using Shell Variables 85 Creating and using aliases 87 Exiting the shell 88 Creating Your Shell Environment 88 Configuring your shell 88 Setting your prompt 89 Adding environment variables 91 Getting Information about Commands 92 Summary 94 Exercises 95 Chapter 4: Moving around the Filesystem 97 Using Basic Filesystem Commands 100 Using Metacharacters and Operators 102 Using file-matching metacharacters 102 Using file-redirection metacharacters 103 Using brace expansion characters 105 Listing Files and Directories 105 Understanding File Permissions and Ownership 109 Changing permissions with chmod (numbers) 111 Changing permissions with chmod (letters) 111 Setting default file permission with umask 112 Changing file ownership 113 Moving, Copying, and Removing Files 114 Summary 115 Exercises 115 Chapter 5: Working with Text Files 117 Editing Files with vim and vi 117 Starting with vi 119 Adding text 119 Moving around in the text 120 Deleting, copying, and changing text 121 Pasting (putting) text 122 Repeating commands 122 Exiting vi 122 Skipping around in the file 123 Searching for text 124 Using ex mode 124 Learning more about vi and vim 124 Finding Files 125 Using locate to find files by name 125 Searching for files with find 127 Finding files by name 127 Finding files by size 128 Finding files by user 128 Finding files by permission 129 Finding files by date and time 130 Using ''not'' and ''or'' when finding files 131 Finding files and executing commands 131 Searching in files with grep 132 Summary 134 Exercises 134 Chapter 6: Managing Running Processes 137 Understanding Processes 137 Listing Processes 138 Listing processes with ps 138 Listing and changing processes with top 140 Listing processes with System Monitor 142 Managing Background and Foreground Processes 144 Starting background processes 144 Using foreground and background commands 145 Killing and Renicing Processes 146 Killing processes with kill and killall 146 Using kill to signal processes by PID 147 Using killall to signal processes by name 148 Setting processor priority with nice and renice 148 Limiting Processes with cgroups 149 Summary 151 Exercises 151 Chapter 7: Writing Simple Shell Scripts 153 Understanding Shell Scripts 153 Executing and debugging shell scripts 154 Understanding shell variables 154 Special shell positional parameters 156 Reading in parameters 157 Parameter expansion in bash 157 Performing arithmetic in shell scripts 158 Using programming constructs in shell scripts 159 The "if.then" statements 159 The case command 162 The "for.do" loop 163 The "while.do" and "until.do" loops 164 Trying some useful text manipulation programs 164 The general regular expression parser 165 Remove sections of lines of text (cut) 165 Translate or delete characters (tr) 165 The stream editor (sed) 166 Using simple shell scripts 167 Telephone list 167 Backup script 168 Summary 168 Exercises 169 Part III: Becoming a Linux System Administrator 171 Chapter 8: Learning System Administration 173 Understanding System Administration 173 Using Graphical Administration Tools 175 Using system-confi g-* tools 175 Using browser-based admin tools 177 Using the root user account 177 Becoming root from the shell (su command) 178 Allowing administrative access via the GUI 180 Gaining administrative access with sudo 180 Exploring Administrative Commands, Configuration Files, and Log Files 182 Administrative commands 182 Administrative configuration files 183 Administrative log files and systemd journal 188 Using journalctl to view the systemd journal 188 Managing log messages with rsyslogd 189 Using Other Administrative Accounts 189 Checking and Confi guring Hardware 190 Checking your hardware 191 Managing removable hardware 194 Working with loadable modules 197 Listing loaded modules 197 Loading modules 198 Removing modules 198 Summary 199 Exercises 199 Chapter 9: Installing Linux x 201 Choosing a Computer 202 Installing Fedora from Live media 203 Installing Red Hat Enterprise Linux from Installation Media 208 Understanding Cloud-Based Installations 211 Installing Linux in the Enterprise 211 Exploring Common Installation Topics 213 Upgrading or installing from scratch 213 Dual booting 214 Installing Linux to run virtually 216 Using installation boot options 216 Boot options for disabling features 217 Boot options for video problems 217 Boot options for special installation types 218 Boot options for kickstarts and remote repositories 218 Miscellaneous boot options 219 Using specialized storage 219 Partitioning hard drives 220 Understanding different partition types 221 Reasons for different partitioning schemes 222 Tips for creating partitions 222 Using the GRUB boot loader 224 Using GRUB Legacy (version 1) 225 Using GRUB 2 229 Summary 231 Exercises 231 Chapter 10: Getting and Managing Software 233 Managing Software on the Desktop 233 Going Beyond the Software Window 235 Understanding Linux RPM and DEB Software Packaging 236 Understanding DEB packaging 237 Understanding RPM packaging 238 What is in an RPM? 238 Where do RPMs come from? 239 Installing RPMs 239 Managing RPM Packages with YUM 240 Understanding how yum works 241 1 Checking /etc/yumconf 242 2 Checking /etc/sysconfi g/rhn/up2date (RHEL only) 242 3 Checking /etc/yumreposd/*repo files 243 4 Downloading RPM packages and metadata from a YUM repository 243 5 RPM packages installed to Linux fi le system 244 6 Store YUM repository metadata to local RPM database 244<.
Linux Bible