How to Edit php.ini ( php version 7.1) file on amazon AMI instance
I want to change my default php.ini file configuration on amazon-ec2 AMI instance.i can access any my instance using putty and filezila.
Solution
This is only for php version 7.1 or greater.
Conncet your instance using filezila or winSCp .
Navigate to /etc folder.
you can see .ini file at bottom name php-7.1.ini.
using filezila right click on that file and click File Permissions.
If your file permission is 777 then good to go or it is any other than 777 then change it permission using command line interface just remember it's current permission.
use this command to change permission sudo chmod 777 /etc/php-7.1.ini
Now you can edit your .ini file.
After edit your file set back to it's previous permission to 644 or whatever your default ini permission using this command sudo chmod 644 /etc/php-7.1.ini.
And it's done dont forgot to restart server using this command sudo service httpd restart.