PHP 7.4 : Install2021/08/02 |
Install PHP 7.4.
|
|
[1] | Confirm the current enabled version of PHP and Install it. |
[root@dlp ~]# dnf module list php Rocky Linux 8 - AppStream Name Stream Profiles Summary php 7.2 [d] common [d], devel, minimal PHP scripting language php 7.3 [e] common [d], devel, minimal PHP scripting language php 7.4 common [d], devel, minimal PHP scripting language Hint: [d]efault, [e]nabled, [x]disabled, [i]nstalled # if other versions are enabled, reset once and switch to the version [root@dlp ~]# dnf module -y reset php [root@dlp ~]# dnf module -y enable php:7.4
# specify PHP 7.4 and install [root@dlp ~]# dnf module -y install php:7.4/common Dependencies resolved. ================================================================================ Package Architecture Version Repository Size ================================================================================ Enabling module streams: php 7.4 Transaction Summary ================================================================================ Complete! [root@dlp ~]# dnf module -y install php:7.4/common Last metadata expiration check: 0:38:49 ago on Mon 02 Aug 2021 11:02:46 AM JST. Dependencies resolved. ================================================================================ Package Arch Version Repository Size ================================================================================ Upgrading: php-cli x86_64 7.4.6-4.module+el8.4.0+415+e936cba3 appstream 3.1 M php-common x86_64 7.4.6-4.module+el8.4.0+415+e936cba3 appstream 694 k php-fpm x86_64 7.4.6-4.module+el8.4.0+415+e936cba3 appstream 1.6 M php-json x86_64 7.4.6-4.module+el8.4.0+415+e936cba3 appstream 73 k php-mbstring x86_64 7.4.6-4.module+el8.4.0+415+e936cba3 appstream 482 k php-xml x86_64 7.4.6-4.module+el8.4.0+415+e936cba3 appstream 173 k Installing module profiles: php/common Transaction Summary ================================================================================ Upgrade 6 Packages ..... .....[root@dlp ~]# php -v PHP 7.4.6 (cli) (built: May 12 2020 08:09:15) ( NTS ) Copyright (c) The PHP Group Zend Engine v3.4.0, Copyright (c) Zend Technologies # verify to create test script [root@dlp ~]# echo "<?php echo 'PHP 7.4 Test Page'.\"\n\"; ?>" > php_test.php [root@dlp ~]# php php_test.php PHP 7.4 Test Page |
Sponsored Link |