{"id":2029,"date":"2024-06-20T23:54:16","date_gmt":"2022-06-14T14:50:03","guid":{"rendered":""},"modified":"2025-02-02T00:46:18","modified_gmt":"2025-02-01T23:46:18","slug":"how-to-install-magento-ecommerce-suite-on-rocky-linux-9-with-elasticsearch","status":"publish","type":"post","link":"https:\/\/netcloud24.com\/knowledgebase\/how-to-install-magento-ecommerce-suite-on-rocky-linux-9-with-elasticsearch\/","title":{"rendered":"Linux VPS &#038; VPS Windows Setup Guide | NetCloud24 Magento eCommerce Suite on Rocky Linux 9 with Elasticsearch"},"content":{"rendered":"<p>\u00a0<\/p>\n<\/p>\n<header>\n<h1>\u00a0<\/h1>\n<\/header>\n<article>\n<p>In this guide, we will walk you through the process of installing the <strong>Magento eCommerce Suite<\/strong> on <strong>Rocky Linux 9<\/strong> using <strong>Elasticsearch<\/strong>. Magento is a powerful eCommerce platform, and Elasticsearch is essential for optimizing its search functionality, providing fast and relevant search results for your online store.<\/p>\n<p>Using a  can significantly improve the performance of your Magento store, thanks to its dedicated resources and reliable performance. In this tutorial, we will assume you&#8217;re setting up Magento on a <strong>VPS server<\/strong> running Rocky Linux 9.<\/p>\n<h2>Step 1: Prepare Your VPS Server<\/h2>\n<p>First, you need to ensure that your <a href=\"https:\/\/ie.netcloud24.com\">VPS server<\/a> is ready for Magento installation. We recommend using a  for its scalability and excellent performance. Follow these steps to prepare your server:<\/p>\n<ul>\n<ul>\n<li>Update your server packages:<\/li>\n<\/ul>\n<\/ul>\n<pre><code>sudo dnf update -y<\/code><\/pre>\n<ul>\n<ul>\n<li>Install essential software dependencies for Magento:<\/li>\n<\/ul>\n<\/ul>\n<pre><code>sudo dnf install epel-release wget curl -y<\/code><\/pre>\n<h2>Step 2: Install Apache, MySQL, and PHP<\/h2>\n<p>Magento requires Apache or Nginx, MySQL, and PHP. In this example, we will use Apache:<\/p>\n<ul>\n<ul>\n<li>Install Apache:<\/li>\n<\/ul>\n<\/ul>\n<pre><code>sudo dnf install httpd -y<\/code><\/pre>\n<ul>\n<ul>\n<li>Enable Apache to start at boot and then start the service:<\/li>\n<\/ul>\n<\/ul>\n<pre><code>sudo systemctl enable httpd --now<\/code><\/pre>\n<ul>\n<ul>\n<li>Install MySQL (MariaDB):<\/li>\n<\/ul>\n<\/ul>\n<pre><code>sudo dnf install mariadb-server -y<\/code><\/pre>\n<ul>\n<ul>\n<li>Start MariaDB and secure the installation:<\/li>\n<\/ul>\n<\/ul>\n<pre><code>\r\nsudo systemctl enable mariadb --now\r\nsudo mysql_secure_installation\r\n<\/code><\/pre>\n<ul>\n<ul>\n<li>Install PHP 7.4 or newer:<\/li>\n<\/ul>\n<\/ul>\n<pre><code>sudo dnf install php php-cli php-mysqlnd php-fpm php-json php-gd -y<\/code><\/pre>\n<h2>Step 3: Install Elasticsearch<\/h2>\n<p>Magento requires Elasticsearch to provide fast and relevant search capabilities. To install Elasticsearch, follow these steps:<\/p>\n<ul>\n<ul>\n<li>Download and install the Elasticsearch RPM:<\/li>\n<\/ul>\n<\/ul>\n<pre><code>wget https:\/\/artifacts.elastic.co\/downloads\/elasticsearch\/elasticsearch-7.17.0-x86_64.rpm\r\nsudo rpm -ivh elasticsearch-7.17.0-x86_64.rpm\r\nsudo systemctl enable elasticsearch --now\r\n<\/code><\/pre>\n<h2>Step 4: Download and Install Magento<\/h2>\n<p>Now that the server and Elasticsearch are set up, it&#8217;s time to install Magento. You can download the latest version of Magento from their official website or via Composer:<\/p>\n<pre><code>composer create-project --repository-url=https:\/\/repo.magento.com\/ magento\/project-community-edition=2.4.5 \/var\/www\/html\/magento<\/code><\/pre>\n<ul>\n<ul>\n<li>Set the correct ownership and permissions:<\/li>\n<\/ul>\n<\/ul>\n<pre><code>sudo chown -R apache:apache \/var\/www\/html\/magento\r\nsudo chmod -R 755 \/var\/www\/html\/magento<\/code><\/pre>\n<h2>Step 5: Configure Apache for Magento<\/h2>\n<p>Next, configure Apache to serve Magento:<\/p>\n<ul>\n<ul>\n<li>Create a new Apache virtual host file:<\/li>\n<\/ul>\n<\/ul>\n<pre><code>sudo nano \/etc\/httpd\/conf.d\/magento.conf<\/code><\/pre>\n<ul>\n<ul>\n<li>Add the following configuration:<\/li>\n<\/ul>\n<\/ul>\n<pre><code>\r\n\r\n    ServerAdmin admin@example.com\r\n    DocumentRoot \/var\/www\/html\/magento\r\n    ServerName example.com\r\n    \r\n        AllowOverride All\r\n        Require all granted\r\n    \r\n    ErrorLog \/var\/log\/httpd\/magento-error.log\r\n    CustomLog \/var\/log\/httpd\/magento-access.log combined\r\n\r\n<\/code><\/pre>\n<p>Restart Apache to apply the changes:<\/p>\n<pre><code>sudo systemctl restart httpd<\/code><\/pre>\n<h2>Step 6: Finalize the Installation<\/h2>\n<p>Once everything is set up, you can access Magento by navigating to <code>http:\/\/your-server-ip<\/code> in your browser and follow the Magento web installation wizard.<\/p>\n<p>For a more robust and scalable solution, consider hosting your Magento store on a  server. A <strong>VPS<\/strong> gives you more control, flexibility, and dedicated resources compared to shared hosting environments.<\/p>\n<h2>Conclusion<\/h2>\n<p>Installing Magento on Rocky Linux 9 with Elasticsearch is straightforward if you follow the steps above. A  is a great option for hosting your eCommerce store due to its power and reliability, making it an ideal choice for growing online businesses. With your Magento platform ready, you can now start building your online store.<\/p>\n<p>If you&#8217;re looking for more VPS hosting options or need help managing your <strong>VPS server<\/strong>, visit  for more details.<\/p>\n<\/article>\n<footer>\n<p>\u00a9 2024 Windows VPS &#8211; All Rights Reserved<\/p>\n<\/footer>\n<div class=\"post-author-box\" style=\"border-top:1px solid #ddd;margin-top:20px;padding-top:15px;\">\n<p><strong>Author:<\/strong> \u0141ukasz Bodziony<\/p>\n<p><strong>Website:<\/strong> <a href=\"https:\/\/ca.netcloud24.com\" target=\"_blank\" rel=\"dofollow\">Windows VPS<\/a><\/p>\n<p><em>\u0141ukasz Bodziony is the CEO and founder of <a href=\"https:\/\/netcloud24.com\" target=\"_blank\" rel=\"dofollow\">NETCLOUD24<\/a>, a global VPS hosting brand proudly originating from Poland. With extensive experience in cloud computing, virtualization, and server management, he delivers high-performance <strong>Windows VPS<\/strong> and <strong>Remote Desktop Services (RDS)<\/strong> solutions to clients across Europe, North America, and beyond.<\/em><\/p>\n<p><em>His expertise covers a wide range of technologies, including <strong>Microsoft Azure<\/strong>, <strong>Proxmox VE<\/strong>, <strong>Amazon Web Services (AWS)<\/strong>, and numerous other virtualization and cloud platforms.<\/em><\/p>\n<p><em>Beyond running his hosting business, \u0141ukasz also provides <strong>professional paid server configuration and optimization services<\/strong> for companies and individuals. Outside of work, he is dedicated to caring for his children and building a secure future for them.<\/em><\/p>\n<p><em>If you are interested in working with him or need expert assistance with your hosting, cloud environment, or server setup, feel free to reach out via <a href=\"https:\/\/ca.netcloud24.com\" target=\"_blank\" rel=\"dofollow\">Windows VPS<\/a>.<\/em><\/p>\n<\/p><\/div>\n","protected":false},"excerpt":{"rendered":"<p>\u00a0 \u00a0 In this guide, we will walk you through the process of installing the Magento eCommerce Suite on Rocky Linux 9 using Elasticsearch. Magento is a powerful\u2026<\/p>\n","protected":false},"author":1,"featured_media":3421,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_seopress_robots_primary_cat":"","_seopress_titles_title":"","_seopress_titles_desc":"","_seopress_robots_index":"","footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2}},"categories":[],"tags":[14,12,11,23,20,21,22,17,7,8,6,10,18,19,15,24,16,5,13,9],"class_list":["post-2029","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","tag-cheapvps","tag-cloudvps","tag-hostingvps","tag-rds","tag-rdscal","tag-remotedesktop","tag-remotedesktopvps","tag-servervps","tag-ukvps","tag-virtualserver","tag-vpshosting","tag-vpsserver","tag-vpssolutions","tag-vpswindows","tag-vpswithwindows","tag-windowsrds","tag-windowsserver","tag-windowsvps","tag-windowsvpshosting","tag-windowsvpsuk"],"jetpack_publicize_connections":[],"_links":{"self":[{"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/posts\/2029","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/comments?post=2029"}],"version-history":[{"count":0,"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/posts\/2029\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/media\/3421"}],"wp:attachment":[{"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/media?parent=2029"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/categories?post=2029"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/tags?post=2029"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}