How do I go about enabling GD Support in a CentOS Installation?
CentOs 6.5+ & PHP 5.6:
sudo yum install php56-gd
service httpd restart
For PHP7 on CentOS or EC2 Linux AMI:
sudo yum install php70-gd
Put the command
yum install php-gd
and restart the server (httpd, nginx, etc)
service httpd restart
The thing that did the trick for me eventually was:
yum install gd gd-devel php-gd
and then restart apache:
service httpd restart
sudo yum install php-gd
With CentOS 6.5+ and PHP 5.5:
yum install php55u-gd
service httpd restart
If you get an error like: cannot map zero-fill pages: Cannot allocate memory in Unknown on line 0
, it could be because you don't have a swap file. I suggest you take a look at the tutorial mentioned in this answer: https://stackoverflow.com/a/20275282/828366
Tutorial: https://www.digitalocean.com/community/articles/how-to-add-swap-on-centos-6