These forums are locked and archived, but all topics have been migrated to the new forum. You can search for this topic on the new forum: Search for installing webmin/virtualmin with php7 on the new forum.
i am reposting this question since i need to move forward with virtualmin and php7.
in order to install virtualmin/webmin with php7, i had to make some changes to the virtualmin install script (below) using an inline "sed" command. i would like opinions on my changes since i really dont feel comfortable changing an installation script.
###install webmin:
wget http://iweb.dl.sourceforge.net/project/webadmin/webmin/1.780/webmin-1.780.tar.gz
gzip -d ./webmin* && tar -xvf ./webmin* && cd ./webmin* && ./setup.sh ;
##install virtualmin:
curl http://software.virtualmin.com/gpl/scripts/install.sh \
| sed -e 's/ php-/ php70w-/g; s/ php / php-70w /g; s/ php5/ php70w/g; ' \
> install.sh ;
chmod 755 ./install.sh ;
./install.sh ;
Thank you very much.
Howdy,
Hmm, PHP 7 should actually be supported out of the box now that Virtualmin 5 is available.
If it's not being detected automatically, you can also go into System Settings -> Virtualmin Config -> PHP Options, and there, you can set "Additional locations for PHP commands" to the path to the php-cgi executable that's included with your PHP 7 package.
-Eric
I have encountered a number of different PHP issues.
If php is installed by a name that contains a revision number, e.g., /bin/php-70 instead of /bin/php, Virtualmin installation won't work, as it's looking for php, not php-70 (or any other name). You can't go to any Virtualmin screen and enter an alternate path for php, because you haven't installed Virtualmin yet.
The solution is to make symlinks in /bin for every PHP binary so the symlink name doesn't contain the revision number.
cd /bin
ln -s php-70 php
ln -s php-70-cgi php-cgi
ln -s php-70-abc php-abc
ln -s php-70-xyz php-xyz
... etc. ...
If you have multiple versions of PHP, you can only have such symlinks for one of them. In my case, with php56 and php70, I have symlinks for php70 so if you run php you get php70. So Virtualmin GPL works. And it actually finds both versions, because, in the Server Templates : Default Settings : Apache Website : Default PHP version pulldown list, it does list both 5.6.17 and 7.0.2 as available.
However, on the Install Scripts screen, if you try to install any of the scripts, it will error out. E.g., with SquirrelMail, the error message is "This script cannot be installed, as it requires PHP version 4 or 5." This is odd when you think about it, because in the previous paragraph, Virtualmin already listed php 5.6.17 as being available.
In my case, I am using php 7.0 as mod_php and with mod_ruid2. Perhaps the errors might be different with a different configuration.