Virtualmin install.sh support for CentOS 8

It’s only the the /vm/6 repo for CentOS. That covers all CentOS versions, but it would only be the one you’re using if you installed in the past couple of years; older installs are in a repo that updating is difficult. I’m also still working on Debian/Ubuntu repos. But, I’m hoping to wrap it all up this weekend.

If you need it urgently, you can switch to the /vm/6 repos, but if you’re using ClamAV or anything we previously mirrored into our repos from EPEL, it’s probably safer just to wait. Some of the packages changed along the way, in incompatible ways that would need some manual tweaking.

1 Like

Thank you very much Joe! I will wait :slight_smile:

I just tried the new install.sh with a fresh Centos 8.1 install. For me it failed with:
Phase 3 of 3: Configuration
Can't locate open.pm in @INC (you may need to install the open module)
To fix I did
dnf install perl-open.noarch
then ran install again.
Apparently Centos 8 doesn’t install perl by default.
Reference: https://github.com/rbspy/rbspy/issues/164

…jack

1 Like

What is odd here, is that it should be installed automatically!

The script, on clean install calls dnf install perl -y, which installs Perl from @AppStream repo and automatically pulls as a dependency perl-open package.

I would recommend running yum clean all && yum update -y before running Virtualmin installer script.

Interesting. I’m testing this on a VM, of which I made a snapshot after the default centos 8.1 install and dnf update.

