I get this error after upgrading to EE 2.10.1

Fatal error: Call to undefined function EllisLab\ExpressionEngine\Library\Mime\finfo_open() in /home/foo/bar/EllisLab/ExpressionEngine/Library/Mime/MimeType.php on line 117

I can't upload files through the CP or synchronise in file manager.

I've tried adding fileinfo.so to extension in php.ini as suggsted here https://stackoverflow.com/questions/3579072/php-fileinfo-is-undefined-function but it didn't do anything, just got the same error message.


EllisLab addresses this issue on a blog post. Part of it:

If you encounter problems with uploading files check the following:

  1. Login to your CP and go to Tools, then Utilities, then PHP Info. If you see --disable-fileinfo on that page (I recommend using your browser’s search function) then you will need to contact your host and have them provide a version of PHP with fileinfo not disabled (i.e. enabled).
  2. Check your system/expressionengine/config/mimes.php file. If it does not contain $whitelist = array around line 31 you will need to upload a fresh copy.

There's more useful info there.

  • Your right about --disable-fileinfo showing up under 'Configure Command'. I've already added extension = "fileinfo.so" in my php.ini so not sure why still showing as disabled? – Samsull May 8 '15 at 9:25
  • Did you restarted PHP? I'm just trying to guess now. – Sobral May 8 '15 at 11:35
  • 1
    yes, restarted Apache and a graceful server reboot. I've opened a ticket with the hosting company, maybe they can help out. – Samsull May 8 '15 at 21:21
  • Had the same issue, my host company installed fileinfo php module (using easyapache) and that fixed the issue. davor – Davor Peic Jun 1 '15 at 19:47
  • 1
    Anyone know of an alternative work around if hosts cant help with fileinfo? – paulcripps Nov 24 '15 at 23:32

I solved this installing php7.0-gd.

sudo add-apt-repository ppa:ondrej/php
sudo apt-get update

Next, install the desired version:

sudo apt-get install php7.0-gd
# or
sudo apt-get install php7.1-gd
# or
sudo apt-get install php7.2-gd

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.