#1. Update software packages
#2 install apache server
Domain mapping virtual hosts
Install MySQL server
Install phpmyadmin on Ubuntu 20.04
migration server apache to nginx
navigate to the directory
cd /home/pubclubindia/epf/theonlineking.com
zip -r zipfilename.zip folder name
zip -r king.zip theonlineking.com
backup sql
know the database name by wp-config.php
export
mysql -u root -psqlpass king > /home/pubclubindia/epf/theonlineking.com/a.sql
import command
mysql -u root -psqlpass king < /var/www/html/king.sql
mysql login
mysql -u root -p
mysql -u root -psqlpass
create database king;
Next vhost nnginx
grant permissions to server user
chown www-data:www-data -R /var/www/html/
LAMP installation on ubuntu & debian //Apache
sudo apt install apache2
sudo apt install mysql-server
sudo apt install php-pear php-fpm php-dev php-zip php-curl php-xmlrpc php-gd php-mysql php-mbstring php-xml libapache2-mod-php
sudo service apache2 restart
LAMP install on ubuntu
change apache.conf
apache htaccess allow rewrite
sudo nano /etc/apache2/sites-available/default
Once inside that file, find the following section, and change the line that says AllowOverride from None to All. The section should now look like this:
<Directory /var/www/>
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
allow from all
</Directory>
sudo chown -R pubclubindia:pubclubindia /home/user/
rm -rf /home/user/wp-content/cache/object
<Directory /home/user/>
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
allow from all
</Directory>
Configure domain to directory apache vhosts install wordpress on ubuntu
sudo nano /etc/apache2/sites-available/epfouanloginportal.co.in.conf
sudo chown pubclubindia:pubclubindia /etc/apache2/sites-available/epfouanloginportal.co.in.conf
if root permission not there
past this
<VirtualHost *:80>
ServerAdmin pubclubindia@gmail.com
ServerName eaadharcarddownload.co.in
ServerAlias www.eaadharcarddownload.co.in
DocumentRoot /home/user/eaadharcarddownload.co.in
<Directory /home/user/eaadharcarddownload.co.in/>
Options Indexes FollowSymLinks MultiViews
Options All
AllowOverride All
Require all granted
</Directory>
ErrorLog /home/user/eaadharcarddownload.co.in/error.log
</VirtualHost>
sudo ln -s /etc/apache2/sites-available/aeaadharcarddownload.co.in.conf /etc/apache2/sites-enabled/aeaadharcarddownload.co.in.conf
or you can navbigate to cd /etc/apache2/sites-available/
and run this command sudo ln -s /etc/apache2/sites-available/burnbelly.in.conf
sudo here root level access i am not root user but own apachge directory
apachectl configtest
check for syntax error before restart becuase apache not able to start again.
sudo service apache2 reload
cheeck your website on browser.