MartFame social emarketplace free online selling

Discussions

Problem encountered while upgrading ubuntu server 16.04 to 18.04 - swap unrecognized and did not load desktop - (Virtualmin - Webmin)
Resolved Locked Unanswered
Hi guys, here are some possible problem you may encounter while upgrading ubuntu server from 16.04 to 18.04

After using software updater to upgrade - I noticed that the desktop would not load - It constantly get stuck at A start job is running for dev-md124p2.device (32s / 1min 30s)
After some research, i noticed that it was pointing to my Swap partition. I didn´t want to worry too much about it so I decided to upgrade to ubuntu 20.04 then I started getting errors like Failed to connect to https://changelogs.ubuntu.com/meta-release-development. Check your Internet connection or proxy settings
I resolved this by using the following command line
SSL_CERT_FILE=/etc/ssl/certs/ca-certificates.crt do-release-upgrade
After upgrade, I was able to load desktop but i noticed that swap is still not available but ubuntu 20.04 will still load the desktop.
I tried to access my virtual server meaning website but failed to connect -
I get this error (Error: Call to a member function getActive() on null: Could not connect to MySQL server.)
or
Error: Failed to start application: Could not connect to MySQL server.

or sometimes when i switch to php 8.0
(Error: Failed to start application: Table 'dBase.#__session' doesn't exist)

I tried searching all over the internet and contacting Ubuntu and virtualmin for support -- i was giving several suggestion but none was successful.

To resolve this issue - the first clue i observed that created a path for the solution was that I tried to install phpmyadmin for my virtual server and I got error that says it phpmyadmin only supports PHP version 7.1 and above.
At this point I noticed that, I have all the versions from 7.0 above installed so that I can switch to whichever I prefer but the server only recognized PHP 7.0 despite showing me that I am using PHP 8.0.
At this stage, i purged all the other versions and left 7.3, 7.4 and 8.0.
At this point, I noticed that I was closed to getting my website back as the webpage error changed to something else and noticed that my website was downloading web file automatically.
Please remember that, whenever you make changes to PHP config file and MySQL config file, try to always restart MySQL server and apache2
Anyways, I already know that the reason for the automatic file download without showing webpage is mostly caused by sethandler

You can see the files or file patch doing this by running this command

find /etc/apache2 | xargs grep -i sethandler

You should get result probably similar to the one below

root@example:~# find /etc/apache2 | xargs grep -i sethandler
grep: /etc/apache2: Is a directory
grep: /etc/apache2/conf-enabled: Is a directory
/etc/apache2/conf-enabled/localized-error-pages.conf:# SetHandler directive in a context somewhere. Adding
/etc/apache2/conf-enabled/localized-error-pages.conf:# SetHandler none
grep: /etc/apache2/conf-available: Is a directory
/etc/apache2/conf-available/php7.0-fpm.conf: SetHandler "proxy:unix:/run/php/php7.0-fpm.sock|fcgi://localhost"
/etc/apache2/conf-available/php7.0-cgi.conf: SetHandler application/x-httpd-php
/etc/apache2/conf-available/php7.0-cgi.conf: SetHandler application/x-httpd-php-source
/etc/apache2/conf-available/php7.2-cgi.conf: SetHandler application/x-httpd-php
/etc/apache2/conf-available/php7.2-cgi.conf: SetHandler application/x-httpd-php-source
/etc/apache2/conf-available/localized-error-pages.conf:# SetHandler directive in a context somewhere. Adding
/etc/apache2/conf-available/localized-error-pages.conf:# SetHandler none
grep: /etc/apache2/sites-available: Is a directory
grep: /etc/apache2/suexec: Is a directory
grep: /etc/apache2/mods-enabled: Is a directory
/etc/apache2/mods-enabled/proxy_balancer.conf: # SetHandler balancer-manager
/etc/apache2/mods-enabled/php7.2.conf: #SetHandler application/x-httpd-php
/etc/apache2/mods-enabled/php7.2.conf: SetHandler application/x-httpd-php-source
/etc/apache2/mods-enabled/status.conf: SetHandler server-status
grep: /etc/apache2/mods-available: Is a directory
/etc/apache2/mods-available/ldap.conf: SetHandler ldap-status
/etc/apache2/mods-available/proxy_balancer.conf: # SetHandler balancer-manager
/etc/apache2/mods-available/php7.2.conf: #SetHandler application/x-httpd-php
/etc/apache2/mods-available/php7.2.conf: SetHandler application/x-httpd-php-source
/etc/apache2/mods-available/info.conf: SetHandler server-info
/etc/apache2/mods-available/status.conf: SetHandler server-status
grep: /etc/apache2/sites-enabled: Is a directory


All you need to do in this case is to comment out by adding hash symbol to where ever you find the command below in the file path
SetHandler application/x-httpd-php

This means, you change it to

#SetHandler application/x-httpd-php

Basically after doing this, I restarted Apache2 server and MySQL server and I was able to get my virtualserver/website back




I hope this helps someone out there




#webmin-virtualmin
  • Like
    Like
    Happy
    Love
    Angry
    Wow
    Sad
0
0
0
0
0
0

Participants

Replies(0)

No replies made on this post yet
Unable to load tooltip content.

MartFame.₦G

About Us

Contact Us

Legal Document

Advertizing on MartFame

Socialize

Career

Buy

Buying Basics

MartFame Stores

Shop by brand

Deals

MartFame MoneyBack Guarantee

Help & Contact

Contact Us

Delivery & Returns

Resolution Centre

FAQs

Sell

Start Selling

Seller Dashboard

Selling Fees/Commission

Posting Items

Seller Protection

Sell Locally

MartFame Companies

www.MartFame.NG

www.MartFame.COM

www.MartFame.CO.UK