Mastering Linux System Administration. Richard Blum

Чтение книги онлайн.

Читать онлайн книгу Mastering Linux System Administration - Richard Blum страница 23

Mastering Linux System Administration - Richard Blum

Скачать книгу

password you used to log into the system.

      Congratulations! You've installed Ubuntu Server as a VM within the VirtualBox hypervisor. Now that the installation process is complete, it's a good idea to check and make sure everything is OK. We'll cover that next.

      Though the system may appear fine after an initial installation, it's wise to check. It may be tricky to understand everything you are looking at in this section, but reviewing this information will help as we cover these utilities and concepts in detail later in the book. Also, you can return to this section the next time you perform an Ubuntu distribution installation for guidance.

      First, boot your Ubuntu Server VM. After the system has booted, log into the tty2 terminal, and do the following:

       Check for boot errors. There are three commands that can help you check for boot errors, and none of them requires the sudo command to run. The first is dmesg. This will display the kernel ring buffer, but that data is useful only if you check it soon after the system has booted.To see boot messages long after a system boot, type less /var/log/bootstrap.log at the prompt and press Enter. You can move forward through this log by pressing the spacebar. When you are done looking at the information, press the Q key to return to the command‐line prompt.Finally, you can look for boot errors and all kinds of messages via the journalctl command. To peruse this information, you will need to press the spacebar to move forward and then the Q key to quit your viewing.

       Determine the default boot level. The default boot level on a Linux system determines what applications are started when the system boots. The command to see this information is systemctl get‐default. It does not require the sudo command to use.Most likely, you will see graphical.target when you issue this command, meaning that if graphical user interface (GUI) software is available, the GUI will start on bootup. However, on Ubuntu Server, since GUI software is not installed by default, this response from the systemctl get‐default command does not indicate a GUI is provided.

       Check version information. Determining the version numbers of the system's main components is helpful when tracking down problems. First, make sure you have the right Ubuntu Server distribution version installed by typing cat /etc/issue at the prompt. The version is in the first few words of the displayed line.Check the Linux kernel version too. This is important to know because different features (and bugs!) exist in the various kernel versions. To see this information, you need to type uname ‐r at the command‐line prompt. You can also view this information via the cat /proc/version command.Finally, look at the version of the Bash shell running on the system. This is easy to accomplish with the bash ‐‐version command.

      Once you've completed your checks, celebrate! You worked hard to get this Ubuntu Server distribution installed correctly.

       Review needed Ubuntu server hardware resources. Determining the hardware resources required for an Ubuntu installation on a physical or virtualized server helps to ensure a successful completion of the install. It also avoids wasting time.Master It Imagine that you need to install the Ubuntu Server on a physical server that has a dual‐core 1 GHz CPU, a 200 GB hard drive, and 10 GB of RAM. Are the server's resources sufficient? Why or why not?

       Determine the requirements for a virtual Ubuntu system. Installing the Ubuntu Server distribution on as a VM on a host system has different requirements than a direct installation on a physical server. It is critical to evaluate the host system so that the installation is successful.Master It Your project team is planning on installing two Ubuntu Server VMs on a host system that has a dual‐core 1 GHz CPU, a 200 GB hard drive, and 10 GB of RAM. Are the host system's resources sufficient? Why or why not?

       Obtain Ubuntu Server software. To install the Ubuntu Server Linux distribution, you must have the proper ISO image file. This is true whether you are installing it directly on hardware or as a VM. Besides getting the ISO file, you need to ensure that it is not corrupted so that the installation proceeds well.Master It You've downloaded the Ubuntu Server ISO image file but are concerned that during the download process, file corruption occurred. What should you do to see whether the ISO image file is corrupt?

       Conduct an installation of an Ubuntu Server. There are several steps to successfully install an Ubuntu Server, and it is critical that you complete all of them. Skipping a step can cause problems immediately, and problems later, if you can even get the system to boot.Master It Your sysadmin team has correctly installed the Ubuntu Server software from the ISO image file, and the system booted without any problems. What's the next step?

        Audit the Ubuntu Server's installation. If you had some problems while booting the system, there are a few commands you can use to look at helpful boot messages. But even a successful installation still requires a few additional checks.Master It At your company, you have completed the entire Ubuntu Server installation process on a new system without any problems for the development team. The team wants to know what version of the Linux kernel is used on this new system. How do you get that information?

      In the old days of Linux, installing software could be a painful experience. Fortunately, the Linux developers have made life a little easier for us by bundling software into prebuilt packages that are much easier to install. However, there's still a little work on your part to get the software packages installed, especially if you want to do so from the command line on a server.

       IN THIS CHAPTER, YOU WILL LEARN TO

       Explore different Linux software package management systems

       Use Debian software packages to install software

       Install applications using Debian snap containers

       Install software from source code

      Before diving into the world of Linux software package management, this chapter goes through a few of the basics of how Linux manages application software. Each of the major Linux distributions utilizes some form of a package management system to control installing software applications and libraries. A package management system uses a database that keeps track of the following:

       What software packages are installed on the Linux system

       What files have been installed for each package

       Versions of each of the software packages installed

      Software packages are stored on servers, called repositories, and are accessed across the Internet via package management system utilities running on your local Linux system. You can use these utilities to search for new software packages or even updates to software packages already installed on the system.

      A software package will often have dependencies, or other packages that must be installed first for the software to run properly. The package management system utilities will detect these dependencies and offer to install any additionally needed software packages before installing the desired package.

Скачать книгу