Skip to content

HHVM – Solving the ini_get() ‘upload_max_filesize’ and ‘post_max_size’ problem in HHVM 3.7 +

My agency has been managing what I would describe as a ‘medium’ traffic site. It gets around 5,000 unique visits per day and handles around 15,000 page views. It also has a reasonably busy membership forum.

The site uses WordPress as the CMS and we’re using HHVM to process PHP. HHVM helps to speed up admin processes and logged-in user experiences and it does a great job.

Every now and then we run into an issue with it and here is one.

When trying to return values for ini_get(‘post_max_size’) and ini_get(‘upload_max_filesize’) HHVM will return a null value.

It was breaking a plugin we are using (WP User Avatar) since it could not determine the servers maximum file upload limit and therefore, couldn’t set an upload limit for user roles.

The following solution also solves some issues with file uploading in Magento and probably loads of other issues in other apps.

Note – I’m using the Centos7 prebuilt package (

Open up /etc/hhvm/server.ini

nano /etc/hhvm/server.ini

Add the following option


Restart HHVM

service hhvm restart

With much thanks –


10 years + experience in web development working with lots of different technology.

Published inHHVMLinuxPHPWordPress

Be First to Comment

Leave a Reply

Your email address will not be published. Required fields are marked *