Facebook Twitter Instagram
    TecAdmin
    • Home
    • FeedBack
    • Submit Article
    • About Us
    Facebook Twitter Instagram
    TecAdmin
    You are at:Home»CMS»How to Install Moodle 3.8 on Fedora 32/31/30

    How to Install Moodle 3.8 on Fedora 32/31/30

    By RahulMay 12, 20202 Mins Read

    Moodle is a free and open source course management system (CMS) written in PHP. You can create courses complete learning platform with Moodle. This article will help you to install Moodle 3.8 on Fedora 32/31/30/29 system.

    Advertisement

    Prerequisites

    First of all, you need to set up a LAMP environment to install Moodle on your Fedora system. We assume that you already have PHP, MySQL and Apache installed on your system. If you don’t have, use the following article to install it.

    • Install Apache, PHP, & MySQL on Fedora

    Step 1 – Getting Moodle Application

    After installing the composer on your Fedora system. Let’s create CakePHP application named “MyApp” using composer command as below.

    cd /var/www
    git clone -b MOODLE_38_STABLE git://git.moodle.org/moodle.git
    

    Now set the proper permission for your project files. For Red Hat based system Apache default uses apache as the user. So change files ownership as per your setup.

    chown -R apache:apache moodle
    chmod -R 755 moodle
    

    Step 2 – Setup Moodle Data

    Create a Moodle data directory outside of the original Moodle directory. Set the proper permissions on the directory. This directory is used by Moodle to store data, files to this directory.

    mkdir /var/www/moodledata
    chmod -R 755 /var/www/moodledata
    

    Step 3 – Create Database for Moodle

    For this article, we are using MySQL as the database server. First use the following commands to create a MySQL database and create.

    1
    2
    3
    4
    5
    CREATE DATABASE moodledb DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
    CREATE USER 'moodleuser'@'localhost' IDENTIFIED BY '_password_';
    GRANT ALL ON moodledb.* to 'moodleuser'@'localhost';
    FLUSH PRIVILEGES;
    quit

    Step 4 – Setup Apache for Moodle

    Second is deploy with external web servers like Apache it is preferred for production use. Let’s create an Apache VirtualHost configuration file using the following content.

    sudo vi /etc/httpd/conf.d/moodle.conf
    
    /etc/httpd/conf.d/moodle.conf
    <VirtualHost *:80>
        ServerAdmin [email protected]
        ServerName moodle.example.com
        DocumentRoot /var/www/moodle
        <Directory /var/www/moodle>
              Allowoverride All
        </Directory>
    </VirtualHost>
    

    Change the ServerName and document root as per your setup. Then restart Apache service.

    sudo systemctl restart httpd
    

    Step 5 – Run Moodle Web Installer

    Now access the moodle in your favorite web browser.

     http://moodle.example.com/install.php
    

    This will open the Moodle web installer page.

    Follow the installation wizard to complete the setup. After installation, you will be redirected to Moodle admin dashboard.

    Conclusion

    You have successfully configured Moodle on your Fedora system.

    fedora install moodle Moodle moodle on fedora
    Share. Facebook Twitter Pinterest LinkedIn Tumblr Email WhatsApp

    Related Posts

    10 Simple Ways to Speed Up Your WordPress Website

    10 Simple Ways to Speed Up Your WordPress Website

    How To Install Apache Solr on Fedora

    How To Install Apache Solr 9.0 on Fedora 36/35

    How to Install Git on Fedora Linux

    How To Install Git on Fedora Linux

    View 2 Comments

    2 Comments

    1. Jane on May 16, 2020 10:42 pm

      Hello,
      Thank you for the quick guide.

      I faced an issue at the last step. – “Installation must be finished from the original IP address, sorry.”

      I read the workaround but I could not find the table as it was not created yet.
      Workaround:
      Update the database directly with your current IP address (table: mdl_user, field: lastip, SQL: UPDATE mdl_user set lastip=’159.245.48.2′ where username=’admin’;).

      How I can solve this issue?

      Thanks in advance

      Reply
    2. facultell on March 7, 2019 6:38 am

      Thanks for sharing this post,
      is very helpful article.

      Reply

    Leave A Reply Cancel Reply

    Advertisement
    Recent Posts
    • How to List Manually Installed Packages in Ubuntu & Debian
    • 10 Bash Tricks Every Developer Should Know
    • How to Validate Email Address in JavaScript
    • Firewalld: Common Firewall Rules and Commands
    • 12 Apk Commands in Alpine Linux Package Management
    Facebook Twitter Instagram Pinterest
    © 2023 Tecadmin.net. All Rights Reserved | Terms  | Privacy Policy

    Type above and press Enter to search. Press Esc to cancel.