Différences

Ci-dessous, les différences entre deux révisions de la page.

Lien vers cette vue comparative

Prochaine révision
Révision précédente
elearning:workbooks:redhat:rh124en:l111 [2024/11/12 11:15] – created adminelearning:workbooks:redhat:rh124en:l111 [2024/11/28 10:06] (Version actuelle) admin
Ligne 5: Ligne 5:
 Last update : ~~LASTMOD~~ Last update : ~~LASTMOD~~
  
-======RH12412 - Service and daemon management======+======RH12412 - Service and Daemon Management======
  
 =====Contents===== =====Contents=====
Ligne 58: Ligne 58:
   * **reboot.target** - restarts the system.   * **reboot.target** - restarts the system.
  
-**Systemd** uses Targets in a similar way to how SysVinit** uses runlevels. To make the transition easier, there are **Targets** which ‘simulate’ the execution levels of **SysVinit** :+**Systemd** uses Targets in a similar way to how **SysVinit** uses runlevels. To make the transition easier, there are **Targets** which ‘simulate’ the run levels of **SysVinit** :
  
 <code> <code>
Ligne 86: Ligne 86:
 </code> </code>
  
-====LAB #1 - The systemctl==== command+====LAB #1 - The systemctl command====
  
 To view the list of Units, use the **systemctl** command with the **list-units** option: To view the list of Units, use the **systemctl** command with the **list-units** option:
Ligne 354: Ligne 354:
 </code> </code>
  
-There are also other executables responsible for generating other :+There are also other executables responsible for generating other files:
  
 <code> <code>
Ligne 562: Ligne 562:
     * This directive specifies targets that should be reached and units that should be started before the sshd unit. However, this directive does not specify a dependency,     * This directive specifies targets that should be reached and units that should be started before the sshd unit. However, this directive does not specify a dependency,
   * **Wants=sshd-keygen.target**,   * **Wants=sshd-keygen.target**,
-    * This directive specifies a soft dependency. In other words, Systemd will try to start the **sshd-keygen.target** unit, but if this fails, the sshd unit will be started.+    * This directive specifies a soft dependency. In other words, Systemd will try to start the **sshd-keygen.target** unit, but if this fails, the sshd unit will be started regardless.
  
 The file also contains the following lines in the **[Service]** section: The file also contains the following lines in the **[Service]** section:
Ligne 708: Ligne 708:
 </code> </code>
  
-===2.2 - Overriding Default Configuration Files===+===2.2 - Overriding the Default Configuration Files===
  
 Default configuration files can also be overridden by files in other directories: Default configuration files can also be overridden by files in other directories:
Ligne 748: Ligne 748:
 ====LAB #3 - The systemd-analyze command==== ====LAB #3 - The systemd-analyze command====
  
-To obtain an evaluation of the start-up time, use the following command:+To consult the system start-up timeline, use the following command:
  
 <code> <code>
Ligne 756: Ligne 756:
 </code> </code>
  
-The **blame** option in the systemd-analyze command allows you to see the boot time of each Unit so that you can concentrate on the slowest:+The **blame** option in the systemd-analyze command allows you to see the boot time of each individual Unit so that you can concentrate on the slowest ones:
  
 <code> <code>
Ligne 908: Ligne 908:
 </code> </code>
  
-====LAB #4 - Targets Systemd====+====LAB #4 - Systemd Targets ====
  
 Each Target is described in a configuration file: Each Target is described in a configuration file:
Ligne 944: Ligne 944:
     * This line indicates which service should be started.     * This line indicates which service should be started.
  
-===4.1 - Checking the dependencies of a Target===+===4.1 - Checking Target dependencies===
  
 The dependencies of a Target can be checked using the **systemctl list-dependencies** command: The dependencies of a Target can be checked using the **systemctl list-dependencies** command:
Ligne 1131: Ligne 1131:
 </code> </code>
  
-====LAB #5 - Services management====+====LAB #5 - Managing Services====
  
 ===5.1 - Managing Single Instances=== ===5.1 - Managing Single Instances===
