Lädt...


🔧 How to Install Magento 2 on Shared Hosting ?


Nachrichtenbereich: 🔧 Programmierung
🔗 Quelle: dev.to

Because of its resource requirements and server limitations, Magento 2 might be difficult to install on shared hosting. If the hosting environment satisfies Magento's minimal criteria, it is feasible.

Pre-Installation Checklist

1. Verify Hosting Requirements:

  • PHP version: 7.4+ (or the latest version supported by Magento).
  • MySQL version: 5.7+ or MariaDB 10.4+.
  • Elasticsearch: May not be available on shared hosting (required for Magento 2.4+).
  • PHP Extensions: intl, soap, bcmath, gd, mbstring, xsl, cURL, zip, etc.
  • Composer Support: Some shared hosting providers include Composer, or you can use it locally.

2. Secure FTP and Database Access:

  • FTP credentials for uploading files.
  • A database (MySQL/MariaDB) created through cPanel.

3. Magento Package:

  • Download the Magento 2 ZIP file from the Magento Downloads page.

4. Domain or Subdomain:

  • Ensure your domain or subdomain points to the shared hosting account.

Step-by-Step Installation

1. Upload Magento Files

  • Download the Magento 2 ZIP package.
  • Extract it locally and upload the contents to your server using FTP or cPanel's File Manager.

2. Set File Permissions

  • After uploading, set the correct permissions: Folders: 755 Files: 644
  • Some shared hosting environments might require additional permission adjustments for pub, var, and generated directories.

3. Create a Database

  • Log in to cPanel.
  • Go to MySQL Databases:
  • Create a new database.
  • Create a new user and assign it to the database with ALL PRIVILEGES.

4. Configure Magento Installation

Navigate to your domain or subdomain in a browser (e.g., https://yourdomain.com).

The Magento Setup Wizard will start:

  • Readiness Check: Ensure your hosting meets the requirements.
  • Add Database Details: Enter the database name, username, and password.

Web Configuration:

  • Specify the Base URL (e.g., https://yourdomain.com).
  • Enable/disable HTTPS based on your SSL setup.
  • Admin Account: Create an admin username, password, and email.
  • Installation Path: Magento will configure itself.

5. Post-Installation Tasks

  • Set File Permissions Again:
chmod -R 775 pub var generated
chmod u+x bin/magento

You may need to do this via SSH or ask your hosting provider for assistance.

  • Run Indexers (Optional): If SSH access is available:
php bin/magento indexer:reindex
php bin/magento cache:flush

Without SSH, Magento automatically handles this after installation.

6. Fix Common Shared Hosting Issues

  • Cron Jobs: Configure cron jobs via cPanel for Magento's background processes. Example:
*/5 * * * * php /home/username/public_html/bin/magento cron:run
  • Elasticsearch Workaround: Magento 2.4+ requires Elasticsearch. If not available, use an earlier Magento version (like 2.3.x) or request Elasticsearch from your hosting provider.

Troubleshooting Tips

  • Slow Performance: Shared hosting is limited in resources; consider upgrading to VPS or cloud hosting.
  • Readiness Check Fails: Ensure all required PHP extensions are installed/enabled. Contact your hosting provider for assistance.
  • Composer Errors: Use Composer locally to install dependencies, then upload the files to the server.

Magento 2 may work on shared hosting for small-scale stores or testing environments. For a production site, VPS or dedicated hosting is highly recommended for better performance, security, and scalability.

...

🔧 How to Install Magento 2 on Shared Hosting ?


📈 36.82 Punkte
🔧 Programmierung

🔧 cPanel Hosting vs NGINX Hosting: A Comparison for Linux Hosting


📈 28.5 Punkte
🔧 Programmierung

🔧 How to install Node on cPanel shared hosting (without root access)


📈 25.96 Punkte
🔧 Programmierung

🕵️ Low CVE-2019-7935: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Low CVE-2019-7926: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Medium CVE-2020-24402: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Low CVE-2020-3715: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Magento CE/Magento EE up to 2.0.5 PHP Code Execution privilege escalation


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Medium CVE-2019-7858: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Medium CVE-2020-9576: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Medium CVE-2020-24401: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Low CVE-2019-7947: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Medium CVE-2019-7859: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Low CVE-2020-9577: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Low CVE-2019-7938: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Low CVE-2019-7927: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Low CVE-2020-24403: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Medium CVE-2019-7950: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Medium CVE-2019-7860: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Medium CVE-2020-9587: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Low CVE-2019-7940: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Low CVE-2019-7936: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Medium CVE-2020-24404: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Medium CVE-2019-7895: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Medium CVE-2019-7861: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Medium CVE-2020-9630: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Low CVE-2019-7944: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Low CVE-2019-7937: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Low CVE-2020-24405: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Medium CVE-2019-7913: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Low CVE-2019-7862: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Medium CVE-2020-9583: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Low CVE-2019-7945: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Low CVE-2019-7939: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

🕵️ Low CVE-2020-24406: Magento Magento


📈 21.71 Punkte
🕵️ Sicherheitslücken

matomo