Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I am using ssh to connect my host on server (connect via myaccount@ip). However, whenever I make changes in files on server, I see Internal Server Error everywhere. In fact, this happens whenever I commit something to my server using Eclipse svn plugin.

Here is apache2 log

SoftException in Application.cpp:256: File "/home/myaccount/public_html/web/index.php" is writeable by group, referer: http://***
Premature end of script headers: index.php, referer: http://***

I solve this problem via following commands (connect server via root account)

chown -R myaccount:myaccount /home/myaccount/public_html/
chmod -R 0755 /home/myaccount/public_html/

Do I have to connect via root and run commands above everytime I change something on my hosting?

share|improve this question

1 Answer 1

up vote 1 down vote accepted

You should just be able to set the permissions of the files in question to 755 (or your preferred group-unwritable set) with your normal account, since the files should still be owned by that account. To fix the issue permanently, try putting "umask 0227" in your .bashrc.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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