Ligne 1139: Ligne 1139:
 <code> <code>
 [root@redhat9 ~]# dnf install httpd [root@redhat9 ~]# dnf install httpd
-Updating Subscription Management repositories. 
-Last metadata expiration check: 1:59:56 ago on Thu 26 Sep 2024 12:57:02 PM CEST. 
-Dependencies resolved. 
-================================================================================================================================================================================================================== 
- Package                                           Architecture                          Version                                            Repository                                                       Size 
-================================================================================================================================================================================================================== 
-Installing: 
- httpd                                             x86_64                                2.4.57-11.el9_4.1                                  rhel-9-for-x86_64-appstream-rpms                                 51 k 
-Installing dependencies: 
- apr                                               x86_64                                1.7.0-12.el9_3                                     rhel-9-for-x86_64-appstream-rpms                                126 k 
- apr-util                                          x86_64                                1.6.1-23.el9                                       rhel-9-for-x86_64-appstream-rpms                                 97 k 
- apr-util-bdb                                      x86_64                                1.6.1-23.el9                                       rhel-9-for-x86_64-appstream-rpms                                 14 k 
- httpd-core                                        x86_64                                2.4.57-11.el9_4.1                                  rhel-9-for-x86_64-appstream-rpms                                1.5 M 
- httpd-filesystem                                  noarch                                2.4.57-11.el9_4.1                                  rhel-9-for-x86_64-appstream-rpms                                 14 k 
- httpd-tools                                       x86_64                                2.4.57-11.el9_4.1                                  rhel-9-for-x86_64-appstream-rpms                                 86 k 
- redhat-logos-httpd                                noarch                                90.4-2.el9                                         rhel-9-for-x86_64-appstream-rpms                                 18 k 
-Installing weak dependencies: 
- apr-util-openssl                                  x86_64                                1.6.1-23.el9                                       rhel-9-for-x86_64-appstream-rpms                                 17 k 
- mod_http2                                         x86_64                                2.0.26-2.el9_4                                     rhel-9-for-x86_64-appstream-rpms                                167 k 
- mod_lua                                           x86_64                                2.4.57-11.el9_4.1                                  rhel-9-for-x86_64-appstream-rpms                                 60 k 
- 
-Transaction Summary 
-================================================================================================================================================================================================================== 
-Install  11 Packages 
- 
-Total download size: 2.2 M 
-Installed size: 6.0 M 
-Is this ok [y/N]: y 
-Downloading Packages: 
-(1/11): apr-util-bdb-1.6.1-23.el9.x86_64.rpm                                                                                                                                       28 kB/s |  14 kB     00:00     
-(2/11): apr-util-openssl-1.6.1-23.el9.x86_64.rpm                                                                                                                                   31 kB/s |  17 kB     00:00     
-(3/11): apr-util-1.6.1-23.el9.x86_64.rpm                                                                                                                                          165 kB/s |  97 kB     00:00     
-(4/11): redhat-logos-httpd-90.4-2.el9.noarch.rpm                                                                                                                                   69 kB/s |  18 kB     00:00     
-(5/11): apr-1.7.0-12.el9_3.x86_64.rpm                                                                                                                                             374 kB/s | 126 kB     00:00     
-(6/11): mod_http2-2.0.26-2.el9_4.x86_64.rpm                                                                                                                                       435 kB/s | 167 kB     00:00     
-(7/11): httpd-core-2.4.57-11.el9_4.1.x86_64.rpm                                                                                                                                   2.9 MB/s | 1.5 MB     00:00     
-(8/11): httpd-filesystem-2.4.57-11.el9_4.1.noarch.rpm                                                                                                                              31 kB/s |  14 kB     00:00     
-(9/11): httpd-2.4.57-11.el9_4.1.x86_64.rpm                                                                                                                                         63 kB/s |  51 kB     00:00     
-(10/11): httpd-tools-2.4.57-11.el9_4.1.x86_64.rpm                                                                                                                                 297 kB/s |  86 kB     00:00     
-(11/11): mod_lua-2.4.57-11.el9_4.1.x86_64.rpm                                                                                                                                     154 kB/s |  60 kB     00:00     
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- 
-Total                                                                                                                                                                             1.2 MB/s | 2.2 MB     00:01      
-Running transaction check 
-Transaction check succeeded. 
-Running transaction test 
-Transaction test succeeded. 
-Running transaction 
-  Preparing        :                                                                                                                                                                                          1/1  
-  Installing       : apr-1.7.0-12.el9_3.x86_64                                                                                                                                                               1/11  
-  Installing       : apr-util-bdb-1.6.1-23.el9.x86_64                                                                                                                                                        2/11  
-  Installing       : apr-util-openssl-1.6.1-23.el9.x86_64                                                                                                                                                    3/11  
-  Installing       : apr-util-1.6.1-23.el9.x86_64                                                                                                                                                            4/11  
-  Installing       : httpd-tools-2.4.57-11.el9_4.1.x86_64                                                                                                                                                    5/11  
-  Running scriptlet: httpd-filesystem-2.4.57-11.el9_4.1.noarch                                                                                                                                               6/11  
-  Installing       : httpd-filesystem-2.4.57-11.el9_4.1.noarch                                                                                                                                               6/11  
-  Installing       : httpd-core-2.4.57-11.el9_4.1.x86_64                                                                                                                                                     7/11  
-  Installing       : mod_lua-2.4.57-11.el9_4.1.x86_64                                                                                                                                                        8/11  
-  Installing       : redhat-logos-httpd-90.4-2.el9.noarch                                                                                                                                                    9/11  
-  Installing       : mod_http2-2.0.26-2.el9_4.x86_64                                                                                                                                                        10/11  
-  Installing       : httpd-2.4.57-11.el9_4.1.x86_64                                                                                                                                                         11/11  
-  Running scriptlet: httpd-2.4.57-11.el9_4.1.x86_64                                                                                                                                                         11/11  
-  Verifying        : apr-util-1.6.1-23.el9.x86_64                                                                                                                                                            1/11  
-  Verifying        : apr-util-bdb-1.6.1-23.el9.x86_64                                                                                                                                                        2/11  
-  Verifying        : apr-util-openssl-1.6.1-23.el9.x86_64                                                                                                                                                    3/11  
-  Verifying        : redhat-logos-httpd-90.4-2.el9.noarch                                                                                                                                                    4/11  
-  Verifying        : apr-1.7.0-12.el9_3.x86_64                                                                                                                                                               5/11  
-  Verifying        : mod_http2-2.0.26-2.el9_4.x86_64                                                                                                                                                         6/11  
-  Verifying        : httpd-2.4.57-11.el9_4.1.x86_64                                                                                                                                                          7/11  
-  Verifying        : httpd-core-2.4.57-11.el9_4.1.x86_64                                                                                                                                                     8/11  
-  Verifying        : httpd-filesystem-2.4.57-11.el9_4.1.noarch                                                                                                                                               9/11  
-  Verifying        : httpd-tools-2.4.57-11.el9_4.1.x86_64                                                                                                                                                   10/11  
-  Verifying        : mod_lua-2.4.57-11.el9_4.1.x86_64                                                                                                                                                       11/11  
-Installed products updated. 
- 
-Installed: 
-  apr-1.7.0-12.el9_3.x86_64                apr-util-1.6.1-23.el9.x86_64                  apr-util-bdb-1.6.1-23.el9.x86_64         apr-util-openssl-1.6.1-23.el9.x86_64     httpd-2.4.57-11.el9_4.1.x86_64       
-  httpd-core-2.4.57-11.el9_4.1.x86_64      httpd-filesystem-2.4.57-11.el9_4.1.noarch     httpd-tools-2.4.57-11.el9_4.1.x86_64     mod_http2-2.0.26-2.el9_4.x86_64          mod_lua-2.4.57-11.el9_4.1.x86_64     
-  redhat-logos-httpd-90.4-2.el9.noarch     
- 
-Complete! 
 </code> </code>
  
Menu