Mastering Ubuntu Server

Book description

Get up to date with the finer points of Ubuntu Server using this comprehensive guide

About This Book

  • Get well-versed with newly-added features in Ubuntu 16.04
  • Master the art of installing, managing, and troubleshooting Ubuntu Server
  • A practical easy-to-understand book that will help you enhance your existing skills.

Who This Book Is For

This book is intended for readers with intermediate or advanced-beginner skills with Linux, who would like to learn all about setting up servers with Ubuntu Server. This book assumes that the reader knows the basics of Linux, such as editing configuration files and running basic commands.

What You Will Learn

  • Learn how to manage users, groups, and permissions
  • Encrypt and decrypt disks with Linux Unified Key Setup /Luks
  • Setup SSH for remote access, and connect it to other nodes
  • Understand how to add, remove, and search for packages
  • Use NFS and Samba to share directories with other users
  • Get to know techniques for managing Apache and MariaDB
  • Explore best practices and troubleshooting techniques

In Detail

Ubuntu is a Debian-based Linux operating system, and has various versions targeted at servers, desktops, phones, tablets and televisions. The Ubuntu Server Edition, also called Ubuntu Server, offers support for several common configurations, and also simplifies common Linux server deployment processes.

With this book as their guide, readers will be able to configure and deploy Ubuntu Servers using Ubuntu Server 16.04, with all the skills necessary to manage real servers. The book begins with the concept of user management, group management, as well as file-system permissions. To manage your storage on Ubuntu Server systems, you will learn how to add and format storage and view disk usage. Later, you will also learn how to configure network interfaces, manage IP addresses, deploy Network Manager in order to connect to networks, and manage network interfaces. Furthermore, you will understand how to start and stop services so that you can manage running processes on Linux servers. The book will then demonstrate how to access and share files to or from Ubuntu Servers. You will learn how to create and manage databases using MariaDB and share web content with Apache. To virtualize hosts and applications, you will be shown how to set up KVM/Qemu and Docker and manage virtual machines with virt-manager. Lastly, you will explore best practices and troubleshooting techniques when working with Ubuntu Servers.

By the end of the book, you will be an expert Ubuntu Server user well-versed in its advanced concepts.

Style and Approach

This book is an advanced guide that will show readers how to administer, manage, and deploy Ubuntu server and will also provide expert-level knowledge on advanced security and backup techniques.

Table of contents

  1. Mastering Ubuntu Server
    1. Table of Contents
    2. Mastering Ubuntu Server
    3. Credits
    4. About the Author
    5. Acknowledgments
    6. About the Reviewers
      1. eBooks, discount offers, and more
        1. Why subscribe?
    8. Preface
      1. What this book covers
      2. What you need for this book
      3. Who this book is for
      4. Conventions
      5. Reader feedback
      6. Customer support
        1. Downloading the color images of this book
        2. Errata
        3. Piracy
        4. Questions
    9. 1. Deploying Ubuntu Server
      1. Setting up our lab
      2. Determining your server's role
      3. Obtaining Ubuntu Server
      4. Deciding between 32-bit and 64-bit installations
      5. Creating a bootable Ubuntu Server flash drive (Windows)
      6. Creating a bootable Ubuntu Server flash drive (Linux)
      7. Creating a bootable Ubuntu Server flash drive (Mac)
      8. Planning the partition layout
      9. Installing Ubuntu Server
      10. Installing Ubuntu Server (Raspberry Pi)
      11. Summary
    10. 2. Managing Users
      1. Understanding when to use root
      2. Creating and removing users
      3. Understanding the /etc/passwd and /etc/shadow files
      4. Distributing default configuration files with /etc/skel
      5. Switching between users
      6. Managing groups
      7. Managing passwords and password policies
      8. Configuring administrator access with sudo
      9. Setting permissions on files and directories
      10. Summary
    11. 3. Managing Storage Volumes
      1. Viewing disk usage
      2. Adding additional storage volumes
      3. Partitioning and formatting volumes
      4. Mounting and unmounting storage volumes
      5. Understanding the /etc/fstab file
      6. Managing swap
      7. Utilizing LVM volumes
      8. Using symbolic and hard links
      9. Summary
    12. 4. Connecting to Networks
      1. Setting the hostname
      2. Managing network interfaces
      3. Assigning static IP addresses
      4. Understanding Linux name resolution
      5. Understanding Network Manager
      6. Getting started with OpenSSH
      7. Getting started with SSH key management
      8. Simplifying SSH connections with a ~/.ssh/config file
      9. Summary
    13. 5. Managing Software Packages
      1. Understanding Linux package management
      2. Installing and removing software
      3. Searching for packages
      4. Managing software repositories
      5. Keeping your server up to date
      6. Backing up and restoring packages
      7. Making use of aptitude
      8. Installing Snap packages
      9. Summary
    14. 6. Controlling and Monitoring Processes
      1. Showing running processes with the ps command
      2. Managing jobs
      3. Killing misbehaving processes
      4. Utilizing htop
      5. Managing system processes
      6. Monitoring memory usage
      7. Scheduling tasks with Cron
      8. Understanding load average
      9. Summary
    15. 7. Managing Your Ubuntu Server Network
      1. Planning your IP address scheme
      2. Serving IP addresses with isc-dhcp-server
      3. Setting up name resolution (DNS) with bind
      4. Creating a secondary DNS server
      5. Setting up an Internet gateway
      6. Keeping your system clock in sync with NTP
      7. Summary
    16. 8. Accessing and Sharing Files
      1. File server considerations
      2. Sharing files with Windows users using Samba
      3. Setting up NFS shares
      4. Transferring files with rsync
      5. Transferring files with SCP
      6. Mounting remote filesystems with SSHFS
      7. Summary
    17. 9. Managing Databases
      1. Preparations for setting up a database server
      2. Installing MariaDB
      3. Taking a look at MariaDB configuration
      4. Understanding how MariaDB differs in Ubuntu 16.04
      5. Managing databases
      6. Setting up a slave DB server
      7. Summary
    18. 10. Serving Web Content
      1. Installing and configuring Apache
      2. Installing additional Apache modules
      3. Securing Apache with SSL
      4. Setting up high availability with keepalived
      5. Installing and configuring ownCloud
      6. Summary
    19. 11. Virtualizing Hosts and Applications
      1. Setting up a virtual machine server
      2. Creating virtual machines
      3. Bridging the virtual machine network
      4. Creating, running, and managing Docker containers
      5. Summary
    20. 12. Securing Your Server
      1. Lowering your attack surface
      2. Securing OpenSSH
      3. Installing and configuring Fail2ban
      4. MariaDB best practices
      5. Setting up a firewall
      6. Encrypting and decrypting disks with LUKS
      7. Locking down sudo
      8. Summary
    21. 13. Troubleshooting Ubuntu Servers
      1. Evaluating the problem space
      2. Conducting a root-cause analysis
      3. Viewing system logs
      4. Tracing network issues
      5. Troubleshooting resource issues
      6. Diagnosing defective RAM
      7. Summary
    22. 14. Preventing and Recovering from Disasters
      1. Preventing disasters
      2. Utilizing Git for configuration management
      3. Implementing a backup plan
      4. Creating system images with Clonezilla live
      5. Utilizing bootable recovery media
      6. Summary
    23. Index

Product information

  • Title: Mastering Ubuntu Server
  • Author(s): Jay LaCroix
  • Release date: July 2016
  • Publisher(s): Packt Publishing
  • ISBN: 9781785284526