How to edit httpd.conf file in AMAZON EC2

Sumit Bijvani picture Sumit Bijvani · Feb 27, 2013 · Viewed 72.9k times · Source

I am new on AMAZON EC2 Server, recently I have Installed PHP and MySQL and now I want to update file /etc/httpd/conf/httpd.conf

but the problem is, when I am going to update it, it display error like - Permission denied. What is the best way to update it?

Answer

Syed Priom picture Syed Priom · Apr 21, 2013

You have to change the file as root user. Do this:

sudo nano /etc/httpd/conf/httpd.conf

Make your changes and save with ctrl + O, Enter. Done.