So reverted to that snapshot (before even downloading script using [this is the latest, right?] wget -O install.sh https://raw.githubusercontent.com/virtualmin/virtualmin-install/master/virtualmin-install.sh

I tried yum clean all && yum update -y, then sh install.sh, but same error:

Let me know if there is anything I can check or post log-wise.

…jack

I see the issue. In my case perl was installed by the default Centos 8 install with 45 perl-related packages (not including perl-open), so the dnf install perl -y was never called. If I call it manually, it adds 112 additional packages, one of which is the perl-open.

So for now I’m just running dnf install perl -y before the initial install.sh runs. Maybe the installer could check to see if perl-open is installed even if perl is already present?

…jack

I installed Virtualmin on Centos8.
Some problems occurred but I found some workarounds on this and other websites.

After a clean install of Centos8, log in with ssh:

Perl problem
First install perl. then install virtualmin
dnf install perl -y
wget http://software.virtualmin.com/gpl/scripts/install.sh
sudo /bin/sh install.sh =>Y

Postfix problem:
Add the following text in Postfix
Webmin > Servers > Postfix Mail Server > Virtual Domains >Domain mapping lookup tables = hash:/etc/postfix/virtual

MYSQL problem with root password
service mysqld stop
mysqld_safe --skip-grant-tables &
Mysql
At the mysql> prompt, reset the password. To do this, type the following command, replacing new-password with the new root password:
UPDATE mysql.user SET Password=PASSWORD(‘NEW PASSWORD’) WHERE User=‘root’;

At the mysql> prompt, type the following commands:
FLUSH PRIVILEGES;
exit;

Stop the MySQL server using the following command. You will be prompted to enter the new MySQL root password before the MySQL server shuts down:
mysqladmin -u root -p shutdown

For CentOS and Fedora, type:
service mysqld start

Webmin/Virtualmin is now fully working :slight_smile:

However, I’ don’t succeed in adding letsencrypt certificates.
I use the providers DNS so need website verification
I was able to add a letsencrypt certificate in Webmin for the main server.
The virtual servers always returns errors (Forbidden). I asked to get a certificate at installation of the virtual server.
After that failed, I tried to add a letsencrypt certificate with Server configuration/ssl configuration/letsencrypt. I flushed all redirections and made sure that the website was accessible. I even tried to set permissions on 777=> No success
Any idea’s how to solve?

Saving debug log to /var/log/letsencrypt/letsencrypt.log
Plugins selected: Authenticator webroot, Installer None
Obtaining a new certificate
Performing the following challenges:
http-01 challenge for e-farma.be
Using the webroot path /home/e-farma/public_html for all unmatched domains.
Waiting for verification…
Challenge failed for domain e-farma.be
http-01 challenge for e-farma.be
Cleaning up challenges
Some challenges have failed.
IMPORTANT NOTES:

Thanks Ilia. I got past these two issues, but kept running into more problems in Virtualmin’s “Re-Check Configuration”. The most recent was “The AWstats command /usr/share/awstats/wwwroot/cgi-bin/awstats.pl was not found on your system.”

So since I have a user that is demanding MariaDB 10, I am going back to CentOS 7, as I successfully installed Virtualmin after I first installed MariaDB 10. Seems like the best solution until the CentOS 8 installation routine is out of beta.

I am appreciative of the work that goes into this, despite how impatient I seem at times.

Craig

1 Like

Hey,

I was able to successful install MariaDB 10.4 on CentOS 8. To accomplish it, I simply uninstalled MariaDB and used this tutorial to install MariaDB 10.4: https://computingforgeeks.com/how-to-install-mariadb-server-on-centos-rhel-linux/

The MariaDB provided by Virtualmin is through the AppStream. Before you can install the new version through MariaDB, you would need to reset the module by issuing this command:

yum module reset mariadb

I didn’t do this and had a lot of errors when trying to do it.

In regards to the Let’s Encrypt error, I had this as well. The solution was to just manually create a folder named ‘.well-known’ in the root directory of the site’s files. After that, Let’s Encrypt should be successful.

Hi Mik. Thanks, but I think you misunderstood my post. CentOS 8 comes with MariaDB 10 by default, so I’m surprised you had to uninstall it. CentOS 7, on the other hand, still comes with MariaDB 5 (or maybe it’s MySQL 5, I can’t remember), but I used MariaDB’s own instructions to install it before installing Virtualmin and that worked a charm.

As for my LE issue in another post, I can’t see how your suggestion would work for me. Perhaps you’d like to post there and tell me where in the file system I create that directory given the sub-domain I’m using isn’t added to Virtualmin and Virtualmin won’t let me add it. :man_shrugging:

I wanted to use MariaDB 10.4. CentOS 8 comes with 10.3. As a part of the upgrade process, you need to uninstall the older version of MariaDB. (https://mariadb.com/kb/en/upgrading-from-mariadb-103-to-mariadb-104/)

Ah, OK. That’s interesting, because on Thursday I deployed a CentOS 8 instance. I’ve destroyed it now (because there were too many bugs in the Virtualmin installer per my earlier post), so I can’t check, but I’m 99% sure it came with 10.4, not 10.3. However, maybe I’ve mis-remembered.

Regarding obtaining a Let’s Encrypt certificate for Webmin to use, it failed for me the first time.
After a fresh install of CentOS 8 (and running the install script, re-running the script after the “PID” error and fixing the mySQL root password) I headed to Webmin > Webmin Configuration > SSL Encryption and the Let’s Encrypt tab.
The first time the Website root directory for validation file was not set so I selected Other directory" which i thought contained /var/www/html. The request failed.
Then I looked more carefully and saw some fuzziness around the ends of the path. In fact it was (double) quotes.
Removing the quotes so that the Other directory was /var/www/html resulted in a successful request and installation of the LE certificate.

Hi everyone !!

I am trying to install Virtualmin on a newly mounted CentOS 8 server from the following script: https://raw.githubusercontent.com/virtualmin/virtualmin-install/master/virtualmin-install.sh

It gives me the following error:

Problem: conflicting requests

  • nothing provides perl-Geo-IP needed by awstats-7.7-5.el8.noarch
    Installing dependencies and system packages: [2020-04-01 10:33:43 UTC] [ERROR] Failed with error: 1

I have tried to manually install the perl-Geo-IP package but it has given me many problems (it seems that there is a bug: https://bugzilla.redhat.com/show_bug.cgi?id=1763425)

It seems this is related to awstats, is it possible to install Virtualmin without awstats? Can you give me any solution?

Thank you

Hi,

Thanks for heads up.

Actually @Joe has already fixed it locally and just need to push changes to our repos.

Thanks Ilia, will you announce it in this same forum?

Yes, we will announce it, as it gets updated.

Temporarily, to work around AWStats problem on CentOS 8, you can install perl-Geo-IP package from Fedora repos, which works just fine.

I have that on CentOS 7 too. It’s not necessarily a CentOS 8 failure I think. How was your install procedure? It would be interesting to me if this is a mistake in the install script.

The installation has been done from CentOS 8 which facilitates my hosting (OVH) but later I have updated it from the official CentOS repository