How to enable bcmath module in PHP 7.1
21,543
Solution 1
For reference purposes, on Ubuntu 16.04.5 LTS, with PHP 7.0, we use:
apt-get install php-bcmath
Solution 2
PHP will be using an additional repository, usually IUS or Remi, so it is likely that you need to install the php71-bcmath
package.
Related videos on Youtube
Author by
Nikk
Updated on September 18, 2022Comments
-
Nikk over 1 year
Am running a Centos7 server. This module
bcmath
wasn't installed,I installed it
yum install php-bcmath
.And it doesn't seem to work. It also doesn't appear in info.php page.
The php version I have is 7.1.12 something.
How do I enable it?
-
Nikk over 6 yearsSays
No package php71-bcmath available.
Error: Nothing to do
. -
Nikk over 6 yearsIt says it uses this repository:
remi-php71: remi.schlundtech.de
-
Simon Greenwood over 6 yearsUse
yum --enablerepo remi.sclundtech.de install php71-bcmath
-
Nikk over 6 yearsNow it says this:
Failed to set locale, defaulting to C
Loaded plugins: fastestmirror
Error getting repository data for remi.sclundtech.de, repository not found
-
Simon Greenwood over 6 yearsTry
yum --enablerepo remi-php71
php71-bcmath` but also refer to the document that you followed to find what repo was set up.