Mastering Linux System Administration. Richard Blum

Mastering Linux System Administration - Richard Blum


Скачать книгу
flatpak as a package using the standard dnf or rpm methods.

      image Real World Scenario

      INSTALLING FLATPAK

      The flatpak container format provides quick installation of many popular application programs. To use flatpak on your CentOS server, you'll need to first install the software package and then install the repository configuration by following these steps:

      1 Log onto your CentOS server as the root user account.

      2 From the command‐line prompt, enter the command dnf install flatpak. There are lots of dependencies required, so you'll see quite a few packages install.

      3 Once flatpak is installed, you will need to point it to a flatpak container repository. The most popular one is Flathub. Configure that by entering the command flatpak remote‐add ‐‐if‐not‐exists flathub https://flathub.org/repo/flathub.flatpakrepo. You should see output that's similar to this:# flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo Note that the directories '/var/lib/flatpak/exports/share' '/root/.local/share/flatpak/exports/share' are not in the search path set by the XDG_DATA_DIRS environment variable, so applications installed by Flatpak may not appear on your desktop until the session is restarted. #

      4 Test the flatpak command by entering the command flatpak list.# flatpak list #Not too exciting. When you first install flatpak, there won't be any containers installed, but now you know that flatpak is installed.

      To find an application in the flatpak repository, you use the flatpak search command.

      # flatpak search mosh Name Description Application ID Version Branch Remotes Mosh The Mobile Shell org.mosh.mosh 1.3.2 stable flathub #

      When working with a container, you must use its Application ID value and not its name. To install the application, use the flatpak install command.

      # flatpak install org.mosh.mosh Looking for matches… Found similar ref(s) for 'mosh' in remote 'flathub' (system). Use this remote? [Y/n]: y Found ref 'app/org.mosh.mosh/x86_64/stable' in remote 'flathub' (system). Use this ref? [Y/n]: y Required runtime for org.mosh.mosh/x86_64/stable (runtime/org.freedesktop.Platform/x86_64/20.08) found in remote flathub Do you want to install it? [Y/n]: y … Installation complete. #

      To check whether the installation went well, you can use the flatpak list command again.

      Finally, to remove an application container, use the flatpak uninstall command.

      # flatpak uninstall org.mosh.mosh ID Branch Op 1. [-] org.mosh.mosh stable r Uninstall complete. #

      Using application containers is similar to using package management systems, but what goes on behind the scenes is fundamentally different. However, the end result is that you have an application installed on your Linux system that can be easily maintained and upgraded.

       Recognize Red Hat packages. Developers bundle the files required for an application into a package to make it easier to install. A package management system allows you to easily track what software packages are installed on your Linux system, as well as install, update, and remove them. Red Hat–based Linux distributions use the Red Hat Package Management (RPM) system for managing application software. The rpm command‐line tool provides access to the package management database, allowing you to quickly determine the status of installed packages.Master It The curl software package allows you to easily transfer data using a multitude of protocols (such as FTP, HTTP, and SCP) from the command line. What command would you use to determine whether curl is installed on your Linux system? If the package is installed, what command would you use to view the version and a description of the package?

       Use automated Red Hat package managers. Most Red Hat–based Linux distributions are based on the rpm utility but use different front‐end tools at the command line. Red Hat, CentOS, and Fedora use dnf for installing and managing software packages. The dnf tool automatically installs any software packages required by the package you install.Master It The perf utility allows you to monitor the performance of a Linux system. What command would you use to check whether the perf software is available as an rpm package for your Linux system, and what command would you use to install it? What command would you use to remove it?

       Manually install Red Hat packages. Not all Linux systems are connected to the Internet, allowing the automated package management tools to connect to a repository. In those situations, you'll need to manually find and download RPM software packages and then use the rpm command to manually install the package. The most common options used to install software are the ‐Uvh options, which will update the package if it's already installed and provide verbose information on the installation progress.Master It What steps would you need to take to install the perf utility if your Linux system is not connected to the Internet?

        Install flatpak application containers. Application containers are relatively new in software package management. Containers bundle all of the software required for an application to run, including all files the application is dependent on. This makes containers portable and easily moved between systems. Red Hat Linux–based distributions use the flatpak container format.Master It Cointop is a terminal‐based application for tracking cryptocurrencies. What command would you use to check if there's a flatpak container for it, and what command would you use to install it?

      Конец ознакомительного фрагмента.

      Текст предоставлен ООО «ЛитРес».

      Прочитайте эту книгу целиком, купив полную легальную версию на ЛитРес.

      Безопасно оплатить книгу можно банковской картой Visa, MasterCard, Maestro, со счета мобильного телефона, с платежного терминала, в салоне МТС или Связной, через PayPal, WebMoney, Яндекс.Деньги, QIWI Кошелек, бонусными картами или другим удобным Вам способом.

/9j/4AAQSkZJRgABAQEBLAEsAAD/7SiAUGhvdG9zaG9wIDMuMAA4QklNBAQAAAAAACscAgAAAgAA HAJQAAlud2VocmthbXAcAgU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