{"id":2982,"date":"2020-04-03T23:43:00","date_gmt":"2020-04-03T18:13:00","guid":{"rendered":"https:\/\/www.24x7serversupport.com\/blog\/?p=2982"},"modified":"2020-04-04T17:55:48","modified_gmt":"2020-04-04T12:25:48","slug":"how-to-install-php-7-4-7-3-7-2-on-centos-rhel-7","status":"publish","type":"post","link":"https:\/\/www.24x7serversupport.com\/blog\/how-to-install-php-7-4-7-3-7-2-on-centos-rhel-7\/","title":{"rendered":"How To Install PHP 7.4, 7.3 &#038; 7.2 on CentOS\/RHEL 7"},"content":{"rendered":"\n<p>The PHP 7.4 is the latest stable release of PHP. The <strong>CentOS 7<\/strong> official software repositories have <strong>PHP 5.5<\/strong> which has reached the end of life and no longer actively maintained by the developers. <\/p>\n\n\n\n<p>Firstly, we will need to enable epel repo and then remi repo. Use the following command to install EPEL repository on your CentOS and Red Hat 7 systems:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># yum install epel-release<\/pre>\n\n\n\n<p>Then install remi repository:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># rpm -Uvh http:\/\/rpms.famillecollet.com\/enterprise\/remi-release-7.rpm<\/pre>\n\n\n\n<p>Use one of the following commands to install PHP 7.4 or PHP 7.3 or PHP 7.2 or PHP 7.1 on your system based on your requirements:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">## Install PHP 7.4 \nyum --enablerepo=remi-php74 install php\n\n## Install PHP 7.3 \nyum --enablerepo=remi-php73 install php\n\n## Install PHP 7.2 \nyum --enablerepo=remi-php72 install php\n\n## Install PHP 7.1 \nyum --enablerepo=remi-php71 install php<\/pre>\n\n\n\n<p>For now, we have installed latest version PHP 7.4<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># <strong>php -v<\/strong>\n\nPHP 7.4.1 (cli) (built: Dec 17 2019 16:35:58) ( NTS )\nCopyright (c) The PHP Group\nZend Engine v3.4.0, Copyright (c) Zend Technologies<\/pre>\n\n\n\n<p>Then you can install corresponding PHP extensions:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># yum --enablerepo=remi-php74 install php-xml php-soap php-xmlrpc php-mbstring php-json php-gd php-mcrypt<\/pre>\n\n\n\n<p>You can check the modules\/extensions using below command:<\/p>\n\n\n\n<p># php -m<\/p>\n","protected":false},"excerpt":{"rendered":"<p>The PHP 7.4 is the latest stable release of PHP. The CentOS 7 official software repositories have PHP 5.5 which has reached the end of life and no longer actively maintained by the developers. Firstly, we will need to enable epel repo and then remi repo. Use the following command to install EPEL repository on [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","enabled":false}}},"categories":[30,34],"tags":[278,276,277],"class_list":["post-2982","post","type-post","status-publish","format-standard","hentry","category-centos","category-linux","tag-epel","tag-php-7-4","tag-remi-repo"],"jetpack_publicize_connections":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v22.5 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>How To Install PHP 7.4, 7.3 &amp; 7.2 on CentOS\/RHEL 7 | 24x7serversupport Blog<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.24x7serversupport.com\/blog\/how-to-install-php-7-4-7-3-7-2-on-centos-rhel-7\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How To Install PHP 7.4, 7.3 &amp; 7.2 on CentOS\/RHEL 7 | 24x7serversupport Blog\" \/>\n<meta property=\"og:description\" content=\"The PHP 7.4 is the latest stable release of PHP. The CentOS 7 official software repositories have PHP 5.5 which has reached the end of life and no longer actively maintained by the developers. Firstly, we will need to enable epel repo and then remi repo. Use the following command to install EPEL repository on [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.24x7serversupport.com\/blog\/how-to-install-php-7-4-7-3-7-2-on-centos-rhel-7\/\" \/>\n<meta property=\"og:site_name\" content=\"24x7serversupport Blog\" \/>\n<meta property=\"article:published_time\" content=\"2020-04-03T18:13:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2020-04-04T12:25:48+00:00\" \/>\n<meta name=\"author\" content=\"24x7support\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@24x7serversuppo\" \/>\n<meta name=\"twitter:site\" content=\"@24x7serversuppo\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"24x7support\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"1 minute\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.24x7serversupport.com\/blog\/how-to-install-php-7-4-7-3-7-2-on-centos-rhel-7\/\",\"url\":\"https:\/\/www.24x7serversupport.com\/blog\/how-to-install-php-7-4-7-3-7-2-on-centos-rhel-7\/\",\"name\":\"How To Install PHP 7.4, 7.3 & 7.2 on CentOS\/RHEL 7 | 24x7serversupport Blog\",\"isPartOf\":{\"@id\":\"https:\/\/www.24x7serversupport.com\/blog\/#website\"},\"datePublished\":\"2020-04-03T18:13:00+00:00\",\"dateModified\":\"2020-04-04T12:25:48+00:00\",\"author\":{\"@id\":\"https:\/\/www.24x7serversupport.com\/blog\/#\/schema\/person\/decfb5fad6bde6ac6822d4e965c6d401\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.24x7serversupport.com\/blog\/how-to-install-php-7-4-7-3-7-2-on-centos-rhel-7\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.24x7serversupport.com\/blog\/how-to-install-php-7-4-7-3-7-2-on-centos-rhel-7\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.24x7serversupport.com\/blog\/how-to-install-php-7-4-7-3-7-2-on-centos-rhel-7\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.24x7serversupport.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How To Install PHP 7.4, 7.3 &#038; 7.2 on CentOS\/RHEL 7\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.24x7serversupport.com\/blog\/#website\",\"url\":\"https:\/\/www.24x7serversupport.com\/blog\/\",\"name\":\"24x7serversupport Blog\",\"description\":\"Linux | CPanel | WHM | webhosting| Plesk | DirectAdmin | CentOs | Debian | Ubuntu Blog\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.24x7serversupport.com\/blog\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.24x7serversupport.com\/blog\/#\/schema\/person\/decfb5fad6bde6ac6822d4e965c6d401\",\"name\":\"24x7support\",\"url\":\"https:\/\/www.24x7serversupport.com\/blog\/author\/24x7support\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How To Install PHP 7.4, 7.3 & 7.2 on CentOS\/RHEL 7 | 24x7serversupport Blog","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.24x7serversupport.com\/blog\/how-to-install-php-7-4-7-3-7-2-on-centos-rhel-7\/","og_locale":"en_US","og_type":"article","og_title":"How To Install PHP 7.4, 7.3 & 7.2 on CentOS\/RHEL 7 | 24x7serversupport Blog","og_description":"The PHP 7.4 is the latest stable release of PHP. The CentOS 7 official software repositories have PHP 5.5 which has reached the end of life and no longer actively maintained by the developers. Firstly, we will need to enable epel repo and then remi repo. Use the following command to install EPEL repository on [&hellip;]","og_url":"https:\/\/www.24x7serversupport.com\/blog\/how-to-install-php-7-4-7-3-7-2-on-centos-rhel-7\/","og_site_name":"24x7serversupport Blog","article_published_time":"2020-04-03T18:13:00+00:00","article_modified_time":"2020-04-04T12:25:48+00:00","author":"24x7support","twitter_card":"summary_large_image","twitter_creator":"@24x7serversuppo","twitter_site":"@24x7serversuppo","twitter_misc":{"Written by":"24x7support","Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.24x7serversupport.com\/blog\/how-to-install-php-7-4-7-3-7-2-on-centos-rhel-7\/","url":"https:\/\/www.24x7serversupport.com\/blog\/how-to-install-php-7-4-7-3-7-2-on-centos-rhel-7\/","name":"How To Install PHP 7.4, 7.3 & 7.2 on CentOS\/RHEL 7 | 24x7serversupport Blog","isPartOf":{"@id":"https:\/\/www.24x7serversupport.com\/blog\/#website"},"datePublished":"2020-04-03T18:13:00+00:00","dateModified":"2020-04-04T12:25:48+00:00","author":{"@id":"https:\/\/www.24x7serversupport.com\/blog\/#\/schema\/person\/decfb5fad6bde6ac6822d4e965c6d401"},"breadcrumb":{"@id":"https:\/\/www.24x7serversupport.com\/blog\/how-to-install-php-7-4-7-3-7-2-on-centos-rhel-7\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.24x7serversupport.com\/blog\/how-to-install-php-7-4-7-3-7-2-on-centos-rhel-7\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.24x7serversupport.com\/blog\/how-to-install-php-7-4-7-3-7-2-on-centos-rhel-7\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.24x7serversupport.com\/blog\/"},{"@type":"ListItem","position":2,"name":"How To Install PHP 7.4, 7.3 &#038; 7.2 on CentOS\/RHEL 7"}]},{"@type":"WebSite","@id":"https:\/\/www.24x7serversupport.com\/blog\/#website","url":"https:\/\/www.24x7serversupport.com\/blog\/","name":"24x7serversupport Blog","description":"Linux | CPanel | WHM | webhosting| Plesk | DirectAdmin | CentOs | Debian | Ubuntu Blog","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.24x7serversupport.com\/blog\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/www.24x7serversupport.com\/blog\/#\/schema\/person\/decfb5fad6bde6ac6822d4e965c6d401","name":"24x7support","url":"https:\/\/www.24x7serversupport.com\/blog\/author\/24x7support\/"}]}},"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_likes_enabled":true,"jetpack-related-posts":[],"_links":{"self":[{"href":"https:\/\/www.24x7serversupport.com\/blog\/wp-json\/wp\/v2\/posts\/2982","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.24x7serversupport.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.24x7serversupport.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.24x7serversupport.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.24x7serversupport.com\/blog\/wp-json\/wp\/v2\/comments?post=2982"}],"version-history":[{"count":1,"href":"https:\/\/www.24x7serversupport.com\/blog\/wp-json\/wp\/v2\/posts\/2982\/revisions"}],"predecessor-version":[{"id":2983,"href":"https:\/\/www.24x7serversupport.com\/blog\/wp-json\/wp\/v2\/posts\/2982\/revisions\/2983"}],"wp:attachment":[{"href":"https:\/\/www.24x7serversupport.com\/blog\/wp-json\/wp\/v2\/media?parent=2982"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.24x7serversupport.com\/blog\/wp-json\/wp\/v2\/categories?post=2982"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.24x7serversupport.com\/blog\/wp-json\/wp\/v2\/tags?post=2982"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}