Join the social network of Tech Nerds, increase skill rank, get work, manage projects...
  • How to Install LAMP in your Fedora 23 Workstation?

    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 747
    Comment on it

    Installing LAMP (Linux, Apache, MariaDB and PHP) on Fedora 23 Server and Workstation

    We all know that LAMP goes a long way in hosting a website and honing your PHP programming skills. LAMP is basically a package of Linux, Apache, Mysql/MariaDB and PHP.


    I am discussing in this article the steps one needs to follow to install LAMP in Fedora 23 Server and Workstation.


    The Linux part is completed after you install Fedora 23 Server and Workstation. I am providing links below to guide you to perform this task.


    The best way to begin with the installation of the rest of the packages is to get updated versions of your packages. And the command for it is:

    $ sudo dnf update 

    Now, I will tell you the steps to install the remaining packages.
    1. Installing Apache Web Server
    2. Installing MariaDB Server
    3. Installing PHP


    Installing Apache Web Server

    Well, its no hidden secret that Apache web server is the numero one server when it comes to use for websites. All you need to install Apache Web Server is to run the below command:

              <pre>$ sudo dnf install httpd </pre>

    You now need to perform a few more tasks, like setting up Apache to start working as soon as the system boots. After this, you need to start and complete the verification of the status of Apache.

    Here are the commands you need to run to serve the purpose:

    $ sudo systemctl enable httpd.service 
    $ sudo systemctl start httpd 
    $ sudo systemctl status httpd 

    The next step involves to enable access to it in the system firewall, for which you are required to allow access to the web server over HTTP and HTTPS. Adding the following rules in the fedora rules will be a great help.

    $ sudo firewall-cmd --permanent --add-service=http 
    $ sudo firewall-cmd --permanent --add-service=https 

    Now is the time to ensure that Apache is running successfully. You can find IP address of your system with this command:-

    $ ip a | grep inet 

    Fedora test page will appear once you copy/paste that IP address in your browser.


    Installing MariaDB Server

    You simply need to run the following command to begin installing MariaDB in Fedora 23.

    # dnf isntall mariadb-server

    Once the installation is done, you need to have right configuration of MariaDB to allow it to automatically start after system boot. Now is the time to start and complete the verification task of MariaDB. Following commands will help you do the same:

    # systemctl enable mariadb 
    # systemctl start mariadb 
    # systemctl status mariadb 

    The following command will help you adjust a few settings to secure your MariaDB installation:

    # mysql_secure_installation 


    Installing PHP

    PHP has become the most popular programming languages among website developers. PHP plays a crucial role in setting static websites apart from dynamic ones. Following command will help you install PHP in Fedora 23:

    # dnf install php php-common 

    The following command now needs to be run for PHP/MySQL applications:

    # dnf install php-mysql php-pdo php-gd php-mbstring 

    Please restart Apache to allow access to PHP. And the command for it it:

    # systemctl restart httpd 

    By following all these aforementioned steps, you can install the LAMP stack on Fedora 23 with ease and successfully complete your web project.

 0 Comment(s)

Sign In

Sign up using

Forgot Password
Fill out the form below and instructions to reset your password will be emailed to you:
Reset Password
Fill out the form below and reset your password: