Linux-Noob Forums

Full Version: Annoying 403 Error
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I have just moved from another LAMP server that wasn't running any Control Panel. I move my files there from a cPanel server without any problem. Now, I want to move them to another server that is closer to me. Upon trying to to move my files via a TAR archive, I am recieving a 403 error. I have tried every single possible combination for permissions both on the folder itself and the files within and I still recieve a 403. (I have tried the one at https://www.linux-noob.com/forums/index.php?/topic/1144-set-correct-permissions-on-your-apache-files/). Does anybody have any ideas? Thank you in advance!

Firstly, check the logfiles to view more information about the 403 error.

 

403 is usually permission-related. This could mean that somewhere higher up, permissions don't allow the apache account to go any further. Check the user account that apache is running under versus file/dir ownership and permissions. I've had an issue where permissions were set find on /home/dave/webroot/htdocs but /home/dave was set to 750 (needed 755 or apache adding to my group to let the webserver in).

 

Note: do NOT set any directory to 777! This allows EVERYONE in, be it apache, any other authorised user, a cracker, a virus - ANYTHING!

 

Another reason for the 403 is Apache permissions: sometimes there is no index page, but "options -indexes" is set on that directory, meaning that Apache *would* serve up a directory listing but its directives prohibit it from doing so (which became the default behaviour from 2.0 onwards).

 

Generally, the apache logfiles can give more information to narrow down what it is. That would be my first port of call.